OpenAPITools / OpenAPITools/openapi-generator
[BUG] Unable to set 'access_token' on api Configuration
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 26.8k
- Forks
- 7.7k
- PR merge metrics
- PR metrics pending
Description
Bug Report Checklist
- [x ] Have you provided a full/minimal spec to reproduce the issue?
- [ x] Have you validated the input using an OpenAPI validator (example)?
- [ x] Have you tested with the latest master to confirm the issue still exists?
- [ x] Have you searched for related issues/PRs?
- [ x] What's the actual output vs expected output?
- [Optional] Sponsorship to speed up the bug fix or feature request (example)
Description
This is for the python-experimental client generator.
When working with a 'bearer' access token, I am unable to set the 'access_token' property in the Configuration() initializer. Instead, I have to do this:
configuration = client_api.Configuration(
host=URL,
)
configuration.access_token = getToken()
ideally I would be able to do this:
configuration = client_api.Configuration(
host=URL,
access_token = getToken()
)
openapi-generator version
latest master (8/30/2022)
OpenAPI declaration file content or url
N/A
Related issues/PRs
Suggest a fix
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 python-experimental client generator's Configuration initializer and compare its accepted arguments with the documented access_token assignment. Reproduce the initializer call using host and access_token, then verify that the generated configuration accepts and retains the token without a separate assignment.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100