Enhance the Python best practices Guidebook for the DevOps Division
As a dev of the DevOps division,
I would like the Python best practices guidebook
to be enhanced with examples, links to best practices, and recommended libraries,
to improve the quality and efficiency of our backend development work.
Background
The current Python best practices guidebook (python.md
) provides a general overview of the coding style, linting tools, testing practices, and code coverage expectations within the DevOps division. While it references Google's style guide and mentions the use of flake8
for PEP8
compliance, it lacks concrete examples, external resources, and recommendations for libraries that could aid in development.
Acceptance Criteria
-
Add examples illustrating the recommended code style, particularly where deviations from Google's guide are endorsed. -
Provide guidance and examples for setting up and using flake8 (e.g. how to configure it for the relaxed line length rule). -
Expand the testing section with examples of unit tests, the use of doctest for private functions, and how to isolate the Django tests. -
Offer a list of recommended libraries for common tasks in Python backend development, with brief descriptions of their use cases and benefits. -
Enhance the code coverage section with examples of how to write tests that improve coverage, including tools and techniques for measuring and reporting coverage.