Update dependency fastapi to ~=0.114.0 #16

Merged
profitroll merged 1 commits from renovate/fastapi-0.x into dev 2024-09-07 11:31:07 +03:00
Collaborator

This PR contains the following updates:

Package Update Change
fastapi (changelog) minor ~=0.112.0 -> ~=0.114.0

Release Notes

fastapi/fastapi (fastapi)

v0.114.0

Compare Source

You can restrict form fields to only include those declared in a Pydantic model and forbid any extra field sent in the request using Pydantic's model_config = {"extra": "forbid"}:

from typing import Annotated

from fastapi import FastAPI, Form
from pydantic import BaseModel

app = FastAPI()

class FormData(BaseModel):
    username: str
    password: str
    model_config = {"extra": "forbid"}

@​app.post("/login/")
async def login(data: Annotated[FormData, Form()]):
    return data

Read the new docs: Form Models - Forbid Extra Form Fields.

Features
Docs
Internal
  • Update internal tests for latest Pydantic, including CI tweaks to install the latest Pydantic. PR #​12147 by @​tiangolo.

v0.113.0

Compare Source

Now you can declare form fields with Pydantic models:

from typing import Annotated

from fastapi import FastAPI, Form
from pydantic import BaseModel

app = FastAPI()

class FormData(BaseModel):
    username: str
    password: str

@​app.post("/login/")
async def login(data: Annotated[FormData, Form()]):
    return data

Read the new docs: Form Models.

Features
Internal

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Renovate Bot.

This PR contains the following updates: | Package | Update | Change | |---|---|---| | [fastapi](https://github.com/fastapi/fastapi) ([changelog](https://fastapi.tiangolo.com/release-notes/)) | minor | `~=0.112.0` -> `~=0.114.0` | --- ### Release Notes <details> <summary>fastapi/fastapi (fastapi)</summary> ### [`v0.114.0`](https://github.com/fastapi/fastapi/releases/tag/0.114.0) [Compare Source](https://github.com/fastapi/fastapi/compare/0.113.0...0.114.0) You can restrict form fields to only include those declared in a Pydantic model and forbid any extra field sent in the request using Pydantic's `model_config = {"extra": "forbid"}`: ```python from typing import Annotated from fastapi import FastAPI, Form from pydantic import BaseModel app = FastAPI() class FormData(BaseModel): username: str password: str model_config = {"extra": "forbid"} @&#8203;app.post("/login/") async def login(data: Annotated[FormData, Form()]): return data ``` Read the new docs: [Form Models - Forbid Extra Form Fields](https://fastapi.tiangolo.com/tutorial/request-form-models/#forbid-extra-form-fields). ##### Features - ✨ Add support for forbidding extra form fields with Pydantic models. PR [#&#8203;12134](https://github.com/fastapi/fastapi/pull/12134) by [@&#8203;tiangolo](https://github.com/tiangolo). ##### Docs - 📝 Update docs, Form Models section title, to match config name. PR [#&#8203;12152](https://github.com/fastapi/fastapi/pull/12152) by [@&#8203;tiangolo](https://github.com/tiangolo). ##### Internal - ✅ Update internal tests for latest Pydantic, including CI tweaks to install the latest Pydantic. PR [#&#8203;12147](https://github.com/fastapi/fastapi/pull/12147) by [@&#8203;tiangolo](https://github.com/tiangolo). ### [`v0.113.0`](https://github.com/fastapi/fastapi/releases/tag/0.113.0) [Compare Source](https://github.com/fastapi/fastapi/compare/0.112.4...0.113.0) Now you can declare form fields with Pydantic models: ```python from typing import Annotated from fastapi import FastAPI, Form from pydantic import BaseModel app = FastAPI() class FormData(BaseModel): username: str password: str @&#8203;app.post("/login/") async def login(data: Annotated[FormData, Form()]): return data ``` Read the new docs: [Form Models](https://fastapi.tiangolo.com/tutorial/request-form-models/). ##### Features - ✨ Add support for Pydantic models in `Form` parameters. PR [#&#8203;12129](https://github.com/fastapi/fastapi/pull/12129) by [@&#8203;tiangolo](https://github.com/tiangolo). ##### Internal - 🔧 Update sponsors: Coherence link. PR [#&#8203;12130](https://github.com/fastapi/fastapi/pull/12130) by [@&#8203;tiangolo](https://github.com/tiangolo). </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi4zNS4wIiwidXBkYXRlZEluVmVyIjoiMzYuMzUuMCIsInRhcmdldEJyYW5jaCI6ImRldiJ9-->
Renovate added 1 commit 2024-09-05 18:46:00 +03:00
Renovate scheduled this pull request to auto merge when all checks succeed 2024-09-05 18:46:00 +03:00
Renovate force-pushed renovate/fastapi-0.x from 308dfa008d to f660550807 2024-09-06 20:51:15 +03:00 Compare
Renovate changed title from Update dependency fastapi to ~=0.113.0 to Update dependency fastapi to ~=0.114.0 2024-09-06 20:51:18 +03:00
profitroll merged commit 73dcfbd8d7 into dev 2024-09-07 11:31:07 +03:00
profitroll deleted branch renovate/fastapi-0.x 2024-09-07 11:31:07 +03:00
Sign in to join this conversation.
No reviewers
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: GarbageReminder/API#16
No description provided.