9299 Commits

Author SHA1 Message Date
Colin Arnott
080991823a [Go] Upgrade dependencies (#4126)
antihax/optional#1 added module support, and was tagged as a stable
release. This change consumes that tag, and updates the psuedo-version
for golang.org/x/oauth2.
2019-10-17 20:09:02 +08:00
siada
6af234f79a [typescript-inversify] Fix multipart form uploads (#4131)
* Fix multipart form uploads

* Update modules/openapi-generator/src/main/resources/typescript-inversify/HttpClient.mustache

Co-Authored-By: Esteban Gehring <esteban.gehring@gmail.com>

* re-generate samples
2019-10-17 13:50:10 +02:00
sunn
f901a84743
Update tests to prevent memory leakage (#4164)
Install C and C++ tools in Travis
2019-10-17 11:48:35 +02:00
wing328
4de3b3f473 update samples 2019-10-17 11:48:23 +08:00
wing328
54151891cc Merge branch 'master' into 5.0.x 2019-10-17 11:18:57 +08:00
William Cheng
9eb3c4fa7a
Add Petstore samples for dart-dio (#4162)
* Add samples for dart-dio

* use dartmft
2019-10-17 11:15:17 +08:00
William Cheng
60d601ee26
[Python] Minor fix to code format (#4172)
* test python e501 fix

* 2 spaces

* fix format with noqa: E501

* fix format, update samples
2019-10-17 02:34:04 +08:00
Jeremie Bresson
f763b6dce3 Update samples 2019-10-16 13:42:03 +02:00
Arun
d71b1cf49e [python] Add option to skip client validations (#4137)
* Adds options to skip client side validations

* Runs petstore.sh

* Correct typo in variable name

* Consistent code styling

* Rerun petstore.sh

* Change position of local_vars_configuration

* Make code pep8 compliant
2019-10-16 15:44:04 +08:00
Arun
095fa719b3 [python] Remove post_params and body from OPTIONS request (#4163)
* Remove post_params and body from OPTIONS

* Empty commit to retrigger build
2019-10-16 15:34:22 +08:00
Arun
1786e75490 Skip adding None value in query parameters (#4161) 2019-10-16 15:15:14 +08:00
Esteban Gehring
f195f8ff7a
typescript-rxjs: fix query parameters type (#4160)
* #4159: fix typescript-rxjs query parameter type

* re-generate typescript-rxjs samples
2019-10-16 08:44:38 +02:00
William Cheng
672a7e9c60 update samples 2019-10-16 02:52:04 +08:00
sunn
83fdc6e752
[C++] [Qt5] Add generation of cmake files to qt5 client (#4133)
* Add generation of cmake files to qt5 client

* Update after review
2019-10-15 15:59:45 +02:00
Josh Burton
755a6f4445 Adds Dart Dio generator (#4018)
* Adds initial implemenation of dart-dio generator

* Adds remaining boilerplate for dart-dio generator
2019-10-15 21:05:38 +08:00
Benoît Courtine
dd08ea7a6b [Rust] [Fix #3052] Handle optional and nullable parameters (#4016)
This PR includes theses changes:

- Handling "optional" parameters is not optional anymore. Handling an additional parameter for it makes templates more complicated, and IMO, it is not worth it (as discussed in issue, it is an "acceptable" breaking change).
- Optional parameters are handled everywhere: path params, query params, form params... Generated sample code compiles (both hyper and reqwest libraries).
2019-10-15 13:59:37 +01:00
Arun
c1d5fe0c77 Run all test cases against petstore server (#4150) 2019-10-15 14:54:24 +08:00
Hippolyte HENRY
3693d60840 Add newline between function signature of operation and summary of operation (#4112)
* Add newline after function signature

* update Petstore

* [go] Add newline after function signature

* update petstore
2019-10-15 14:46:45 +08:00
sunn
450153d4e0 Add missing supporting files when prefix is provided (#4132) 2019-10-15 14:45:08 +08:00
William Cheng
9c6b94c292 update samples 2019-10-15 02:00:10 +08:00
Thiago Arrais
cb2bf4d2bf Do not check status code for default response (#3322)
* Do not check status code for default response

* Updated generated code/docs

Because Circle CI said

> Please run 'bin/utils/ensure-up-to-date' locally and commit
> changes (UNCOMMITTED CHANGES ERROR)
2019-10-15 01:29:46 +08:00
Zbigniew Mandziejewicz
2cab048d41 [go-experimental] export required fields without pointer (#3989)
* [go-experimental] export required fields without pointer, only omitempty if type is not required and not nullable

* fix: go-experimental sample code

* fix: export nullable field as pointer

* update samples

* feat: nullable types

* add getter/setter for required fields, improve docstring
2019-10-15 01:19:47 +08:00
gurumeditator
dee6de7778 Replaced dashes with underscores in build.gradle files. (#4092) 2019-10-13 18:37:50 +08:00
Colin Arnott
3274592e29 [Go] Fix go.mod and go.sum for 1.13 (#4084)
The openapi-generator-cli currently creates an invalid go.mod file,
according to the go1.13 compiler. This change uses the correct pseudo
version without upgrading or modifying either dependency. It also adds
several missing go.sum dependencies that will break when the toolchain
is run in -mod=readonly mode.
2019-10-10 21:59:53 +08:00
Bruno Coelho
3cd74f4a8d [kotlin] add option for non public api (#4089)
* [kotlin] add option for non public api

* [kotlin] update petstores

* [kotlin] add missing script to kotlin-client-all.sh

* [kotlin] update pet projects

* [kotlin] remove public modifier

* [kotlin-client] inline visibility modifier
2019-10-10 21:56:40 +08:00
Alexander Lehmann
4d32e65c24 [JAVA][JAXRS] Fix parameters validation (#3862)
* [JAVA][JAXRS] Improved formatting of *Params.mustache files

Signed-off-by: Alexander Lehmann <alexander.lehmann@tracetronic.de>

* [JAVA][JAXRS] Added validation to path/query-Params

Fixes #3861

Signed-off-by: Alexander Lehmann <alexander.lehmann@tracetronic.de>

* [JAVA][JAXRS] Regenerate examples

Signed-off-by: Alexander Lehmann <alexander.lehmann@tracetronic.de>
2019-10-10 21:21:17 +08:00
Thomas Joeissient
a13543e859 Make Resttemplate thread safe by using the withHttpInfo pattern used by many other generated clients (#4049) 2019-10-10 21:18:29 +08:00
Anders Fogh Eriksen
9f82755696 Disabling linting for typescript-fetch (#4110)
* Disabling linting for typescript fetch

* Update petstore

* Update samples

* Fix typescript-fetch samples
2019-10-10 14:43:08 +02:00
William Cheng
b69b8cdd31
[Kotlin][Client] fix missing curly bracket when the model contains enum property (#4118)
* fix kotlin okhttp3, add CI test

* update kotlin server sample
2019-10-10 18:21:50 +08:00
William Cheng
3141e483ef
Fix NPE in Elm path parameter (#4116)
* fix NPE in elm path parameter

* replace paramName with baseName

* install elm format in circleci

* switch to /usr/bin/env
2019-10-10 18:20:46 +08:00
William Cheng
661fb42a06 add back ruby client folders 2019-10-10 11:07:50 +08:00
William Cheng
0d91be3a72 update petstore samples 2019-10-10 10:27:13 +08:00
Jim Schubert
54d7e8c488
[CLI] Initial implementation for batch generation (#3789)
* [CLI] Initial implementation for batch generation

Allows for generating multiple outputs via config. Just specify multiple
config files on command line.

Intent for this is to reduce CI times to generate outputs as well as to
reduce time for users to run ensure-up-to-date to meet PR standards.

Example command:

  openapi-generator batch --includes-base-dir `pwd` --fail-fast  -- bin/ci/*

---

As part of this implementation, the batch command support a customized
JSON key, `!include`. If this key's value refers to an existing file,
that file's contents are "unwrapped" into the config during
deserialization. This allows us to easily point to the same configs used
by our sample scripts without modifying the CLI generate task's switches
or assumptions.

* Allow for path-relative outputs
* Add batch JSON objects
* Include INFO log about threads used and includes/root
* Ensure GlobalSettings.reset()
* Improved thread-safety of ModelUtils
2019-10-09 12:51:52 -04:00
Martin Weber
e24030be52 fix nullable for arrays and complex types (#4106)
change csharp folder parameter from "SwaggerClient" to "OpenAPIClient"
2019-10-10 00:23:19 +08:00
Erik Timmers
8cc708011b [elm] Add toString for all types (#3983) 2019-10-09 23:34:51 +08:00
William Cheng
e9a0a51b50
Fix file type in avro template (#4105)
* fix file type in avro template

* update doc
2019-10-09 20:22:57 +08:00
Akira Tanimura
08613691e8 fix enum which is not string of Go (#4077) 2019-10-09 18:35:56 +08:00
Bruno Coelho
7a369d3b02 [kotlin-client] Add support okhttp3 and Android 4.x (#4008)
* [kotlin] support okhttp3

* [kotlin] create okhttp3 sample

* [kotlin-client] rename HttpClient to HttpLibrary

* [kotlin] move okhttp 3 to library model

* [kotlin] fix okhttp3 version

* [kotlin] fix kotlin client jvm okhttp3

* [kotlin] fix wrong spacing in okhttp3 code

* [kotlin] update okhttp3 sample to use parcelize models

* [kotlin] readd jvm tag
2019-10-09 16:38:07 +08:00
Perennes
87c77076ef [AVRO] Fix the package handling for the avro generator (#3987) (#4078)
* [AVRO] Fix the package handling for the avro generator (#3987)

Also fix an issue with the outputFolder that wasn't overridable through opts

* Update sample files through avro-petstore.sh

There's an issue with inlined object but it's already present with the previous commit

* Revert the fix on outputFolder (not a bug)
2019-10-09 15:46:29 +08:00
tkrtmy
4e47426224 typescript-fetch: fix empty URLSearchParams request body (#4103)
* typescript-fetch: correct handling body as URLSearchParams

* typescript-fetch: run typescript-fetch-petstore-all.sh

* typescript-fetch: add URLSearchParams to globals
2019-10-09 09:43:54 +02:00
Jan
bbfcd3bf64 [kotlin-client][kotlin-server] Feature/kotlin data class serial version uid (#4021)
* feat: add companion object to data classes if the implement the interface java.io.Serializable

* style: format template file

* style: adapt to project's original code style

* fix: add missing imports

* style: reverted mustache template to original styling

* test: generate additional samples for kotlin-springboot-reactive and kotlin-springboot

* docs: name full qualified classname of interface java.io.Serializable to prevent confusion with kotlinx.serialization
2019-10-09 15:17:53 +08:00
William Cheng
cf38c56aa6
Fix readonly with isReadOnly (#4102)
* fix readonly

* update samples
2019-10-09 15:16:22 +08:00
oharaandrew314
682af7c4f3 Add DELETE with body to kotlin client (#4047)
* delete with body

* update petstore sample

* update kotlin-threetenbp sample

* update sample for kotlin-client-string
2019-10-09 00:10:57 +08:00
William Cheng
8f86f0f04a Merge remote-tracking branch 'origin/4.2.x' into 5.0.x 2019-10-08 21:21:04 +08:00
Mateusz Szychowski (Muttley)
991e0bf821 [C++][Pistache] Use optional when required (#4082)
* [C++][Pistache] Include pistache/optional only when required

* [C++][Pistache] Update Petstore sample
2019-10-07 12:27:45 +02:00
Slavek Kabrda
5234139814 [java][client] Fix regression in Java XML serialization. Fixes #4014 (#4023)
* Fix regression in Java XML serialization. Fixes #4014

* Also move JSON_PROPERTY_* declaration
2019-10-07 17:50:55 +08:00
Gabriel Féron
f96ed69c26 Add rust discriminator (#3895)
* Add support for the `discriminator` feature of OpenAPI 3, and implement it with `enum` in Rust
* Add all missing explicit `dyn` to trait types to remove warnings
* Add missing re-export for properties that are enum (was missing from #2244).
2019-10-06 17:35:14 +01:00
Jon Schoning
a979fd8e13
[haskell-http-client] update samples (#4073) 2019-10-05 13:28:52 -05:00
Akshay Mankar
25e1f5e1c3 [haskell-http-client] Bump deps to LTS 14.7 (#4068) 2019-10-05 13:24:38 -05:00
William Cheng
61abe6332b Merge branch 'master' of https://github.com/OpenAPITools/openapi-generator 2019-10-04 16:52:36 +08:00