19080 Commits

Author SHA1 Message Date
devhl-labs
c510ea4b3d
Ensured enum entry name is unique (#16484)
* ensured enum entry name is unique

* ensured enum entry name is unique
2023-09-04 23:28:32 +08:00
Tomohiko Ozawa
09704951f0
[Java][resttemplate] Enable access token refresh (#16485)
* use supplier to enable refreshing token

* update samples

* fix param name and doc

* update samples
2023-09-04 23:23:22 +08:00
William Cheng
47a85e880b
Add tests for http basic authentication in python client (#16488)
* add tests for http basic auth in python client

* add new files
2023-09-03 19:11:53 +08:00
devhl-labs
b59719a6ea
[csharp][generichost] Minor formatting changes (#16482)
* started source generator

* copy the options

* fixed visibility

* added new sample

* discarded changes to existing samples

* discarded changes to existing samples

* build new sample

* changed package name due to file path length limit

* reverted changes to manual tests

* fixed all new manual tests

* inject contexts into api

* only one JsonConstructor

* fixed spacing

* revert samples for easier merge master

* revert unnecessary change

* fixed formatting

* build samples

* reverting unintended commit

* fixing default value

* reverting unintended commit

* move minor formatting changes to different pr
2023-09-03 16:20:12 +08:00
devhl-labs
dad677f63d
[csharp][generichost] Remove unnecessary json options (#16483)
* started source generator

* copy the options

* fixed visibility

* added new sample

* discarded changes to existing samples

* discarded changes to existing samples

* build new sample

* changed package name due to file path length limit

* reverted changes to manual tests

* fixed all new manual tests

* inject contexts into api

* only one JsonConstructor

* fixed spacing

* revert samples for easier merge master

* revert unnecessary change

* fixed formatting

* build samples

* reverting unintended commit

* fixing default value

* reverting unintended commit

* removed unnecessary json option
2023-09-03 16:19:23 +08:00
William Cheng
6434c86afd
[php-nextgen] add php-nextgen client generator (#16480)
* php-nextgen first commit

* [php] Set minimal PHP version to ^8.0 (#14500)

* Set minimal PHP version to ^8.0

* Fix php-nextgen config

* Change stability to BETA

* Add phplint package (#15054)

* [php-nextgen] Rename folders to follow PDS skeleton (#15102)

* Change lib -> src, test -> tests folder

This will make build compliant to PHP-PDS skeleton.
Ref: https://github.com/php-pds/skeleton

* Refresh samples

* Exclude composer.lock from codebase (#15105)

Since client generator is library and not a project it makes sense
to exclude composer.lock from codebase by default.

Ref: http://getcomposer.org/doc/02-libraries.md#lock-file

* Add @generated tag to DocBlocks (#15106)

This tag in draft status right now(PSR-19), but I think we can leverage
from it already.

Ref: https://github.com/php-fig/fig-standards/blob/master/proposed/phpdoc-tags.md#55-generated

* update samples, doc

* update samples

---------

Co-authored-by: Yuriy Belenko <yura-bely@mail.ru>
2023-09-03 16:16:58 +08:00
William Cheng
ebc9bcda44
[java][native] Add tests for oneOf form parameters (#16487)
* add tests for oneOf form parameters

* update samples
2023-09-03 16:15:54 +08:00
William Cheng
69c3f567ce
[Swift] various improvements (#16481) 2023-09-02 20:13:01 +01:00
William Cheng
8c2de11ac2
[rust] fix nullable array (#16473)
* add tests for nullable array in rust

* fix nullable array in rust

* minor fix
2023-09-02 10:21:04 +08:00
William Cheng
a2177570b3 update python samples 2023-09-02 01:07:33 +08:00
jessemyers-lettuce
40731ed52d
python: several typing and style improvements (#16378)
* python: several typing and style improvements

The generated (python) code fails with several standard validation tools,
including `flake8`, `mypy`, and `autoflake`. While fixing every possible
violation -- especially wrto typing -- woudl be a project, some of the
changes are fairly easy.

 - The `autoflake` tool picks up on unused imports. These can just be removed.

 - The `mypy` tool picks up on numerious typing violations, especially if set
   to its strictest mode. As a starting point, all functions ought to annotate
   a return type, including constructors, even if the return type is `None`
   because otherwise the functions are omitted from type checking and it's
   impossible to make incremental progress towards adding types.

 - The `flake8` tool mostly finds whitespace and line-length issues; while
   line-length standards very, the source already includes several flake8
   ignores, so it seems safe to add a few more.

* Add generated files

* Restore imports used by `AbstractPythonCodegen.java`

* Update generated files
2023-09-02 01:03:02 +08:00
devhl-labs
c0abeceb85
[csharp] Fixed enum values with whitespace (#16316)
* fixed enum values

* build samples

* build samples

* revert samples for easier merge master

* fixed while not changing other generators

* changed logging

* minor change
2023-09-01 10:11:11 +08:00
William Cheng
c74ed98282
Fix indent lambda using \n as line break (#16464)
* fix indent lambda using \n as line break

* update tests

* more fix
2023-09-01 09:07:14 +08:00
Cliford
71b33db7ee
Fix global property separator (#16465) 2023-08-31 21:02:19 +08:00
William Cheng
07a5920b2f
fix slash in python aiohttp files (#16463) 2023-08-31 15:59:18 +08:00
William Cheng
72da3b2c76
fix slash in php gneerator doc/config (#16462) 2023-08-31 15:22:38 +08:00
William Cheng
5954daea18
[powershell] update doc to use backslash (#16460)
* add backslash, forwardslash lambda

* update api doc
2023-08-31 14:29:01 +08:00
Davy Durham
4a1c70f2f1
fix: python client generator didn't respect range response specification (#16451)
* bug: python client generator didn't respect range response specification (e.g. "1XX", "2XX", etx.).  Return values tended to become None as a result

* update samples

---------

Co-authored-by: William Cheng <wing328hk@gmail.com>
2023-08-31 10:15:30 +08:00
William Cheng
e73143d777
fix cast exception with uuid default (c) (#16449) 2023-08-31 10:03:20 +08:00
William Cheng
a0350c6533
Fix cast exception when handling example/default of UUID/Long type (#16450)
* fix cast exception when handling uuid example/default

* more cast exception fix

* better fix in example generator

* better code format

* better code format
2023-08-31 09:42:38 +08:00
William Cheng
bceae5695e
Fix model name being a type in TS abstract codegen (#16392)
* fix model name being a type in ts abstract codegen

* add a test

* better code format
2023-08-30 13:24:54 +02:00
Jim Simon
9cc5513a1c
Fix Issue 16385 (#16387) 2023-08-30 14:23:53 +08:00
martin-mfg
20692aa891
Properly handle mappings and import mappings after processOpts (#16216)
* make Java imports overridable

* fix for other dateLibraries

* complete core fix

* adapt test - step 1/2

* add unit test

* adapt test - step 2/2

* remove accidentally added file

* final small clean-up
2023-08-30 13:48:51 +08:00
EdithBirrer1
35f5852cc0
Fix null request body issue (#16376)
* suggestion how to fix #9217

* removed check for versions V2/v3

* removed useless import
2023-08-30 13:40:35 +08:00
William Caine
134dc98a71
fix: Using Map.Entry to avoid "reference to Entry is ambiguous" (#16445)
* fix: Using Map.Entry to avoid "reference to Entry is ambiguous"

when spec defines a model Entry it conflicts.  Also rest of mustache
uses  Map.Entry to matching it

* fix: Map.Entry - update samples
2023-08-30 12:57:53 +08:00
William Cheng
8386a6eaaf
[java] improve petstore tests with openapi v3 spec (#16447)
* regenerate tests in jersey2-java8 client

* update samples

* fix java google api client tests

* update java resteasy to use v3 spec for tests

* update java vertx to test with v3 spec

* update java resttemplate to test with v3 spec

* add new files

* regenerate jersey1 tests
2023-08-30 12:33:01 +08:00
William Cheng
611a60411b
fix cast exception in uuid default value (julia) (#16438) 2023-08-29 20:42:49 +08:00
William Cheng
b1564d8002
Fix UUID default value cast exception (swift5) (#16436) 2023-08-29 12:32:01 +01:00
ChengDaqi2023
b14f99df92
update golang.org/x/net v0.2.0 to 0.7.0 (#16148) 2023-08-29 18:51:32 +08:00
William Cheng
5ab1badbef
fix cast exception in default value of uuid (objc) (#16437) 2023-08-29 18:43:53 +08:00
William Cheng
9b6e6b3e49
Fix cast exception in uuid default value (haskell-http-client) (#16439)
* fix cast exception in uuid default value (haskell-http-client)

* better code format
2023-08-29 18:42:27 +08:00
William Cheng
b5867ebf2b
fix cast exception in array default value (java gen) (#16434) 2023-08-29 14:31:24 +08:00
martin-mfg
020415facc
add test to invoke each generator and catch simple crashes (#16425)
* add test

* remove unused imports

* remove SmartBear copyright line

* use 3.0 input
2023-08-29 13:35:45 +08:00
William Cheng
b457c3de70
fix uuid example cast exception in python generators (#16432) 2023-08-29 13:34:54 +08:00
William Cheng
1a654eba5c
better handling of null pointer in CodegenSecurity (#16433) 2023-08-29 13:33:35 +08:00
Yohei Kitamura
56105fbbe6
[ruby] Not symbolize header param keys to allow the usage of underscore ("_") character (#16396)
* [ruby] Not symbolize header param keys to allow the usage of underscore ("_") character

* use lambda to convert header key to a string if underscore is included
2023-08-29 10:42:53 +08:00
William Cheng
55252f4b25 update ruby samples 2023-08-28 15:17:05 +08:00
jumpei.yokota
21cbd1ab71
[Ruby] align indentation (#16423) 2023-08-28 15:08:50 +08:00
Wojciech Trocki
6310ecdb0f
issue15126: restore default support for golang generator (#15127) 2023-08-28 11:38:09 +08:00
Stephane Carrez
0dcd8b42b0
Fix 16417: [Ada] Server generation fails for some response types (#16421)
* Fix and improvement of Ada server code generator

- add support for EWS (Embedded Web Server)
- fix GNAT project to avoid depending on util_http but instead use util_aws or util_curl
- update server skeleton generation to handle more data types for the response
- add more explanation on the generated server README

* Rebuild the Ada client GNAT project
2023-08-28 10:18:50 +08:00
Robert Oschwald
ec835fbd94
Update kotlin-client okHttp3 api.mustache fixes 16410 (#16411)
- populate body into the ServerException message
2023-08-25 19:06:43 +01:00
Yoonho Go
0f8f18e727
Update api.service.mustache (#16406)
Fix miscast types. At compile time, it says it can't find toISOString because the parameter is of type string, because modifies the whole thing.
2023-08-25 10:41:22 +02:00
William Cheng
80121aa88f
Prepare v7.0.1 (#16409)
* prepare 7.0.1 in master

* update doc
2023-08-25 16:11:29 +08:00
y-tomida
c7100b9e61
wrap operand listOf (#16408) 2023-08-25 08:37:48 +01:00
William Cheng
c37fa8a4e8
prepare v7.0.0 release (#16407) v7.0.0 2023-08-25 15:05:29 +08:00
martin-mfg
ad7ce7cba6
fix scalatra on Windows (#16395) 2023-08-25 09:25:22 +08:00
Baptiste Le Morlec
26899ee59b
Adding model type hints for Python Flask (#16382)
Co-authored-by: Baptiste LE MORLEC <baptiste.lemorlec@stryker.com>
2023-08-24 20:49:28 +08:00
Felipe Crochik
9cda7b0965
use propertyBaseName instead of propertyName (#15668)
Since it is looking at the payload before the transformation it should use the "original name" and not the "generated name" for the property
2023-08-24 11:54:52 +02:00
Dan Leehr
35f6eec71d
Add supportedMediaTypes needed for kubernetes client (#16386)
* Add supportedMediaTypes needed for kubernetes client

https://github.com/kubernetes-client/javascript/issues/893

* Add generated files
2023-08-24 08:43:50 +02:00
William Cheng
91fc151451
Add mapping features to Julia generators (#16370)
* add mapping features to julia generators

* additional changes required for mapped names (#16383)

---------

Co-authored-by: Tanmay Mohapatra <tanmaykm@gmail.com>
2023-08-24 10:09:54 +08:00