2017-01-20 03:18:52 +00:00
|
|
|
# Contributing
|
2016-10-14 11:23:48 +01:00
|
|
|
|
2017-01-20 03:18:52 +00:00
|
|
|
Thank you for your interest! Sanic is always looking for contributors. If you
|
|
|
|
don't feel comfortable contributing code, adding docstrings to the source files
|
|
|
|
is very appreciated.
|
2016-10-14 11:23:48 +01:00
|
|
|
|
2016-10-14 12:51:08 +01:00
|
|
|
## Running tests
|
2017-01-20 03:18:52 +00:00
|
|
|
|
2016-10-14 11:23:48 +01:00
|
|
|
* `python -m pip install pytest`
|
|
|
|
* `python -m pytest tests`
|
|
|
|
|
2016-12-25 09:20:48 +00:00
|
|
|
## Documentation
|
|
|
|
|
2017-01-20 03:18:52 +00:00
|
|
|
Sanic's documentation is built
|
|
|
|
using [sphinx](http://www.sphinx-doc.org/en/1.5.1/). Guides are written in
|
|
|
|
Markdown and can be found in the `docs` folder, while the module reference is
|
|
|
|
automatically generated using `sphinx-apidoc`.
|
2016-12-25 09:20:48 +00:00
|
|
|
|
|
|
|
To generate the documentation from scratch:
|
|
|
|
|
|
|
|
```bash
|
2017-01-19 22:32:08 +00:00
|
|
|
sphinx-apidoc -fo docs/_api/ sanic
|
2016-12-25 09:20:48 +00:00
|
|
|
sphinx-build -b html docs docs/_build
|
|
|
|
```
|
|
|
|
|
|
|
|
The HTML documentation will be created in the `docs/_build` folder.
|
|
|
|
|
2016-10-14 12:51:08 +01:00
|
|
|
## Warning
|
2017-01-20 03:18:52 +00: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. Please don't let this intimidate you! If you have any concerns about an
|
|
|
|
idea, open an issue for discussion and help.
|
|
|
|
|
2017-01-20 03:24:08 +00:00
|
|
|
**Previous:** [Sanic extensions](extensions.md)
|