2016-10-14 12:51:08 +01:00
# How to contribute to Sanic
2016-10-14 11:23:48 +01:00
Thank you for your interest!
2016-10-29 19:39:12 +01:00
## Setting up the dev environment
It is ideal to create a virtual environment whenever you want to work on
a python project. **Note:** This is not a necessity to work on sanic.
Create a a new virtual environment if you dont have one, using:
`python3 -m venv <any name>`
Enable it using:
`. <any name>/bin/activate`
Get the source of sanic:
`git clone https://github.com/channelcat/sanic`
`cd sanic`
Install sanic :
`python setup.py install`
Install the dev dependencies:
`pip install -r requirements-dev.txt`
Create a new branch for your bugfix or feature:
`git checkout -b <branch name>`
Now you can start working on sanic.
## Tests
Install pytest and flake8:
`pip install pytest`
`pip install flake8`
Run the tests:
`pytest tests`
Ensure your code is properly linted using flake8:
`flake8 sanic/`
## Pull request
Once all tests have passed send out a PR.
2016-10-14 11:23:48 +01:00
2016-10-14 12:51:08 +01:00
## Warning
2016-10-29 19:39:12 +01:00
One of the main goals of Sanic is speed. Code that lowers the performance of Sanic without significant gains in usability, security, or features may not be merged.