⬆️ Upgrade Starlette supported version range to >=0.40.0,<0.49.0 - #14077
Merged
Merged
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
Member
|
If we use 429 instead of the constant, there's no need to bump. Maybe we should do that? |
Contributor
Author
As in, just write literal integer |
Member
|
Yep, I think a literal |
Restore support for Starlette 0.40 through 0.47 (without deprecation warnings in Starlette 0.48) by using the literal integer `422` or string representation `"422"` in place of either the new RFC 9110 name `HTTP_422_UNPROCESSABLE_CONTENT` or the earlier RFC 7231 name `HTTP_422_UNPROCESSABLE_ENTITY`.
This comment was marked as outdated.
This comment was marked as outdated.
svlandeg
reviewed
Sep 15, 2025
Contributor
|
📝 Docs preview for commit 0e23139 at: https://e30477a7.fastapitiangolo.pages.dev |
Kludex
approved these changes
Sep 16, 2025
16 tasks
Vasilije1990
added a commit
to topoteretes/cognee
that referenced
this pull request
Oct 22, 2025
<!-- .github/pull_request_template.md --> ## Description <!-- Please provide a clear, human-generated description of the changes in this PR. DO NOT use AI-generated descriptions. We want to understand your thought process and reasoning. --> In `uv.lock`, we've already been using fastapi version 0.119.0 for a while. However, with #1586 changes we can't allow fastapi to be lower than 0.116.2. See fastapi/fastapi#14077 ## Type of Change <!-- Please check the relevant option --> - [ ] Bug fix (non-breaking change that fixes an issue) - [ ] New feature (non-breaking change that adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to change) - [ ] Documentation update - [ ] Code refactoring - [ ] Performance improvement - [ ] Other (please specify): ## Screenshots/Videos (if applicable) <!-- Add screenshots or videos to help explain your changes --> ## Pre-submission Checklist <!-- Please check all boxes that apply before submitting your PR --> - [ ] **I have tested my changes thoroughly before submitting this PR** - [ ] **This PR contains minimal changes necessary to address the issue/feature** - [ ] My code follows the project's coding standards and style guidelines - [ ] I have added tests that prove my fix is effective or that my feature works - [ ] I have added necessary documentation (if applicable) - [ ] All new and existing tests pass - [ ] I have searched existing PRs to ensure this change hasn't been submitted already - [ ] I have linked any relevant issues in the description - [ ] My commits have clear and descriptive messages ## DCO Affirmation I affirm that all code in every commit of this pull request conforms to the terms of the Topoteretes Developer Certificate of Origin.
ivantodorovich
added a commit
to camptocamp/rest-framework
that referenced
this pull request
Nov 3, 2025
Starting from `starlette >= 0.48`, the `status.HTTP_422_UNPROCESSABLE_ENTITY` emits a deprecation warning, as it has been replaced by `status.HTTP_422_UNPROCESSABLE_CONTENT`. To be compatible with past and future versions, we simply use the integer value `422`, aligning also with the updated `fastapi` documentation: See: - fastapi/fastapi#14077
florian-dacosta
pushed a commit
to akretion/rest-framework
that referenced
this pull request
Mar 26, 2026
Starting from `starlette >= 0.48`, the `status.HTTP_422_UNPROCESSABLE_ENTITY` emits a deprecation warning, as it has been replaced by `status.HTTP_422_UNPROCESSABLE_CONTENT`. To be compatible with past and future versions, we simply use the integer value `422`, aligning also with the updated `fastapi` documentation: See: - fastapi/fastapi#14077
lmignon
pushed a commit
to acsone/rest-framework
that referenced
this pull request
Apr 16, 2026
Starting from `starlette >= 0.48`, the `status.HTTP_422_UNPROCESSABLE_ENTITY` emits a deprecation warning, as it has been replaced by `status.HTTP_422_UNPROCESSABLE_CONTENT`. To be compatible with past and future versions, we simply use the integer value `422`, aligning also with the updated `fastapi` documentation: See: - fastapi/fastapi#14077
This was referenced Jun 23, 2026
This was referenced Jul 28, 2026
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Starlette 0.48.0 introduced
HTTP_422_UNPROCESSABLE_CONTENTas a new name forHTTP_422_UNPROCESSABLE_ENTITYand deprecated the old name due to RFC 9110; see Kludex/starlette#2939.I updated all instances
to the new name and increased the lower bound on the Starlette versionto use the literal integer or string value422/"422"instead of eitherHTTP_422_UNPROCESSABLE_CONTENTorHTTP_422_UNPROCESSABLE_ENTITY, which makes FastAPI compatible with Starlette >=0.48 without deprecation warnings while preserving backwards compatibility with Starlette<0.48.@Kludex, FYI.