Skip to content

Closing sorryful results with tags: (#1161) #1

Closing sorryful results with tags: (#1161)

Closing sorryful results with tags: (#1161) #1

Workflow file for this run

on:
push:
branches:
- master
pull_request:
branches:
- master
name: Style linters
jobs:
alpha_build:
name: Lean based style linters
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install elan
run: |
set -o pipefail
curl https://raw.githubusercontent.com/leanprover/elan/master/elan-init.sh -sSf | sh -s -- --default-toolchain none -y
~/.elan/bin/lean --version
echo "$HOME/.elan/bin" >> $GITHUB_PATH
- name: check versions
run: |
lean --version
lake --version
- name: build cache
run: |
lake exe cache get
- name: build PhyslibAlpha
id: build
uses: liskin/gh-problem-matcher-wrap@v3
with:
linters: gcc
run: |
bash -o pipefail -c "env LEAN_ABORT_ON_PANIC=1 lake build -KCI PhyslibAlpha | tee stdout.log"
- name: runLinter on PhyslibAlpha
if: ${{ always() && steps.build.outcome == 'success' || steps.build.outcome == 'failure' }}
id: lint
uses: liskin/gh-problem-matcher-wrap@v3
timeout-minutes: 4
with:
linters: gcc
run: env LEAN_ABORT_ON_PANIC=1 lake exe runPhyslibAlphaLinters
style_lint:
name: Python based linters
runs-on: ubuntu-latest
steps:
- name: cleanup
run: |
find . -name . -o -prune -exec rm -rf -- {} +
- uses: actions/checkout@v4
# Run the case checker action
- name: Check Case Sensitivity
uses: credfeto/action-case-checker@v1.3.0
- name: Look for ignored files
uses: credfeto/action-no-ignored-files@v1.1.0
- name: install Python
if: ${{ 'ubuntu-latest' == 'ubuntu-latest' }}
uses: actions/setup-python@v5
with:
python-version: 3.8
- name: Check PhyslibAlpha imports
run: |
chmod u+x scripts/PhyslibAlpha/alphaFileImports.py
./scripts/PhyslibAlpha/alphaFileImports.py
- name: Check no PhyslibAlpha in Physlib and QuantumInfo
run: |
chmod u+x scripts/PhyslibAlpha/noAlphaImports.py
./scripts/PhyslibAlpha/noAlphaImports.py
- name: Python linters for PhyslibAlpha
run: |
chmod u+x scripts/PhyslibAlpha/alphaPythonLinters.sh
./scripts/PhyslibAlpha/alphaPythonLinters.sh