-
-
Notifications
You must be signed in to change notification settings - Fork 6.9k
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
Bump Rust edition to 2021 and a few crates #18608
Bump Rust edition to 2021 and a few crates #18608
Conversation
@@ -38,8 +38,8 @@ serde_derive = "^1.0" | |||
serde_with = { version = "^3", default-features = false, features = ["base64", "std", "macros"] } | |||
{{/serdeWith}} | |||
serde_json = "^1.0" | |||
url = "^2.2" | |||
uuid = { version = "^1.0", features = ["serde", "v4"] } | |||
url = "^2.5" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
url = "^2.2" | ||
uuid = { version = "^1.0", features = ["serde", "v4"] } | ||
url = "^2.5" | ||
uuid = { version = "^1.8", features = ["serde", "v4"] } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
features = ["json", "blocking", "multipart"] | ||
{{/supportAsync}} | ||
{{#supportAsync}} | ||
{{#supportMiddleware}} | ||
reqwest-middleware = "0.2.0" | ||
reqwest-middleware = "0.3.1" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks for the PR. can you please take a look at https://github.com/OpenAPITools/openapi-generator/actions/runs/9002489911/job/24730910208?pr=18608 when you've time? |
@wing328 - I opened this PR too quickly, sorry for the churn. Fixing the build now :( |
Please take our time. Appreciate the PR to bump the dependencies to newer versions. If you need help, let me know. (ping me via Slack) |
d524d27
to
da88754
Compare
@@ -32,14 +32,13 @@ homepage = "{{.}} | |||
{{/homePageUrl}} | |||
|
|||
[dependencies] | |||
serde = "^1.0" | |||
serde_derive = "^1.0" | |||
serde = { version = "^1.0", features = ["derive"] } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using serde
with the derive
feature instead of serde_derive
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: serde_derive
hasn't been required in years at this point :) Even the serde
docs show using the derive
feature: https://serde.rs/derive.html#using-derive
features = ["json", "blocking", "multipart"] | ||
reqwest = { version = "^0.12", features = ["json", "blocking", "multipart"] } | ||
{{#supportMiddleware}} | ||
reqwest-middleware = { version = "^0.3", features = ["json", "blocking", "multipart"] } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reqwest-middleware
requires the same features as reqwest
@@ -29,19 +29,19 @@ impl From<(hyper::StatusCode, hyper::body::Body)> for Error { | |||
|
|||
impl From<http::Error> for Error { | |||
fn from(e: http::Error) -> Self { | |||
return Error::Http(e) | |||
Error::Http(e) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to return
@wing328 - PR is ready for a review |
[dependencies.reqwest] | ||
version = "^0.11" | ||
features = ["json", "blocking", "multipart"] | ||
reqwest = { version = "^0.12", features = ["json", "blocking", "multipart"] } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -174,7 +174,7 @@ pub {{#supportAsync}}async {{/supportAsync}}fn {{{operationId}}}(configuration: | |||
{{/bodyParams}} | |||
{{/hasBodyParam}} | |||
{{^hasBodyParam}} | |||
&"", | |||
"", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Clippy to the rescue :)
lgtm. thanks for the PR. |
* bump Rust edition to 2021, update a few creates * bump Rust edition to 2021, update a few creates
Bump Rust edition to 2021 and a few crates. Fixes: #18609
PR checklist
Commit all changed files.
This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master.
These must match the expectations made by your contribution.
You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example
./bin/generate-samples.sh bin/configs/java*
.IMPORTANT: Do NOT purge/delete any folders/files (e.g. tests) when regenerating the samples as manually written tests may be removed.
master
(upcoming 7.1.0 minor release - breaking changes with fallbacks),8.0.x
(breaking changes without fallbacks)