> mkdir projects
> cd projects
> git clone https://github.com/vatsaaa/tasks.git
> cd tasks
> python3 -m venv .venv
> cd tasks
> python -m venv .venv
> ./.venv/bin/activate
> pip3 install -r requirements.txt
> python3 app.py
> pip3 install eventlet
celery -A taskqueue.tasks.celery_app worker --loglevel=DEBUG --pool=eventlet --purge
- Open link http://127.0.0.1:9889/api/v1/ui
- Operate with Swagger UI
- Before starting to contribute, one may find it useful to go through this page - How to contribute to Open Source.
- The recommended IDE is Visual Studio Code. [Here] is a good tutorial to follow and setup the IDE(https://realpython.com/advanced-visual-studio-code-python/).
- PyCharm is as good as VS Code, with a few specific differences. Update README.md file with instructions to setup PyCharm - [Issue #8].
paths:
/ping:
get:
summary: Health check url
operationId: controllers.controllers.ping
parameters:
- in: query
name: suffix
required: false
schema:
type: string
description: suffix is appended to response from the service
tags:
- Health Check
responses:
200:
description: ping( ) services responds to user's ping with pong and the time at which the srvice was invoked. e.g.
def ping(suffix=None):
resp_str = "User ping, tasks pong / " + dt.now().strftime("%Y-%m-%d, %H:%M:%S")
resp = resp_str if suffix is None else resp_str + " / " + suffix
return resp
> python3 app.py
INFO:waitress:Serving on http://127.0.0.1:5454
Open the browser to visit page http://127.0.0.1:5454/api/v1/ui to launch the swagger ui and to test the service just added
Alternatively, one could use the cUrl utility as well:
curl -X 'GET' \
'http://127.0.0.1:5454/api/v1/ping?suffix=suffix01' \
-H 'accept: */*'
Need to add unit testing for each module which should run nightly - for every branch Successful tests is the first criteria for accepting a merge request
Need to create automated functional tests which should run nightly - for every branch Successful tets is the first criteria for accepting a merge request
https://lightrun.com/dev-tools/using-the-redis-command-line/