Skip to content

Commit 12746b7

Browse files
fix(ci): use full template URLs and options-before-path for uvx smoke
Published 0.1.0 does not resolve catalog slugs; Typer also misparses options when the project path comes first. Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent 87330a3 commit 12746b7

1 file changed

Lines changed: 17 additions & 7 deletions

File tree

.github/workflows/scaffold-cross-platform.yml

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,12 @@ concurrency:
1414
group: scaffold-cross-platform-${{ github.ref }}
1515
cancel-in-progress: true
1616

17+
env:
18+
# Full registry URLs: published PyPI 0.1.0 does not resolve catalog slugs.
19+
# After create-awesome-python-app>=0.2.0 ships resolve_catalog_spec, slugs also work.
20+
CPA_TEMPLATE_FASTAPI: https://github.com/Create-Python-App/cpa-templates?subdir=templates/fastapi-starter
21+
CPA_ADDON_DOCKER: https://github.com/Create-Python-App/cpa-templates?subdir=extensions/python-docker
22+
1723
jobs:
1824
scaffold:
1925
name: ${{ matrix.os }} / fastapi-starter
@@ -34,11 +40,14 @@ jobs:
3440
shell: bash
3541
run: |
3642
set -euo pipefail
37-
uvx create-awesome-python-app@latest "$TARGET" \
38-
--template fastapi-starter \
43+
# Options before project_directory — Typer treats a leading path as the
44+
# positional arg; trailing options after a bare path can be misparsed.
45+
uvx create-awesome-python-app@latest \
46+
--template "$CPA_TEMPLATE_FASTAPI" \
3947
--no-interactive \
4048
--no-install \
41-
--force
49+
--force \
50+
"$TARGET"
4251
4352
- name: Verify scaffolded project
4453
env:
@@ -76,12 +85,13 @@ jobs:
7685
TARGET: ${{ runner.temp }}/cpa-fastapi-docker
7786
run: |
7887
set -euo pipefail
79-
uvx create-awesome-python-app@latest "$TARGET" \
80-
--template fastapi-starter \
81-
--addons python-docker \
88+
uvx create-awesome-python-app@latest \
89+
--template "$CPA_TEMPLATE_FASTAPI" \
90+
--addons "$CPA_ADDON_DOCKER" \
8291
--no-interactive \
8392
--no-install \
84-
--force
93+
--force \
94+
"$TARGET"
8595
8696
- name: Verify extension files
8797
env:

0 commit comments

Comments
 (0)