20 Commits

Author SHA1 Message Date
loic-seguin
b01c8be47f
bugfix: generate correct setup.pi when no paths are specified (#20098) 2024-12-17 10:58:26 +08:00
Pascal Bachor
619e4d9653
Harmonize python client dependency versions (#19694)
Co-authored-by: Pascal Bachor <bachorp@users.noreply.github.com>
2024-10-03 14:09:39 +08:00
Mike Phillips
34aeb16c5e
Improve urllib3 semver flexibility (#19458) 2024-09-18 16:54:43 +08:00
Jonathan Ballet
03781d3a93
python: remove aenum in favor of stdlib's enum (#16691)
The aenum dependency didn't provide any specific improvements over the
stdlib's enum module.
aenum also doesn't provide typing information at the moment.

This removes one dependency and will help for completing the typing of
the generated client.
2023-10-01 21:22:42 +08:00
Jonathan Ballet
04fa53b692
python: generate Pydantic v2 + typing complete code (#16624)
* python: improve type generation with more specific typing

* Annotate function parameters

* Remove unused imports

* remove unused files

* remove temporary hack

* remove lock file

* fix Annotated import

* support Python 3.7

* Regenerate code with typing-extensions

* Fix setup.py

* More Pydantic v2 compatibility

* depend on pydantic v2

* fix client_echo tests

* fix JSON serialization

* Fix references

* Skip circular dependency tests for now

* Temporarily hide the "float" property

The "float" property aliases the "float" type and completely breaks the
model: all the properties that were "float" now become the type of the
"float" property instead.

* Fix errors

* Import Literal from typing_extensions

* Fix GitHub Action workflows

* Fix Python 3.7 failure

* Fix quotes

* Apply suggestions from code review

* Fix tests

* split model imports from other modules imports

* fix workflow

* Comment the array unique items convertion, remove set translation

* Replace alias usage
2023-09-28 19:13:14 +08:00
ふぁ
f3b930c48c
[python-nextgen] Fix noqa: E501 position (#16280)
* Fix `noqa: E501` position

Signed-off-by: ふぁ <yuki@yuki0311.com>

* [python-nextgen] update samples

Signed-off-by: ふぁ <yuki@yuki0311.com>

---------

Signed-off-by: ふぁ <yuki@yuki0311.com>
2023-08-08 20:42:12 +08:00
William Cheng
d2e10a7229
install urllib3 < 2.1.0 (#15810) 2023-06-12 15:58:51 +08:00
William Cheng
21748e024a
add py.typed (#15804) 2023-06-10 21:48:54 +08:00
William Cheng
01ed5975e1
rename python-nextgen to python (#15504) 2023-05-16 13:54:07 +08:00
William Cheng
780d266fe1
Decommission python client generator (#15486)
* decomission python client generator

* udpate

* update doc
2023-05-14 16:33:13 +08:00
Justin Black
ef8e55ca21
[python] client bug fixes + type hint improvements (#13665)
* Adds python client, template, and spec updates for query param content type json

* Samples regenerated

* Finishes adding test cases for query param json content type

* Uses newest templates

* Templates replaced, spec replaces, sample replaced

* Samples updated
2022-10-10 20:13:31 -07:00
Justin Black
7e73645303
Switches python-experimental in as the primary python client (#13501)
* Changes python to python-prior

* python -> python-prior, python-experimental->python

* Renames sample spec directories

* Samples regnerated

* Regenerates docs

* Fixes test

* Samples regenerated

* Updates renerators list

* Fixes made to python paths in pom.xml

* Fixes node4 sh file paths
2022-09-24 16:19:38 +08:00
Justin Black
2553d056dc
Removes nulltype from python, updates samples (#8555)
* Removes nulltype from python, updates samples

* Removes nulltype from the python requirements

* Removes nulltype import in models, moves requiredVars to optionalVars when approprieate
2021-01-28 09:30:36 -08:00
Robert Parini
a4f84b2f8c
[Python][Client] Default to system CA instead of certifi (#8108)
* Use system CA by default and remove certifi

See https://github.com/OpenAPITools/openapi-generator/issues/6506

* Use system CA by default in asyncio client

* Update README_onlypackage.mustache

* Result of ./bin/generate-samples.sh

* Add ssl_ca_cert argument for Configuration

* Result of ./bin/generate-samples.sh

* Remove certifi, use system CA by default
2020-12-15 16:36:35 -08:00
Ülgen Sarıkavak
e00ac502f1
[python] Update python versions (#8042)
* Remove redundant encoding definitions

UTF-8 is already the default encoding in Python 3.

* Remove Python3.4 related requirements

* Remove dead Python version 3.5

* Add Python 3.9 to CI and test configs

* Update petstore example
2020-12-07 12:07:35 -08:00
William Cheng
3bf8ca7484
[python] Renames python generators (#7965)
* python->python-legacy, python-experimental->python

* test with openjdk8

* test with openjdk11

* comment out rm

* move kotlin tests to circleci

* move kotlin tests

* move tests to circleci

* fix circleci

* rearrange test

* move tests

* use wrapper

Co-authored-by: Justin Black <justin.a.black@gmail.com>
2020-11-18 14:34:00 +08:00
Sai Giridhar P
ea600989f7 [python][metadata]: Adding license and author fields (#4318)
* fix(license): Fixing the license and author information

* fix(license): Fixing the license and author information

* fix(metadata): Adding default values for contact details and license fields

* fix(metadata): Adding default values for contact details and license fields
2019-11-03 14:58:39 +08:00
Jim Schubert
ee7c8a82e8
[BUG][CLI][GENERATOR] NullPointer when not setting outputDir (updated) (#3752)
* Fixes NPE when no outputDir is set

* Fix behaviors of default values for values not provided by user

* Easier handling of default behavior in settings.

* Fixes for dynamic config deserialization (specifically, ruby client sample fix)

* Tests for WorkflowSettings (defaults, modified defaults, nulls)

* Test modification of WorkflowSettings defaults for both class constructor and builder
2019-08-25 19:19:52 -04:00
William Cheng
dc0c24b955
Minor wording change (#2875)
* better wording for version of openapi doc

* update petstore samples
2019-05-13 15:59:59 +08:00
William Cheng
7811390b7b
Add multiple servers support to Python client (#1969)
* add multiple server support to python client

* various fixes

* minor fixes, add tests

* test oas2 python first

* fix tests

* fix issues reported by flake8

* update code format

* add python petstore to ensure up-to-date

* rearrange test

* fix E501

* fix tests

* add new files

* fix script permission

* fix index check

* update samples
2019-01-28 11:24:48 +08:00