Skip to content

Latest commit

 

History

History
29 lines (16 loc) · 1.38 KB

coding_standards.md

File metadata and controls

29 lines (16 loc) · 1.38 KB

Coding Standards

Q: Does the KBase project using any type of coding standards? Do you use a linter?

We aim to follow pep8, but we have some exceptions, such as a line length of 100 characters. We don't have a linter. But you can use Flake80 on your code. We have a .tox file to enforce code standards at the recommended editors section

Q: What python best practices do you recommend?

Python Best Practices

An opionated guide to python

Raymond Hettinger Videos

Python Gotchas

Q: Which python should I use?

KBase currently uses 2.7.14, but write code compatible with 3, namely wrap your print functions in parenthesis. A guide to writing future proof code is available at python-future.org

Q: Single Quotes or Double Quotes?

Use single or double quotes consistently throughout your app, pick one and don't switch between the two.

Q: Underscores for protected methods and double underscores for private methods?

YES