William Cheng
a5f79a7bdc
[python] Update github workflow, use debug instead of warning ( #16565 )
...
* update github workflow, use debug instead of warning
* use debug instead of warn
2023-09-12 16:55:53 +08:00
William Cheng
dee536f7f7
import Annotated if needed ( #16521 )
2023-09-07 14:36:45 +08:00
jessemyers-lettuce
b34a10aee7
python: ignore long lines for model descriptions ( #16518 )
...
Descriptions can easily exceed line-length limits because they are often
extracted from doc/comments strings, which may use unexpected formatting.
Python doc strings, in particular, are likely to use newlines, which mustache
does not preserve, causing descriptions to be condensed to a single line.
2023-09-06 10:48:43 +08:00
jessemyers-lettuce
1b32088c2d
python: use isinstance instead of type() ( #16516 )
...
Use of `isinstance` is preferred (and validated by common linters).
2023-09-05 23:45:18 +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
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
b457c3de70
fix uuid example cast exception in python generators ( #16432 )
2023-08-29 13:34:54 +08: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
William Cheng
fd12bb3508
[python] Fix data type ( #16291 )
...
* fix data type in python client codegen
* add model mapping feature
2023-08-10 23:05:35 +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
f6fb83878b
[Default] update isAdditionalPropertiesTrue tag to cover more types ( #16227 )
...
* enhance additional properties support
* update samples
* update tests
* add more tests
* update samples
* fix samples
2023-08-05 13:32:43 +08:00
William Cheng
3278eea9a4
Add tests for #16217 ( #16221 )
...
* add tests for #16217
* add new files
2023-07-31 11:03:36 +08:00
ふぁ
77311c3d76
[python-nextgen] Fix allOf missing imports ( #16217 )
...
* [python-nextgen] fix allOf missing imports
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] update samples
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] remove circular import
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] Fix circular refs
Signed-off-by: ふぁ <yuki@yuki0311.com>
---------
Signed-off-by: ふぁ <yuki@yuki0311.com>
2023-07-31 10:04:53 +08:00
William Cheng
526ca78e79
add tests for #16199 (python client) ( #16220 )
2023-07-30 01:19:11 +08:00
ふぁ
48ff57b4f6
[python-nextgen] fix #16010 circular refs lead to no imports ( #16199 )
...
* [python-nextgen] fix #16010 circular refs lead to no imports
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] update samples
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] remove unnecessary Postponed annotations
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] update samples
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] remove unnecessary Postponed annotations
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] update samples
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] update samples
Signed-off-by: ふぁ <yuki@yuki0311.com>
---------
Signed-off-by: ふぁ <yuki@yuki0311.com>
2023-07-30 00:42:46 +08:00
William Cheng
d41fe12c1f
[python] Add tests for simple object with additional properties ( #16218 )
...
* add tests for simple object without additional properties
* update logic
2023-07-29 11:43:37 +08:00
ふぁ
d9fc039dcf
[python-nextgen] fix #16151 Disallow additional properties if not present - missing Any and Dict import ( #16208 )
...
* [python-nextgen] fix #16151 Disallow additional properties if not present - missing Any and Dict import
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] update samples
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] remove unwanted imports
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] update samples
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] remove unwanted imports
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] update samples
Signed-off-by: ふぁ <yuki@yuki0311.com>
---------
Signed-off-by: ふぁ <yuki@yuki0311.com>
2023-07-29 10:51:28 +08:00
ふぁ
e411b2ac0a
[python-nextgen] Add type to actual instance ( #16204 )
...
* [python-nextgen] add type to actual_instance
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] update samples
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] fixed unnecessary type conversions
Signed-off-by: ふぁ <yuki@yuki0311.com>
* [python-nextgen] update samples
Signed-off-by: ふぁ <yuki@yuki0311.com>
---------
Signed-off-by: ふぁ <yuki@yuki0311.com>
2023-07-29 10:08:06 +08:00
William Cheng
7dee666826
add python name mapping support ( #16120 )
2023-07-20 17:30:01 +08:00
William Cheng
08c3f8973e
[python] Fix array of array of model's to_dict, from_dict ( #16032 )
...
* fix array of array of model's to_dict, from_dict
* update samples
2023-07-08 14:12:42 +08:00
William Cheng
b42234eb3c
[python] Fix map of array in property ( #15844 )
...
* fix map of array in property (python)
* update samples
2023-06-15 11:50:56 +08:00
William Cheng
d2e10a7229
install urllib3 < 2.1.0 ( #15810 )
2023-06-12 15:58:51 +08:00
William Cheng
6788f43af0
Better handling of Inline schema ( #15682 )
...
* skip allOf inline subschema created as $ref
* add option for fallback
* add back atleastonemodel
* add log
* update java, kotlin, js samples
* update tests
* fix native client test
* fix java client errors by regenerating test files
* clean up python
* clean up powershell
* clean up php
* clean up ruby
* update erlang, elixir
* update dart samples
* update ts samples
* update r, go samples
* update perl
* update swift
* add back files
* add back files
* remove outdated test files
* fix test
2023-06-11 15:35:58 +08:00
William Cheng
21748e024a
add py.typed ( #15804 )
2023-06-10 21:48:54 +08:00
William Cheng
1fb0ab997f
[Python] fix access_token set to None when constructing Configuration object ( #15802 )
...
* clean up files
* add tests for access_token
* fix bug with access_token
* update test method name
2023-06-10 19:22:02 +08:00
gyoganathan
fc474eab5f
Added BadRequestException as a subclass in python ( #15722 )
...
Co-authored-by: Gomathi Yoganathan <gyoganathan@C02G45FPMD6R.corp.proofpoint.com>
2023-06-10 15:27:18 +08:00
Tiffany Marrel
c2f635a330
fix use of isBasic and isBasicBasic and isBasicBearer and isHttpSignature in documentation ( #15443 )
...
* [ada] fix use of isBasic condition
* [apex] fix use of isBasic condition
* [asciidoc] fix use of isBasic condition
* [python] fix use of isBasic condition
* [csharp C#] fix use of isBasic condition
* [htmlDocs] fix use of isBasic condition
* [Ruby] fix use of isBasic condition
* [scala] fix use of isBasic condition
* [julia] fix use of isBasic condition
* [Objective-C objc] fix use of isBasic condition
* [GraphQL] fix use of isBasic condition
* [MarkDown] fix use of isBasic condition
2023-06-01 09:47:00 +08:00
William Cheng
48ef91acc4
[python] Add test for nullable property with pattern ( #15625 )
...
* add test for nullable property with pattern
* update samples
2023-05-24 15:13:53 +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
William Cheng
0c3460f95b
Merge remote-tracking branch 'origin/master' into 7.0.x
2023-05-10 15:00:56 +08:00
Tiffany Marrel
c251202869
[Python] cleanup documentation ( #15301 )
...
* [Python] fix documentation of API authorization in README files
fix hierarchy level + add internal links + align wording across generators
* [Python] fix anchor links in documentation
2023-05-09 16:24:56 +00:00
Tiago Silva
56495d1486
Python Allow clients to define TLS Server name when using ( #15283 )
...
This PR allows users to define custom SNI when using the python clients
Fixes https://github.com/OpenAPITools/openapi-generator/issues/15282
2023-05-05 16:11:57 +08:00
William Cheng
5d1e18306a
Prepare 6.6.0-SNAPSHOT ( #15100 )
...
* set 6.6.0 snapshot version
* update samples
* update readme
2023-04-01 18:48:01 +08:00
William Cheng
7417432a54
Prepare 6.5.0 release ( #15099 )
...
* 6.5.0 release
* update samples
2023-04-01 15:03:35 +08:00
William Cheng
1beec7ef87
Merge remote-tracking branch 'origin' into 7.0.x
2023-03-03 21:52:50 +08:00
William Cheng
c50a775e0c
prepare 6.5.0 release ( #14749 )
2023-02-19 20:36:23 +08:00
William Cheng
93df0ff444
Prepare 6.4.0 release ( #14748 )
...
* prepare 6.4.0 release
* update samples
2023-02-19 18:53:20 +08:00
Beppe Catanese
68b944e6e6
Preserve order of securitySchemes ( #14536 )
...
* Remove alphabetical sort
* Update integration testing expectations
* Regenerate files
2023-02-10 22:20:19 +08:00
William Cheng
31a89e35cb
Prepare 6.4.0 ( #14582 )
...
* update to 6.4.0 snapshot
* update samples
* update doc
2023-02-01 22:44:40 +08:00
William Cheng
8f2676c5c2
Prepare v6.3.0 release ( #14580 )
...
* 6.3.0 release
* fix maven plugin test
* update samples
* update doc
* fix tests in windows
2023-02-01 20:52:29 +08:00
Justin Black
45b1f91807
[python] Fixes Response TypeError ( #14299 )
...
* Fix and sample regen
* Response with only header added, sample regnerated
2022-12-20 12:42:10 -08:00
Justin Black
28ae689615
[python] Fixes Configuration w/ access_token at initialization ( #14153 )
...
* Fixes templates
* Samples regenerated
* Adds discard_unknown_keys back in, regenerates samples
2022-11-30 11:09:31 -08:00
Justin Black
871eda2731
[python] exposes deserialized bodies for non-2XX responses ( #14095 )
...
* Template update and sample update
* Samples regenerated
* Adds verification test
* Template update
* Samples regen, fixes exception instantiation
2022-11-22 09:35:26 -08:00
Justin Black
1748d03fb9
[python] Issue 13997 fix pass in model instances to new ( #14067 )
...
* Template update
* Adds test file
* Samples regenerated
* Adds missing #
2022-11-18 15:04:26 -08:00
Mustansir Soni
4667b7e471
[ #13954 ] Allows args and arg as schema properties in python client ( #13955 )
...
* Add args to reserved words
* arg and args to _arg and _args in templates
* Corrections
* Test added
* Corrections
* Use arg and args as defined properties
* Removed unnecessary assertion
* Suggested change
2022-11-09 11:10:29 -08:00
Nathan Baulch
9f1fa0e440
Fix another batch of spelling typos ( #13915 )
...
* Fix typos
* Remove repeated words
* Minor grammar fixes
2022-11-07 21:30:24 +08:00
Justin Black
b35ea31e82
[python] fixes multipart/form-data bug ( #13926 )
...
* api_client template updated
* Samples regenerated
* Fixes tests
* Adds missing test file
* Adds test fix
2022-11-05 09:10:24 -07:00
William Cheng
558ae9373d
Merge remote-tracking branch 'origin/master' into 7.0.x
2022-11-01 21:01:06 +08:00