name: app-actions on: workflow_dispatch: push: paths: - '**.py' branches: - main - app pull_request: branches: - main jobs: mypy: runs-on: ubuntu-latest continue-on-error: true steps: - name: Checkout uses: actions/checkout@v3 - name: Setup Python uses: actions/setup-python@v4 with: python-version: 3.9 architecture: x64 - name: Install dependencies run: | pip install mypy pip install -r app/requirements.txt - name: Run mypy run: mypy --ignore-missing-imports ./app pytest: runs-on: ubuntu-latest env: MONGO_HOST: ${{ secrets.MONGO_HOST }} MONGO_PORT: ${{ secrets.MONGO_PORT }} MONGO_USER: ${{ secrets.MONGO_USER }} MONGO_PASS: ${{ secrets.MONGO_PASS }} steps: - name: Checkout uses: actions/checkout@v3 - name: Setup Python uses: actions/setup-python@v4 with: python-version: 3.12 architecture: x64 - name: Setup MongoDB run: docker run --name mongodb -d -p ${{ secrets.MONGO_PORT }}:27017 -e MONGO_INITDB_ROOT_USERNAME=${{ secrets.MONGO_USER }} -e MONGO_INITDB_ROOT_PASSWORD=${{ secrets.MONGO_PASS }} mongodb/mongodb-community-server - name: Install dependencies run: | python -m pip install --upgrade pip pip install pytest==8.3.4 pytest-asyncio==0.25.3 httpx==0.28.1 pip install -r app/requirements.txt - name: Setup moderated base cards working-directory: ./app/tools run: python3 _add_base_cards.py -a 2 -f data/base_cards.json - name: Run pytest run: pytest -vs