Skip to content

Commit 8494b57

Browse files
committed
Replace unmaintained paste with pastey in utoipa-axum
The paste crate has been archived and is no longer maintained (RUSTSEC-2024-0436). Replace it with pastey, a maintained fork that provides drop-in compatibility.
1 parent a024aca commit 8494b57

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

utoipa-axum/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ utoipa = { version = "5.0.0", path = "../utoipa", default-features = false, feat
2828
] }
2929
tower-service = "0.3"
3030
tower-layer = "0.3.2"
31-
paste = "1.0"
31+
pastey = "0.1.1"
3232

3333
[dev-dependencies]
3434
utoipa = { path = "../utoipa", features = ["debug"] }

utoipa-axum/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ impl PathItemExt for HttpMethod {
7575

7676
/// re-export paste so users do not need to add the dependency.
7777
#[doc(hidden)]
78-
pub use paste::paste;
78+
pub use pastey::paste;
7979

8080
/// Collect axum handlers annotated with [`utoipa::path`] to [`router::UtoipaMethodRouter`].
8181
///

utoipa-gen/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ axum = { version = "0.8.0", default-features = false, features = [
4545
"json",
4646
"query",
4747
] }
48-
paste = "1"
48+
pastey = "0.1.1"
4949
rocket = { version = "0.5", features = ["json"] }
5050
smallvec = { version = "1.10", features = ["serde"] }
5151
rust_decimal = { version = "1", default-features = false }

utoipa-gen/tests/path_derive.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
use std::collections::BTreeMap;
22

33
use insta::assert_json_snapshot;
4-
use paste::paste;
4+
use pastey::paste;
55
use serde::Serialize;
66
use serde_json::{json, Value};
77
use std::collections::HashMap;

utoipa-gen/tests/path_response_derive_test.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ macro_rules! test_response_types {
139139
( $( $name:ident=> $(body: $expected:expr,)? $( $content_type:literal, )? $( headers: $headers:expr, )?
140140
assert: $( $path:literal = $expectation:literal, $comment:literal )* )* ) => {
141141
$(
142-
paste::paste! {
142+
pastey::paste! {
143143
test_fn! {
144144
module: [<mod_ $name>],
145145
responses: (
@@ -154,7 +154,7 @@ macro_rules! test_response_types {
154154

155155
#[test]
156156
fn $name() {
157-
paste::paste! {
157+
pastey::paste! {
158158
let doc = api_doc!(module: [<mod_ $name>]);
159159
}
160160

0 commit comments

Comments
 (0)