swagger-api / swagger-api/swagger-codegen-generators
Python asyncio client inconsistent
Nobody has claimed this yet.
- Dominant language
- Mustache
- Stars
- 299
- Forks
- 439
- PR merge metrics
- No merged PRs in 30d
Description
Hey,
I noticed some inconsistencies when using the v3 code generator for Python with the library asyncio:
- refresh_api_key_hook is not awaited, although if the rest other requests are async, this function will probably also be
- urllib3 logger is configured although it is not used
- urllib3 is still used for encoding BasicAuth header although aiohttp also provides a possibility for this
- urllib3 is still a dependency although it is not really needed (if previous point is resolved)
The same problems probably also apply for the generation of the tornado, but I don't have any experience with it and can therefore not confirm it.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the v3 Python asyncio generator and inspect how refresh_api_key_hook, logging, BasicAuth encoding, and dependencies are generated. Compare those paths with aiohttp's async APIs and confirm whether the same concerns affect tornado; done means the asyncio client is internally consistent without an unnecessary urllib3 dependency.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100