From ec21dda102ed78139823c28c1a16a015dea0f7fc Mon Sep 17 00:00:00 2001 From: Vijay Sarvepalli Date: Wed, 17 Jun 2026 18:49:34 -0400 Subject: [PATCH 1/9] Added pypi publish workflow --- .github/workflows/pypi_publish.yml | 74 ++++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 .github/workflows/pypi_publish.yml diff --git a/.github/workflows/pypi_publish.yml b/.github/workflows/pypi_publish.yml new file mode 100644 index 00000000..56396f31 --- /dev/null +++ b/.github/workflows/pypi_publish.yml @@ -0,0 +1,74 @@ +name: Build and Publish to PyPI + +on: + push: + tags: + - "20*" + +permissions: + contents: read + +jobs: + build: + name: Build distribution + runs-on: ubuntu-latest + + steps: + - name: Checkout source + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.12" + + - name: Install uv + uses: astral-sh/setup-uv@v5 + + - name: Install build tooling + run: | + python -m pip install --upgrade pip build twine + + - name: Sync dependencies + run: uv sync --frozen + + - name: Build package + run: python -m build + + - name: Verify distributions + run: | + python -m pip install --upgrade twine + twine check dist/* + ls -lah dist/ + + - name: Upload distributions + uses: actions/upload-artifact@v4 + with: + name: dist + path: dist/* + publish: + name: Publish to PyPI + needs: build + runs-on: ubuntu-latest + + environment: + name: pypi + + permissions: + id-token: write + contents: read + + steps: + - name: Download distributions + uses: actions/download-artifact@v4 + with: + name: dist + path: dist/ + + - name: Publish package + uses: pypa/gh-action-pypi-publish@release/v1 + with: + verbose: true + From dcbaf2d9d516bb09d1bd80faeea4be1ef1018924 Mon Sep 17 00:00:00 2001 From: Vijay Sarvepalli Date: Wed, 17 Jun 2026 18:57:53 -0400 Subject: [PATCH 2/9] try publish --- .github/workflows/pypi_publish.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pypi_publish.yml b/.github/workflows/pypi_publish.yml index 56396f31..0b6aa2df 100644 --- a/.github/workflows/pypi_publish.yml +++ b/.github/workflows/pypi_publish.yml @@ -1,9 +1,12 @@ +--- name: Build and Publish to PyPI on: push: tags: - "20*" + branches: + - pypi permissions: contents: read @@ -71,4 +74,3 @@ jobs: uses: pypa/gh-action-pypi-publish@release/v1 with: verbose: true - From 616bfe62e6622e810b5750ae11cc0c2b56836698 Mon Sep 17 00:00:00 2001 From: Vijay Sarvepalli Date: Wed, 17 Jun 2026 20:18:26 -0400 Subject: [PATCH 3/9] Reduce duplicates --- .github/workflows/pypi_publish.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/pypi_publish.yml b/.github/workflows/pypi_publish.yml index 0b6aa2df..e58ea894 100644 --- a/.github/workflows/pypi_publish.yml +++ b/.github/workflows/pypi_publish.yml @@ -5,8 +5,7 @@ on: push: tags: - "20*" - branches: - - pypi + permissions: contents: read From 6b831ec7bacfc10ee2da155193ede7f97b293ec7 Mon Sep 17 00:00:00 2001 From: Vijay Sarvepalli Date: Wed, 17 Jun 2026 20:48:17 -0400 Subject: [PATCH 4/9] Fixed pyproject again --- pyproject.toml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c608925a..97932787 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,8 +62,11 @@ ssvc_doctools="ssvc.doctools:main" "Project" = "https://github.com/CERTCC/SSVC" "Bug Tracker" = "https://github.com/CERTCC/SSVC/issues" +[tool.setuptools] +package-dir = {"" = "src"} + [tool.setuptools.packages.find] -where = ["."] # list of folders that contain the packages (["."] by default) +where = ["src"] # list of folders that contain the packages (["."] by default) include = ["ssvc*"] # package names should match these glob patterns (["*"] by default) exclude = ["test*"] # exclude packages matching these glob patterns (empty by default) #namespaces = false # to disable scanning PEP 420 namespaces (true by default) From 2697c8a2e27040e22f4fede0b852a017bb774c32 Mon Sep 17 00:00:00 2001 From: Vijay Sarvepalli Date: Mon, 22 Jun 2026 11:40:58 -0400 Subject: [PATCH 5/9] Potential fix for pull request finding no need uv steps here. Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --- .github/workflows/pypi_publish.yml | 6 ------ 1 file changed, 6 deletions(-) diff --git a/.github/workflows/pypi_publish.yml b/.github/workflows/pypi_publish.yml index e58ea894..41869a22 100644 --- a/.github/workflows/pypi_publish.yml +++ b/.github/workflows/pypi_publish.yml @@ -26,16 +26,10 @@ jobs: with: python-version: "3.12" - - name: Install uv - uses: astral-sh/setup-uv@v5 - - name: Install build tooling run: | python -m pip install --upgrade pip build twine - - name: Sync dependencies - run: uv sync --frozen - - name: Build package run: python -m build From a547b00a8fa26c342d55fd1be1816c8ac37545a6 Mon Sep 17 00:00:00 2001 From: Vijay Sarvepalli Date: Mon, 22 Jun 2026 15:17:08 -0400 Subject: [PATCH 6/9] Move evertyhing to uv --- .github/workflows/pypi_publish.yml | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/.github/workflows/pypi_publish.yml b/.github/workflows/pypi_publish.yml index 41869a22..a3cd2703 100644 --- a/.github/workflows/pypi_publish.yml +++ b/.github/workflows/pypi_publish.yml @@ -1,4 +1,3 @@ ---- name: Build and Publish to PyPI on: @@ -6,13 +5,12 @@ on: tags: - "20*" - permissions: contents: read jobs: build: - name: Build distribution + name: Build distribution (uv) runs-on: ubuntu-latest steps: @@ -21,21 +19,18 @@ jobs: with: fetch-depth: 0 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: "3.12" + - name: Install uv + uses: astral-sh/setup-uv@v3 - - name: Install build tooling - run: | - python -m pip install --upgrade pip build twine + - name: Set up Python (via uv) + run: uv python install 3.12 - name: Build package - run: python -m build + run: uv build - name: Verify distributions run: | - python -m pip install --upgrade twine + uv pip install twine twine check dist/* ls -lah dist/ @@ -44,6 +39,7 @@ jobs: with: name: dist path: dist/* + publish: name: Publish to PyPI needs: build From c22d9c26ff00f7a606f3e453b4beab50c8e6443b Mon Sep 17 00:00:00 2001 From: Vijay Sarvepalli Date: Mon, 22 Jun 2026 15:24:12 -0400 Subject: [PATCH 7/9] Move from uv tool to pip for twine --- .github/workflows/pypi_publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pypi_publish.yml b/.github/workflows/pypi_publish.yml index a3cd2703..7b640235 100644 --- a/.github/workflows/pypi_publish.yml +++ b/.github/workflows/pypi_publish.yml @@ -30,7 +30,7 @@ jobs: - name: Verify distributions run: | - uv pip install twine + pip install twine twine check dist/* ls -lah dist/ From 97c9217eebe3b149365761185b3932bc48fa6bbd Mon Sep 17 00:00:00 2001 From: Vijay Sarvepalli Date: Mon, 22 Jun 2026 15:41:37 -0400 Subject: [PATCH 8/9] Upgrade twine first --- .github/workflows/pypi_publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pypi_publish.yml b/.github/workflows/pypi_publish.yml index 7b640235..1831fdb6 100644 --- a/.github/workflows/pypi_publish.yml +++ b/.github/workflows/pypi_publish.yml @@ -30,7 +30,7 @@ jobs: - name: Verify distributions run: | - pip install twine + pip install -U twine twine check dist/* ls -lah dist/ From 4ca4aaf99ef09ed80e2d8f296d105011cda1dfce Mon Sep 17 00:00:00 2001 From: Vijay Sarvepalli Date: Mon, 22 Jun 2026 15:53:36 -0400 Subject: [PATCH 9/9] Remove twine check redundant --- .github/workflows/pypi_publish.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/pypi_publish.yml b/.github/workflows/pypi_publish.yml index 1831fdb6..fdc39b2a 100644 --- a/.github/workflows/pypi_publish.yml +++ b/.github/workflows/pypi_publish.yml @@ -30,8 +30,6 @@ jobs: - name: Verify distributions run: | - pip install -U twine - twine check dist/* ls -lah dist/ - name: Upload distributions