20391 Commits

Author SHA1 Message Date
Martin Boos
ae069e6840
[Python] Update python-pydantic-v1 generator to respect the --git-host argument (#19404)
* Update pyproject.mustache

chore(pyproject): replace static `github.com` with variable `{{{gitHost}}}`

* chore: follow contribution guidelines
2024-08-22 15:52:36 +08:00
mohamuni
deb007b976
fix regex breakage in unmarshaljson function (#19410) 2024-08-22 15:12:54 +08:00
julianladisch
87704b28c0
Upgrade commons-io dependency to latest 2.16.1 (#19414) 2024-08-22 14:59:20 +08:00
Bruno Coelho
b3f74c7c4f
[typescript][angular] move app description from license info to readme (#19397)
* [typescript][angular] move app description from header license info to readme

* [typescript][angular] move app description from header license info to readme
2024-08-21 13:51:39 +02:00
Richard Whitehouse
eda4547f15
[Rust Server] Fix up model generation (#19363)
* [Rust Server] Fix up model generation

- Correctly generate anyOf/oneOf models
- Fix up ToString / FromStr support
- Disable PartialOrd generation for anyOf/oneOf models
- Generate models for inline enums
- Support enums in headers, and vectors of models in headers

* [Rust Server] Add test for anyOf with additional properties

* Update samples

* [Rust Server] Tidy up logging
2024-08-21 15:14:52 +08:00
Rory Schadler
cc98333d87
feat(python): handle multiple file parameters (#19329)
* test: fix broken python test

* fix: handle multiple file parameters

Previously an array of files was not handled correctly, despite the type
annotation implying it was.

* feat: handle filename,filedata tuples in file param

This allows for users to pass filenames with their data in file params,
which is useful for multipart formdata requests. Without this, the list
of files added in the previous commit would have the same filename for
all files (the parameter name).
2024-08-21 15:09:10 +08:00
William Cheng
c2472b03b6 update doc to v7.8.0 2024-08-19 16:19:49 +08:00
William Cheng
91da2fd240
Prepare 7.9.0 snapshot (#19386)
* Revert "v7.8.0 release (#19385)"

This reverts commit 6bdc452f92d49dcac7ac21dfe8751c8cc4267b98.

* update samples for v7.9.0-snapshot
2024-08-19 16:14:51 +08:00
William Cheng
6bdc452f92
v7.8.0 release (#19385) v7.8.0 2024-08-19 14:01:58 +08:00
William Cheng
fc8b7d92c8
Fix Reactive Spring build.gradle.kts (#19382)
Co-authored-by: Erik VanderWerf <eski787@gmail.com>
2024-08-18 18:34:16 +08:00
Richard Whitehouse
df2b4210c9
[Rust Server] Sort operations so that the ones with fewest params come first (#19368)
* [Rust Server] Sort operations so that the ones with fewest params come first

This resolves things correctly per
https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.3.md#pathsObject
- "When matching URLs, concrete (non-templated) paths would be matched
before their templated counterparts."

* Update samples

* [Rust Server] Fix tabs vs spaces

---------

Co-authored-by: Rob Day <Robert.Day@metaswitch.com>
2024-08-18 18:01:19 +08:00
Kensuke Taguchi
fd62e3897b
[kotlin-client] Add @JsonEnumDefaultValue annotation to enum class (#19380) 2024-08-18 08:27:43 +01:00
Richard Whitehouse
0a5c99739a
[Rust Server] Allow configuration of multipart/form attachment size limit (#19371)
* [Rust Server] Allow configuration of multipart/form attachment size limit

multipart 0.14+ imposes a 8MB size limit on multipart/form bodies.

This allows that limit to be configured. The default is left as is.

This also improves error messages produced when handling multipart/form bodies.

* Update samples
2024-08-17 16:02:20 +08:00
William Cheng
bb831dad9a
Make the rust hyper client Send so it can be used in rust threads more easily (#19375)
* Add externCrateName property to rust hyper client

This is follows the lead of the rust hyper server generator and provides
an externCrateName. This is because the crate name used for importing
can be different from the package name, because dashes `-` get converted
to underscores `_`.

This allows us to write example code in rustdoc that compiles
successfully.

* Get the rustdoc examples to actually compile

* Make rust hyper client thread safe

* Fix compile time issue with reqwest client test

* Add a test for thread safety

* Generate rust hyper samples

* Use https for petstore api to fix client tests

http://petstore.swagger.io/v2 is 301 redirecting to
https://petstore.swagger.io/v2 and this is breaking posts to the API.
When the client recieves a redirect it does not resend the POST data,
instead it switches to GET. This is in line with how browsers behave
when encountering a 301 redirect on a POST request.

* Make rust hyper client structs `Sync` too

This trait is also helpful in making the api work well with threads.

* Use a getCrateName function instead of adding more state

* update samples

---------

Co-authored-by: Krishna Rajendran <krishna@emptybox.org>
2024-08-17 16:01:11 +08:00
Richard Whitehouse
172fafe674
[Rust Server] Fix server-writing docs for rust-server (#19367)
* Fix server-writing docs for rust-server

Fix broken link in generated README for rust-server.

* Update samples

---------

Co-authored-by: Keith Wansbrough <Keith.Wansbrough@metaswitch.com>
2024-08-17 15:33:58 +08:00
Richard Whitehouse
fbe6c11903
[Rust] Ensure all features build as part of CI / Upgrade to Frunk 0.4 (#19364)
* [Rust] [CI] Build all features as part of CI

* [Rust Server] Update to frunk 0.4

* Update samples
2024-08-17 14:17:36 +08:00
Richard Whitehouse
caeb83c845
[Rust Server] Fix homepage URL in Cargo.toml (#19365)
This fixes a missing quote in Cargo.toml, which causes validation errors
2024-08-17 14:16:25 +08:00
Aleksander Baranowski
ba1d7255d0
fix mixed indent + move do to same line as start of loop (#19373) 2024-08-17 14:15:00 +08:00
William Cheng
a6a75e3501
Better handling of backtick in pattern (#19358)
* use x-go-datatag in go client model template

* add logic to handle backtick
2024-08-16 18:04:47 +08:00
Tim Quinn
cd02426648
Suppress Pattern annotation on property of type byte array (#19346)
* Suppress Pattern annotation on property of type byte array

Signed-off-by: Tim Quinn <tim.quinn@oracle.com>

* Straggler files from generated samples

* Add new format test to workflows

---------

Signed-off-by: Tim Quinn <tim.quinn@oracle.com>
2024-08-15 17:09:44 +08:00
Richard Whitehouse
024bbb7784
[Rust Server] Improve RFC 13341 compliance for multipart/related (#19355)
* [Rust Server] Improve RFC 13341 compliance for multipart/related

* Update samples
2024-08-15 17:04:59 +08:00
Richard Whitehouse
be09f8a868
[Rust Server] Use swagger/multipart_related support (#19354)
* [Rust Server] Use swagger/multipart_related support

* Update samples
2024-08-15 17:03:59 +08:00
llendi
38ebf0bb4e
[Java][OkHttp-Gson] fix: free form query parameters for okhttp-gson (#19226) 2024-08-15 17:02:59 +08:00
martin-mfg
05c10934ce
docs: update versions, fix links, remove broken camel.xml, update download counts (#19356)
* manually update version in documentation, remove camel.xml

... because it has the wrong generator version, it has the wrong generator name (should be "java-camel"), the generated code doesn't compile - and then I didn't check further

* improve automatic version updating

* fix one more Readme link

* update docker stats again
2024-08-15 17:02:34 +08:00
Richard Whitehouse
daf52229e3
[Rust Server] Refactor Mustache templates for request/response body handling (#19347)
* [Rust Server] Refactor Mustache templates for request/response body handling

* Update samples
2024-08-14 15:25:08 +08:00
William Cheng
8f7354a2a2
revert gradle extension version (#19351) 2024-08-14 15:22:10 +08:00
Fei Wang
2bf2d9bb56
Include licenseInfo for all the generated java code files (#19273)
* Include license info for all the generated java code files

* Re-base generate
2024-08-14 15:13:42 +08:00
Richard Whitehouse
b8001323f6
[Core] Consolidate Operation ID generation (#19339)
* [Core] Consolidate Operation ID generation

* Update samples
2024-08-14 15:12:26 +08:00
martin-mfg
58dd0305ce
[JAVA] use query parameter apikey if present (#19334)
* Fix #16362

* Update samples

* Undo formatting changes

* Revert whitespace changes in samples

* make it work

---------

Co-authored-by: Jason Boileau <jason@boileau.dk>
Co-authored-by: Jason Boileau <spraot@users.noreply.github.com>
2024-08-14 15:02:37 +08:00
Sylvain Joubert
d55525fbc4
[C++][Pistache] Fix 'unused-parameter' warning on Helpers.h file (#19315) 2024-08-14 14:34:11 +08:00
Sylvain Joubert
8af3ff2828
[C++][Pistache] Add error handlers overload taking the response object (#19314)
This allows overriders to have full access to the response object and
more finely control the error handling behavior.
For example, this enables the specification of a proper Content-Type in
case of custom format responses (application/json, ...)
2024-08-14 14:31:55 +08:00
condorcorde
e70a9564e0
[PowerShell] Fix missing Content-Type header on a 204 response (#19340)
* Allow for binary response content

* AllowNull for $ContentTypes

* Update PSApiClient.ps1
2024-08-13 15:20:46 +08:00
William Cheng
d340e15f1a update dart samples 2024-08-13 15:19:29 +08:00
Brenton Bostick
03d8c30183
fix invalid syntax in gitignore (#19341)
gitignore only supports line comments, not in-line comments
2024-08-13 15:11:30 +08:00
GeorgeFkd
2107e9ef8f
Added support for openapi-normalizer in the online version. (#19336)
* Added support for openapi-normalizer in the online version with a minimal test.

* removed comments and formatted code
2024-08-12 17:49:34 +08:00
Gergely Imreh
fdd2dc9651
python-asyncio: update retry factors for actual exponential retries (#19337)
* python-asyncio: update retry factors for actual exponential retries

As per the `aiohttp-retry` library's code[^1], the timeout is

```python
timeout = self._start_timeout * (self._factor ** attempt)
```

This means the previous setting with "start_timeout=0.0" would have
always just retried right away (0 timeout) regardless of the "factor" value,
and also, "factor=0.0" would never have increased the timeout, rather it
would have resulted in a 0 timeout regardless of the value of "start_timeout".

This double-zeroing effectively rendered exponential backoff to nothing (rather than
"retries" number of retries in quick succession.

The update is a quick fix to set the same default as in `aiohttp-retry`. In
the future this should likely be configurable (through extra Configuration settings perhaps?),
as not all APIs are created equal, but this works as a quick fix for making retries more effective.

[^1]: ba2169891f/aiohttp_retry/retry_options.py (L38-L65)

* updated example
2024-08-12 17:35:00 +08:00
Franck Arnulfo
d1b9f9284a
Fix issue https://github.com/OpenAPITools/openapi-generator/issues/19326 (#19328)
Try to fix issue https://github.com/OpenAPITools/openapi-generator/issues/19326
2024-08-12 15:26:11 +08:00
devhl-labs
5166765724
changed default sorting of samples (#19335) 2024-08-12 15:04:50 +08:00
devhl-labs
ad8a7d2a3c
[csharp] Change sorting default (#18942)
* change sorting default

* implement sorting options for all libraries

* rebuild tests

* build samples
2024-08-12 00:33:18 +08:00
condorcorde
6da3dc5c10
Allow for binary response content (#19331) 2024-08-11 22:48:03 +08:00
Tim Quinn
07baddfe12
Minor change to Helidon version handling allowing snapshot versions (#19320)
* Minor change to Helidon version handling

Signed-off-by: Tim Quinn <tim.quinn@oracle.com>

* Update modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/JavaHelidonCommonCodegen.java

Co-authored-by: martin-mfg <2026226+martin-mfg@users.noreply.github.com>

* Review comments: fix typo in comment

---------

Signed-off-by: Tim Quinn <tim.quinn@oracle.com>
Co-authored-by: martin-mfg <2026226+martin-mfg@users.noreply.github.com>
2024-08-09 15:59:57 +08:00
Richard Whitehouse
ad7acc30eb
[Rust/Rust Server] Fix example/test code (#19318)
* [Rust Server] Fix code so examples compile

Zero length arrays don't correctly type infer, so if we have no scopes, we need to not create a empty array

We need an authentication middleware - without it the code doesn't compile.

* Update samples

* [Rust Server] Remove trailing whitespace

* Update samples

* [Rust Server] [CI] Build all targets

* [Rust] Fix reqwest test
2024-08-09 15:54:58 +08:00
William Cheng
4b493358a8 update php samples 2024-08-07 18:09:11 +08:00
Stefan Koppier
aea536027c
[bugfix][kotlin-wiremock] fix problems with range responses (#19309)
* [kotlin] Target correct library in jvm-spring-webclient sample

* [kotlin] Fixed warning in jvm-spring-restclient

* [kotlin-wiremock] fixed issue 7193

* [kotlin-wiremock] fixed wrong implementation of fromResponse

* [kotlin-wiremock] forbidden API

* [kotlin-wiremock] fixed wrong workflow trigger
2024-08-07 18:04:05 +08:00
Pavel Miller
908eddea0b
Issue-19220: processing schema name is added to the list with names checked at recursing processing, so it prevent to endless recursive execution (#19221) 2024-08-07 17:48:14 +08:00
Şerban Ghiţă
539aab05a7
[BUG] PHP Client - ObjectSerializer::buildQuery flattens array params resulting invalid URL params (param=a&param=b vs param[]=a&param[]=b) #19233 (#19236)
* [BUG] PHP Client - ObjectSerializer::buildQuery flattens array params resulting invalid URL params (param=a&param=b vs param[]=a&param[]=b) #19233

* Added tests (replaced old provider data). This looks like a breaking change

* Fix space

---------

Co-authored-by: Serban Ghita <serban.ghita@virta.global>
2024-08-07 17:15:59 +08:00
Lajos Szoke
edc60db531
Add ConfigCat to the Companies/Projects using OpenAPI Generator section (#19304)
* Add ConfigCat to the Companies/Projects using OpenAPI Generator section

* Adding ConfigCat to the users.yml and adding a logo
2024-08-07 17:07:24 +08:00
Bruno Coelho
b803af5ddf
[typescript][angular] move api version from license info to readme (#19310)
* [typescript][angular] move api version from header license info to readme

* [typescript][angular] move api version from header license info to readme
2024-08-07 10:12:57 +02:00
congyuluo
f8a5051d9c
Refactored Identifiers (#19270) 2024-08-05 18:20:54 +08:00
William Cheng
eff3e6df53
[cpp-qt] Add option for download progress, add test (#19297)
* add option for download progress, add test

* add cmake file

* remove test

* update
2024-08-05 16:06:36 +08:00