f8a2744492fb33f6821536809d12d1b94878c458
- Store direct reference to SecurityMiddleware instance in app.state._security_middleware
immediately at module load time in main.py (before middleware_stack is built)
- Rewrite conftest.py _reset_all() to use app.state._security_middleware instead of
fragile middleware stack traversal that failed before the first request was made
- Set explicit client=('127.0.0.1', 50000) on ASGITransport across all test files
to ensure guard-core always sees a valid IP and can ban/track it correctly
this OR that
Telegram mini-app where you have to choose one of two things.
Installation
- Installing the repository:
git clone https://github.com/IgorVolochay/thisORthat
Manual setup:
- The project is written in Python3.9. Make sure you have it on your system. Go to the project folder, create a virtual environment and download pip requirements:
cd ./thisORthat
python3.9 -m venv venv
source ./venv/bin/activate
pip3 install -r ./app/requirements.txt
- Installing MongoDB database. You can use the official manual to install MongoDB manually, or use a Docker image to run the container:
docker run --name mongodb -d -p 27017:27017 -e MONGO_INITDB_ROOT_USERNAME=user -e MONGO_INITDB_ROOT_PASSWORD=pass mongodb/mongodb-community-server
Docker Compose setup:
- Use docker-compose to automatically build the entire project. For correct build, it is better to use docker-compose version 1.29.2:
docker-compose up --build
Description
thisORthat (TORT) - Telegram mini-app where you have to choose one of two things
https://t.me/thisorthat_rubot?startapp
392 KiB
Releases
1
Release 1.0
Latest
Languages
Python
58.5%
JavaScript
26.5%
CSS
14.1%
HTML
0.5%
Erlang
0.4%