Skip to content

File the question of drawing anonymous scopes as their own nodes #142

File the question of drawing anonymous scopes as their own nodes

File the question of drawing anonymous scopes as their own nodes #142

Workflow file for this run

name: CI
on:
push:
branches: [ master ]
tags: ["v*"]
pull_request:
branches: [ master ]
workflow_dispatch:
permissions:
contents: read
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
# Full Python matrix on Linux; newest Python only on macOS and Windows.
# Rationale: pyan3 is pure Python, so platform-specific bugs (path
# handling, subprocess launch, line endings, ...) are almost never
# Python-version-specific. The extra 8 jobs to cover every Python
# version on every OS would just re-find the same bugs in parallel.
os: [ubuntu-latest]
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14", "3.15"]
include:
- os: macos-latest
python-version: "3.14"
- os: windows-latest
python-version: "3.14"
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Set up Python ${{ matrix.python-version }} on ${{ matrix.os }}
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: ${{ matrix.python-version }}
# 3.15 is at rc1, which the setup-python manifest marks unstable, so a bare
# "3.15" resolves to nothing without this. Versions with a stable release
# are unaffected — the prerelease is only a fallback when no stable one
# satisfies the request. Becomes a no-op once 3.15 final ships.
allow-prereleases: true
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pdm
pdm install
- name: Lint with ruff
run: |
pdm run ruff check .
- name: Test with pytest
run: |
pdm run pytest tests/ -v
build:
needs: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: "3.14"
- run: pip install build
- run: python -m build
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: dist
path: dist/
publish:
if: startsWith(github.ref, 'refs/tags/v')
needs: build
runs-on: ubuntu-latest
environment: pypi
permissions:
id-token: write
steps:
- uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
name: dist
path: dist/
- uses: pypa/gh-action-pypi-publish@dc37677b2e1c63e2034f94d8a5b11f265b73ba33 # v1.14.2
with:
packages-dir: dist/