swagger-api / swagger-api/swagger-codegen
[python] How can I disable the generation of the header
Nobody has claimed this yet.
- Dominant language
- Mustache
- Stars
- 17.8k
- Forks
- 6k
- PR merge metrics
- No merged PRs in 30d
Description
Description
Good day, I use swagger-codegen-cli to generate a client in python, but I really don't like the big diff in pullrequest when changing the api version, the version is put in each file, can I somehow remove this version, or the entire header ?
Swagger-codegen version
swagger-codegen 3.0.20
Example
It looks like this
"""
Automated data flow handler API
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
OpenAPI spec version: 0.0.2
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
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
The issue concerns swagger-codegen-cli Python output and the generated module docstring containing the OpenAPI version and header text. Start by locating the Python generator templates or configuration used for this header; done means providing a way to omit the version or entire header without adding it to generated files.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli, tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100