[Python] - Migrate enable per request authentification in new python codegen#11279
Merged
spacether merged 13 commits intoOpenAPITools:masterfrom Mar 20, 2022
Conversation
Can now overwrite request auth by request Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
…sent Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
Contributor
|
Ce-running circleci tests |
Contributor
Author
|
Hi @spacether, Is there something special to do to re-launch the circle ci pipeline ? Yours faithfully, |
Add None when _content_type is not set Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
Add _request_auth in sample Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
Contributor
Author
|
Hi, I have this error in the CI, I don't understand why. Could you please help me out @spacether ? |
Request auth is now a list of dict Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
Contributor
|
Hi @LeComptoirDesPharmacies sorry for my delay in reviewing this here. Your PR generally looks good but one CI test is failing (test_test_endpoint_enums_length_one). Can you fix it? |
Envoyé depuis mon iPhone. P.S. : Ce commit est certifié sans gluten
Contributor
Author
|
Hi, |
spacether
approved these changes
Mar 20, 2022
Contributor
spacether
left a comment
There was a problem hiding this comment.
Thank you for your PR. This looks good!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Can now overwrite request auth in request
Actually in current python codegen, authentification is managed in api configuration.
But when you instantiate a new configuration, a new thread poll is create with it, so each time you need to change your authentification key, you will create a thread poll which will pull down the performance of the application.
We could have a global configuration and change the authentification but it will not be thread safe.
The solution was already developed in python-legacy but it has not be migrated. ( In this PR #6569 )
PR checklist
This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master.
These must match the expectations made by your contribution.
You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example
./bin/generate-samples.sh bin/configs/java*.For Windows users, please run the script in Git BASH.
master(5.3.0),6.0.x@taxpon (2017/07) @frol (2017/07) @mbohlool (2017/07) @cbornet (2017/09) @kenjones-cisco (2017/11) @tomplus (2018/10) @Jyhess (2019/01) @arun-nalla (2019/11) @spacether (2019/11) ❤️
Thanks for the review