This repository was archived by the owner on Apr 30, 2025. It is now read-only.
Added blueprints-provider #233
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: pr-check | |
| on: | |
| pull_request: | |
| branches: | |
| - main | |
| workflow_dispatch: | |
| jobs: | |
| codespell: | |
| name: Codespell | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - name: Codespell | |
| uses: codespell-project/actions-codespell@master | |
| with: | |
| ignore_words_list: .codespellignore | |
| check_filenames: true | |
| check_hidden: false | |
| skip: "*.patch" | |
| changes: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| outputs: | |
| python-api-packages: ${{ steps.python.outputs.changes }} | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - uses: dorny/paths-filter@v2 | |
| id: python | |
| with: | |
| filters: | | |
| frinx-inventory-server/python: | |
| - 'frinx-inventory-server/python/**' | |
| resource-manager/python: | |
| - 'resource-manager/python/**' | |
| schellar/python: | |
| - 'schellar/python/**' | |
| topology-discovery/python: | |
| - 'topology-discovery/python/**' | |
| performance-monitor/python: | |
| - 'performance-monitor/python/**' | |
| uniconfig/python: | |
| - 'uniconfig/python/**' | |
| utils/graphql-pydantic-converter: | |
| - 'utils/graphql-pydantic-converter/**' | |
| code-validate: | |
| name: Validate api packages | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| needs: changes | |
| if: ${{ needs.changes.outputs.python-api-packages != '[]' && needs.changes.outputs.python-api-packages != '' }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| directories: ${{ fromJSON(needs.changes.outputs.python-api-packages) }} | |
| defaults: | |
| run: | |
| working-directory: ${{ matrix.directories }} | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - uses: actions/setup-python@v4 | |
| with: | |
| python-version: "3.10" | |
| - uses: abatilo/actions-poetry@v2 | |
| with: | |
| poetry-version: "1.4.2" | |
| - name: Install package dependencies. | |
| run: poetry install | |
| - name: Run mypy. | |
| run: poetry run mypy . | |
| - name: Run ruff. | |
| run: poetry run ruff . | |
| - name: Run pyright. | |
| run: poetry run pyright . | |
| - name: Run pytests. | |
| run: | | |
| if [[ -d tests ]]; then | |
| poetry run pytest . -vv | |
| fi |