How to Contribute
Contribute to RPANBot.
👉 Make sure to read the Code of Conduct.
Contribute to RPANBot
👉 The RPANBot code lives in the
For a pull-request to be merged, your pull request must fullfill the following:
- Your code must be formatted with our linters (make sure you have pre-commit installed, then run
pre-commit run --all-files).
- Your pull request must target the
- It is strongly recommended test your code locally to avoid causing yourself (and others) a severe headache. If you did not test your code, you must specify it in your pull request.
- You must fully document the changes of which you are making.
Assuming your code is compliant with the above, the pull request will need to be reviewed by 1 contributor. The contributors will review your code and highlight any changes they suggest be made.
Setting up a development environment
Create an application on Discord's developer portal, go to the Bot tab, and copy the token and store it in a safe place.
Create an application on Reddit's website and copy the client ID and client secret, and store those in a safe place.
If you want error tracking, you can create a project at Sentry, however, this is optional.
Make a copy of
.env.exampleand rename it to
DISCORD_TOKENto the token from the Discord developer portal.
REDDIT_CLIENT_SECRETto the client ID and client secret (respectively) of the Reddit app you created earlier.
- If you are using Sentry, set
BOT/BN_WATCHER_SENTRY_DSNto the DSN for the Sentry project.
Start the bot by running
docker-compose upfrom the main directory. This will initialize and start all of the services.
Run database migrations by running
docker-compose exec api poetry run alembic upgrade head, which will set up the database tables.