going to postgre #42
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: pylint | |
| on: | |
| pull_request: | |
| branches: master | |
| jobs: | |
| setup: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| python-version: ["3.12"] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install pylint sqlfluff | |
| check_database_scripts: | |
| runs-on: ubuntu-latest | |
| needs: setup | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run : | | |
| pip install sqlfluff | |
| - name: Run sqlfluff for PostgreSQL | |
| run : sqlfluff lint --dialect postgres database/init-scripts/*.sql | |
| - name: Run sqlfluff for bank-service | |
| run : sqlfluff lint --dialect sqlite bank-service/database/bank-schema.sql | |
| check_store_service: | |
| runs-on: ubuntu-latest | |
| needs: setup | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: | | |
| pip install -r store-service/requirements.txt | |
| pip install pylint sqlfluff | |
| - name: Run pylint on store-service | |
| run: pylint store-service/*.py store-service/*/*.py | |
| check_bank_service: | |
| runs-on: ubuntu-latest | |
| needs: setup | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependecies | |
| run: | | |
| pip install -r bank-service/requirements.txt | |
| pip install pylint | |
| - name: Run pylint on bank-service | |
| run: pylint bank-service/*.py bank-service/*/*.py | |
| all_test_success: | |
| runs-on: ubuntu-latest | |
| needs: | |
| - check_store_service | |
| - check_bank_service | |
| - check_database_scripts | |
| steps: | |
| - name: Decide whether the needed jobs succeeded or failed | |
| uses: re-actors/alls-green@v1.2.2 | |
| with: | |
| jobs: ${{ toJSON(needs) }} |