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

Upgrade axum to 0.8 #3893

Merged
merged 1 commit into from
Jan 28, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
98 changes: 40 additions & 58 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 7 additions & 7 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ oauth2-types = { path = "./crates/oauth2-types/", version = "=0.13.0-rc.1" }

# OpenAPI schema generation and validation
[workspace.dependencies.aide]
version = "0.13.5"
features = ["axum", "axum-headers", "macros"]
version = "0.14.0"
features = ["axum", "axum-extra", "axum-json", "axum-query", "macros"]

# GraphQL server
[workspace.dependencies.async-graphql]
Expand All @@ -75,11 +75,11 @@ version = "1.0.95"

# HTTP router
[workspace.dependencies.axum]
version = "0.7.9"
version = "0.8.1"

# Extra utilities for Axum
[workspace.dependencies.axum-extra]
version = "0.9.6"
version = "0.10.0"
features = ["cookie-private", "cookie-key-expansion", "typed-header"]

# Constant-time base64
Expand Down Expand Up @@ -271,18 +271,18 @@ features = [

# Sentry error tracking
[workspace.dependencies.sentry]
version = "0.34.0"
version = "0.36.0"
default-features = false
features = ["backtrace", "contexts", "panic", "tower", "reqwest"]

# Sentry tower layer
[workspace.dependencies.sentry-tower]
version = "0.34.0"
version = "0.36.0"
features = ["http"]

# Sentry tracing integration
[workspace.dependencies.sentry-tracing]
version = "0.34.0"
version = "0.36.0"

# Serialization and deserialization
[workspace.dependencies.serde]
Expand Down
4 changes: 1 addition & 3 deletions crates/axum-utils/src/client_authorization.rs
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
// Copyright 2024 New Vector Ltd.
// Copyright 2024, 2025 New Vector Ltd.
// Copyright 2022-2024 The Matrix.org Foundation C.I.C.
//
// SPDX-License-Identifier: AGPL-3.0-only
// Please see LICENSE in the repository root for full details.

use std::collections::HashMap;

use async_trait::async_trait;
use axum::{
extract::{
rejection::{FailedToDeserializeForm, FormRejection},
Expand Down Expand Up @@ -321,7 +320,6 @@ impl IntoResponse for ClientAuthorizationError {
}
}

#[async_trait]
impl<S, F> FromRequest<S> for ClientAuthorization<F>
where
F: DeserializeOwned,
Expand Down
4 changes: 1 addition & 3 deletions crates/axum-utils/src/cookies.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2024 New Vector Ltd.
// Copyright 2024, 2025 New Vector Ltd.
// Copyright 2022-2024 The Matrix.org Foundation C.I.C.
//
// SPDX-License-Identifier: AGPL-3.0-only
Expand All @@ -8,7 +8,6 @@

use std::convert::Infallible;

use async_trait::async_trait;
use axum::{
extract::{FromRef, FromRequestParts},
response::{IntoResponseParts, ResponseParts},
Expand Down Expand Up @@ -65,7 +64,6 @@ impl CookieManager {
}
}

#[async_trait]
impl<S> FromRequestParts<S> for CookieJar
where
CookieManager: FromRef<S>,
Expand Down
4 changes: 1 addition & 3 deletions crates/axum-utils/src/user_authorization.rs
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
// Copyright 2024 New Vector Ltd.
// Copyright 2024, 2025 New Vector Ltd.
// Copyright 2022-2024 The Matrix.org Foundation C.I.C.
//
// SPDX-License-Identifier: AGPL-3.0-only
// Please see LICENSE in the repository root for full details.

use std::{collections::HashMap, error::Error};

use async_trait::async_trait;
use axum::{
extract::{
rejection::{FailedToDeserializeForm, FormRejection},
Expand Down Expand Up @@ -284,7 +283,6 @@ where
}
}

#[async_trait]
impl<S, F> FromRequest<S> for UserAuthorization<F>
where
F: DeserializeOwned,
Expand Down
Loading
Loading