This repository has been archived by the owner on Feb 25, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 39
Code style guide
mwobensmith edited this page Dec 18, 2018
·
5 revisions
Iris follows fairly standard conventions with regard to code. The most obvious is the PEP 8 standard for Python. While we do not obey every PEP 8 rule, in general, they are good practice. Use the PEP 8 inspector in your IDE or similar to find problems.
Some of our standards include:
- PEP 8 for Python files
- Whitespace - spaces and line returns
- Comment formatting - single-line and multiline
- Variable, function, and class naming
- Single quotes for function arguments
- Import statements
- Order
- Avoid wildcards when possible
- Delete when unused
- Comments
- Use hash comments when documenting internal-only functions
- Use triple-quote comments when documenting external functions, intended to be part of the API
- Python file names
- Lowercase
- Underscores in place of spaces
- Contain no other alphanumeric characters (aside from file extension)
- Image file names
- Similar to Python files, with additional rules for PNGs
- JavaScript, bash, and other file types
- TBD
Other conventions:
- Code files are terminated with a line return
- Comments are full sentences that begin with a capitalized word and end with a period
- Error messages are also full sentences, as above
- URLs must include protocol
- Proper spelling, grammar, and punctuation are enforced
Installation
Running Iris
- Basic workflow
- Useful examples
- Using the Control Center
- Runtime argument list
- How to run update tests
Contributing to Iris
- Contributors
- Creating a test case
- Developer requirements
- Creating images
- Iris APIs - coming soon
- Code style guide
Iris Team Workflow
- Getting code into Iris
- Communicating with the team
- Sheriff and merge process
- Monitoring daily test runs
Release QA Team Workflow