Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Added Deprecation Warnings for CoreAPI#7519

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
auvipy merged 31 commits intoencode:masterfromsmithdc1:coreapi
Jun 13, 2023
Merged

Conversation

@smithdc1
Copy link
Contributor

Fixed#7007 -- CoreAPI deprecation not being raised

As per comments in the linked issue, this PR looks to add deprecation warnings for CoreAPI. Comments some time ago suggested this should form part of the 3.12 release.

I have:

  • Added warnings at where I think are the relevant points
  • Added a filter that suppresses all of these warnings from the existing test suite. This is based on a regex match of the warning message
  • Added deprecation tests to check that the warning is actually raised when those elements are used.

sevdog and johnthagen reacted with thumbs up emojiauvipy reacted with heart emoji
@smithdc1smithdc1force-pushed thecoreapi branch 2 times, most recently from322ef8c to937e2d1CompareSeptember 4, 2020 22:01
@carltongibsoncarltongibson added this to the3.12 Release milestoneSep 5, 2020
@carltongibson
Copy link
Collaborator

Super. Good work@smithdc1. Yes, it's time to add these I think. 👍

Copy link
Collaborator

@carltongibsoncarltongibson left a comment

Choose a reason for hiding this comment

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

Looks good. (Half wonder if we need to trigger the warnings in the paginator, for example, but I can't see that it hurts.)

@smithdc1
Copy link
ContributorAuthor

As this is now targeting the 3.13 release I've moved the warnings to target removal in 3.15. I've also rebased.

carltongibson reacted with thumbs up emoji

@johnthagen
Copy link
Contributor

johnthagen commentedOct 27, 2020
edited
Loading

@carltongibson As someone helping maintaindrf-yasg,which is still using coreapi.SchemaGenerator, do you know about how long it will be before DRF 3.13 is released (i.e. how much time we have to migrate away before warnings are thrown)?

Thanks.

@carltongibson
Copy link
Collaborator

Hi@johnthagen. I'd say a while. 😀

This was to go in 3.12, but didn't make it. That's OK. I originally meant to add the warnings around the 3.10 timescale. But bandwidth as ever.

If I were you I'd pull the few CoreAPI bits out separately so that you're not relying on them being in DRF at all.

The whole idea of SchemaGenerator, and attaching via the descriptor atschema was to decouple the schema generation from the rest of the framework.

If you moved those bits you need wholesale, they'd no longer be an issue. (It should just be a couple of classes no? 🤔)

@stale
Copy link

stalebot commentedMar 25, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stalestalebot added the stale labelMar 25, 2022
@auvipy
Copy link
Collaborator

@tfranzel are you going to handle this one? if not I will try to fix the conflict

@stalestalebot removed the stale labelNov 29, 2022
@tfranzel
Copy link
Contributor

@auvipy I will have a look later today.

auvipy and johnthagen reacted with thumbs up emoji

@auvipy
Copy link
Collaborator

I fixed the merge conflicts, might need to fix the lint errors as well, I want to know if removed in 3.15 is still right for this? or we should increment the version number?? If no I will check what else need to be adjusted to merge this over the next couple of weeks.

@auvipyauvipy self-assigned thisJun 12, 2023
Copy link
Collaborator

@auvipyauvipy left a comment

Choose a reason for hiding this comment

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

merging this without the pre commit fixes. will fix them separately

@auvipyauvipy merged commita16dbfd intoencode:masterJun 13, 2023
auvipy added a commit that referenced this pull requestJun 17, 2023
* fix OpenAPIRenderer for timedelta* added test for rendering openapi with timedelta* fix OpenAPIRenderer for timedelta* added test for rendering openapi with timedelta* Removed usage of field.choices that triggered full table load (#8950)Removed the `{{ field.choices|yesno:",disabled" }}` block because this triggers the loading of full database table worth of objects just to determine whether the multi-select widget should be set as disabled or not.Since this "disabled" marking feature is not present in the normal select field, then I propose to remove it also from the multi-select.* Added Deprecation Warnings for CoreAPI (#7519)* Added Deprecation Warnings for CoreAPI* Bumped removal to DRF315* Update rest_framework/__init__.py* Update rest_framework/filters.py* Update rest_framework/filters.py* Update tests/schemas/test_coreapi.py* Update rest_framework/filters.py* Update rest_framework/filters.py* Update tests/schemas/test_coreapi.py* Update tests/schemas/test_coreapi.py* Update setup.cfg* Update rest_framework/pagination.py---------Co-authored-by: Asif Saif Uddin <auvipy@gmail.com>* Update copy right timeline* Fix NamespaceVersioning ignoring DEFAULT_VERSION on non-None namespaces (#7278)* Fix the case where if the namespace is not None and there's no match,  NamespaceVersioning always raises NotFound even if DEFAULT_VERSION  is set or None is in ALLOWED_VERSIONS* Add test cases* fix OpenAPIRenderer for timedelta* added test for rendering openapi with timedelta* added testcase for rendering yaml with minvalidator for duration field (timedelta)---------Co-authored-by: Rizwan Shaikh <rshaikh@ces-ltd.com>Co-authored-by: Lenno Nagel <lenno@namespace.ee>Co-authored-by: David Smith <39445562+smithdc1@users.noreply.github.com>Co-authored-by: Asif Saif Uddin <auvipy@gmail.com>Co-authored-by: Konstantin Kuchkov <konstantin.kuchkov@gmail.com>
@smithdc1smithdc1 deleted the coreapi branchNovember 26, 2023 22:11
tomodachi94 added a commit to tomodachi94/nixpkgs that referenced this pull requestNov 22, 2024
tomodachi94 added a commit to tomodachi94/nixpkgs that referenced this pull requestNov 22, 2024
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@carltongibsoncarltongibsoncarltongibson approved these changes

@auvipyauvipyauvipy approved these changes

Assignees

@auvipyauvipy

Projects

None yet

Milestone

3.15

Development

Successfully merging this pull request may close these issues.

CoreAPI schemas not raising RemovedInDRF317Warning

6 participants

@smithdc1@carltongibson@johnthagen@auvipy@tfranzel@lovelydinosaur

[8]ページ先頭

©2009-2025 Movatter.jp