Project pub-sub test with upciti
Lefthook is mandatory, that' a tool which run predefined scripts on git hooks. We're using it to ensure that what you push respects our quality rules.
First of all, you'll have to install it globally
npm install @arkweid/lefthook --global
Then, you'll have to run it locally. This step will tell Lefthook to install custom hooks in your local .git directory
npx @arkweid/lefthook install pre-push
Voilà, Lefthook is working and will run scripts defined in lefthook.yml file on push event.
Want to run it manually? No problem you can do that by running
npx @arkweid/lefthook run pre-push
You must have docker and docker compose installed on your computer for the containers to work. Please refer to their documentation for installation.
I suggest using pyenv to manage your python versions.
This project uses poetry for dependency management you will need it to install the project and its dependencies.
- Clone the project
- Activate python 3.9.4 with
pyenv local 3.9.4
- Install dependencies with
poetry install
- Activate the venv with
poetry shell
- Use the project with either
python src/upciti/main.py
orinvoke run
for the container version
If you need to find the available commands for you, you can use: invoke --list
. For specific help, please use: invoke cmd --help
.
- Improve the first implementation of the pub sub.
- Use redis with compose to have multiple workers as well as processes to exchange data between themselves.
- Publish a python package to install the wheel in the docker image rather than what is currently used.
- Remove factory-boy from the production code to fix the production image. This would mean another service or image would send the information for instance via http or redis.
- Use click or similar to create a real cli.