Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version 3.14.0 proposal #8599

Merged
merged 6 commits into from
Sep 21, 2022
Merged

Conversation

tim-schilling
Copy link
Contributor

Currently projects using Django 4.1 are blocked from using Django Rest Framework due to #8591. Since that was merged, I think a release is warranted.

I started putting together the changes from 3.13.1, and discovered there were a couple of API changes. I suspect this should require a minor version change, but a maintainer should make that final call.

If the version change isn't desired, let me know and I can remove that.

@tomchristie
Copy link
Member

Good stuff, thanks Tim.
And yes, a 3.14 release makes sense.

I'd like #7522 to be part of this too, but would be great to get a review onto that from someone other than myself.

@Nta1e Nta1e mentioned this pull request Aug 16, 2022
3 tasks
@Nta1e
Copy link

Nta1e commented Aug 30, 2022

@tomchristie can we release this? It's blocking upgrades to Django 4.1

@tomchristie
Copy link
Member

Consideration... I suppose we might want to include #8617 for this release. Thoughts?

We also ought to add a https://www.django-rest-framework.org/community/3.14-announcement/ page to the docs.

@mscansian
Copy link
Contributor

@tomchristie it would be nice to not delay too much the release of this version since it's actually blocking everyone from upgrading to Django 4.1

@tim-schilling
Copy link
Contributor Author

I can add the community page this weekend. If #8617 isn't resolved by then, perhaps that goes in a 3.15 release when it does get merged?

@Archmonger
Copy link

Archmonger commented Sep 2, 2022

I believe #8617 is now in a mergeable state. Should be able to make it in to the 3.14 release.

This deprecation was never released in the 3.13.x series and therefore
can't be removed at the same time the replacement is released.
@tim-schilling
Copy link
Contributor Author

I've added a draft for the community page, including the mention for #7522.

I also noticed that the warnings for RemovedInDRF314Warning were still being raised, so I removed the functionality that was scheduled for removal.

One thing that I caught was that the openapi _get_reference warning was introduced into the master branch, but never released. Since the deprecation is being released in version 3.14, we can't remove the call in 3.14 as well. I've created a new class for RemovedInDRF315Warning and switched _get_reference to reference that instead.

Comment on lines 36 to 37
class RemovedInDRF314Warning(PendingDeprecationWarning):
pass
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this and the above RemovedInDRF313Warning can be removed? I cannot find any other references.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I kept it as per the comments in #8589.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That argument doesn't really convince me, DRF has never kept around the old warning classes for previous versions, e.g. RemovedInDRF312Warning was removed in d45e000. Similarly, Django does not keep around old warning classes "just in case".

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rather leave that decision up to a maintainer. I wasn't a part of the original discussion so it'd be disingenuous for me to say that by convincing me, the past argument is moot.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry to have missed this thread!

I was assuming that RemovedInDRF313Warning would be deleted with the 3.14 release.
(My point was only that deleting an exception class in a minor release would constitute a breaking change)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CC @adamchainz - put out a PR to delete the now-unused warnings: #8664


Our requirements are now:

* Python 3.6+
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

imho this should be 3.7+ but we need #8518 to be merged

Suggested change
* Python 3.6+
* Python 3.7+

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd be happy merging that but I'll defer to @tomchristie.

Our requirements are now:

* Python 3.6+
* Django 4.1, 4.0, 3.2, 3.1, 2.2 (LTS)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* Django 4.1, 4.0, 3.2, 3.1, 2.2 (LTS)
* Django 4.1, 4.0, 3.2 (LTS)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can do the related clean ups in a separate PR as well.

@spapas
Copy link

spapas commented Sep 13, 2022

Hello friends, do we have a timeline on when will the new release be released?

I think this should be prioritized because DRF can't be used with Django 4.1 because of the ValueError: The file 'rest_framework/css/bootstrap-theme.min.css.map' could not be found with <django.contrib.staticfiles.storage.ManifestStaticFilesStorage error.

Thank you and kind regards,
Serafeim

@spapas
Copy link

spapas commented Sep 13, 2022

Also, are you working on a specific branch or tag for the 3.14 release ? I'd be happy to install it directly from github using the -e git+https://github.com... requirement if you point me to the correct branch. Could I use tim-schilling:version-3.14.0 ?

Thanks again

@tomchristie
Copy link
Member

Hello friends, do we have a timeline on when will the new release be released?

It's right at the top of the list. Ought to be this week.

@tomchristie
Copy link
Member

Ought to be this week.

Arrrgggh. Don't be too mean.
Getting there.

@tomchristie tomchristie merged commit b658915 into encode:master Sep 21, 2022
@tim-schilling
Copy link
Contributor Author

tim-schilling commented Sep 21, 2022 via email

@tim-schilling
Copy link
Contributor Author

I see the follow-up PR now and that you're on it! Thank you.

@tomchristie
Copy link
Member

tomchristie commented Sep 21, 2022

Okay... I'm ready for us to release this tomorrow unless there's any objections?

I've updated the release date in the docs to 22nd Sept 2022.

@tim-schilling
Copy link
Contributor Author

@tomchristie is DRF's policy regarding RemovedInDRF<version>Warning changing? Adam brought up that the project hasn't kept the previous warning classes, but we still have RemovedInDRF314Warning hanging around currently.

@DavidCain
Copy link
Contributor

@tomchristie is DRF's policy regarding RemovedInDRFWarning changing? Adam brought up that the project hasn't kept the previous warning classes, but we still have RemovedInDRF314Warning hanging around currently.

I responded in-thread, but also noting here:

The pattern in past releases has been to drop the old unused exception classes - I think we should do the same for 3.14.
I only kept RemovedInDRF313Warning around because 3.13 was released with that exception class still defined.

Would be best to not repeat the same strangeness with DRF 3.14. 😄

#8664

(Sorry for not being clear on my original PR)

@gopackgo90
Copy link

It looks like Django 2.2 is being dropped, but the setup.cfg still looks like it allows for Django 2.2 both in the python_requires and classifiers.

https://github.com/encode/django-rest-framework/blob/master/setup.py#L85
https://github.com/encode/django-rest-framework/blob/master/setup.py#L92

I also would think dropping Django 2.2 should be added to the release notes.

@tomchristie
Copy link
Member

Okay, released.

@pauloxnet
Copy link
Member

Thanks for the release. 🙏️

@MarkusH
Copy link

MarkusH commented Sep 22, 2022

Okay, released.

Wonderful. Thank you ❤️

sigvef pushed a commit to sigvef/django-rest-framework that referenced this pull request Dec 3, 2022
* Version 3.14.0

* Update docs/community/release-notes.md to use proper links.

Co-authored-by: Adam Johnson <[email protected]>

* Add community announcement page for version 3.14

* Remove deprecated NullBooleanField.

* Change openapi _get_reference removal to 3.15

This deprecation was never released in the 3.13.x series and therefore
can't be removed at the same time the replacement is released.

* Removing deprecated openapi methods.

Co-authored-by: Adam Johnson <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.