Skip to content

Commit d1d772c

Browse files
committed
poem v3.1.5
poem-openapi v5.1.4
1 parent 97c65a8 commit d1d772c

File tree

5 files changed

+15
-11
lines changed

5 files changed

+15
-11
lines changed

poem-openapi-derive/src/api.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -400,8 +400,10 @@ fn generate_operation(
400400
request_meta.push(quote! {
401401
if <#arg_ty as #crate_name::ApiExtractor>::TYPES.contains(&#crate_name::ApiExtractorType::RequestObject) {
402402
request = <#arg_ty as #crate_name::ApiExtractor>::request_meta();
403-
if let Some(ref mut request) = request.as_mut() {
404-
request.description = #param_desc;
403+
if let ::std::option::Option::Some(ref mut request) = request.as_mut() {
404+
if request.description.is_none() {
405+
request.description = #param_desc;
406+
}
405407
}
406408
}
407409
});

poem-openapi/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7+
#[5.1.4] 2024-11-25
8+
9+
- Assign the description to the request object in OpenAPI [#886](https://github.com/poem-web/poem/pull/886)
10+
- Implemented nullable fields for openapi spec generation [#865](https://github.com/poem-web/poem/pull/865)
11+
- refactor: change type name delimiters from `<>` `()` `[]` to `_` [#904](https://github.com/poem-web/poem/pull/904)
12+
713
#[5.1.3] 2024-11-20
814

915
- Update MSRV to `1.81.0`

poem-openapi/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "poem-openapi"
3-
version = "5.1.3"
3+
version = "5.1.4"
44
authors.workspace = true
55
edition.workspace = true
66
license.workspace = true

poem-openapi/tests/object.rs

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -43,21 +43,15 @@ fn generics() {
4343
delete_user: T2,
4444
}
4545

46-
assert_eq!(
47-
<Obj<i32, i64>>::name(),
48-
"Obj_integer_int32_integer_int64"
49-
);
46+
assert_eq!(<Obj<i32, i64>>::name(), "Obj_integer_int32_integer_int64");
5047
let meta = get_meta::<Obj<i32, i64>>();
5148
assert_eq!(meta.properties[0].1.unwrap_inline().ty, "integer");
5249
assert_eq!(meta.properties[0].1.unwrap_inline().format, Some("int32"));
5350

5451
assert_eq!(meta.properties[1].1.unwrap_inline().ty, "integer");
5552
assert_eq!(meta.properties[1].1.unwrap_inline().format, Some("int64"));
5653

57-
assert_eq!(
58-
<Obj<f32, f64>>::name(),
59-
"Obj_number_float_number_double"
60-
);
54+
assert_eq!(<Obj<f32, f64>>::name(), "Obj_number_float_number_double");
6155
let meta = get_meta::<Obj<f32, f64>>();
6256
assert_eq!(meta.properties[0].1.unwrap_inline().ty, "number");
6357
assert_eq!(meta.properties[0].1.unwrap_inline().format, Some("float"));

poem/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77
# [3.1.5] 2024-11-25
88

99
- Bump `opentelemetry` to `0.27.0`
10+
- Add WebSocketStream::get_config method to get the WebSocket configuration. [#900](https://github.com/poem-web/poem/pull/900)
11+
- feat: implement conversion from libcookie to poem cookie [#898](https://github.com/poem-web/poem/pull/898)
1012

1113
# [3.1.4] 2024-11-20
1214

0 commit comments

Comments
 (0)