lab test fixtures break workspace parse downstream #307

Open
opened 2026-06-02 15:01:06 +00:00 by zaelgohary · 2 comments
Member

Downstream repos (e.g. hero_codescalers) that lock hero_skills at 599114a8 and pull it into their workspace fail to parse with:

error: invalid character `{` in package name: `{{ name_kebab }}`, the first character must be a Unicode XID start character
 --> /home/zainab/hero/build/cargo/git/checkouts/hero_skills-bf2dda0b0c5b45f3/599114a/crates/lab/tests/fixtures/blueprint/service_info_model/Cargo.toml:2:8

The fixture Cargo.toml at crates/lab/tests/fixtures/blueprint/service_info_model/Cargo.toml ships with template placeholders that cargo tries to parse as a real package. Either:

  • Exclude fixture paths from the workspace (exclude = ["crates/lab/tests/fixtures"] in root Cargo.toml), or
  • Move the fixtures to a non-Cargo path (e.g. tests/data/).
Downstream repos (e.g. hero_codescalers) that lock hero_skills at `599114a8` and pull it into their workspace fail to parse with: ``` error: invalid character `{` in package name: `{{ name_kebab }}`, the first character must be a Unicode XID start character --> /home/zainab/hero/build/cargo/git/checkouts/hero_skills-bf2dda0b0c5b45f3/599114a/crates/lab/tests/fixtures/blueprint/service_info_model/Cargo.toml:2:8 ``` The fixture Cargo.toml at `crates/lab/tests/fixtures/blueprint/service_info_model/Cargo.toml` ships with template placeholders that cargo tries to parse as a real package. Either: - Exclude fixture paths from the workspace (`exclude = ["crates/lab/tests/fixtures"]` in root `Cargo.toml`), or - Move the fixtures to a non-Cargo path (e.g. `tests/data/`).
Author
Member

Already fixed in 5ab1541 (development) and 6763929 (main) — both branches now exclude crates/lab/tests/fixtures from the workspace. Downstreams locked at older SHAs (e.g. 599114a) need to bump.

Already fixed in 5ab1541 (development) and 6763929 (main) — both branches now exclude crates/lab/tests/fixtures from the workspace. Downstreams locked at older SHAs (e.g. 599114a) need to bump.
Author
Member

Reopening: the exclude in hero_skills/Cargo.toml does NOT prevent downstream git-dep consumers from parse-erroring. When a downstream pulls lab as a git dep, cargo scans the extracted repo and chokes on the templated fixture before the workspace exclude is consulted.

Verified after bumping codescalers Cargo.lock to 5ab1541 — same parse error against the new SHA path:

error: invalid character { in package name: {{ name_kebab }}
--> ~/cargo/git/checkouts/hero_skills-.../5ab1541/crates/lab/tests/fixtures/blueprint/service_info_model/Cargo.toml:2:8

Fix: rename the fixture off Cargo.toml (e.g. Cargo.toml.tmpl) — or relocate fixtures outside any path cargo will scan when resolving git deps.

Reopening: the exclude in hero_skills/Cargo.toml does NOT prevent downstream git-dep consumers from parse-erroring. When a downstream pulls lab as a git dep, cargo scans the extracted repo and chokes on the templated fixture before the workspace exclude is consulted. Verified after bumping codescalers Cargo.lock to 5ab1541 — same parse error against the new SHA path: error: invalid character { in package name: {{ name_kebab }} --> ~/cargo/git/checkouts/hero_skills-.../5ab1541/crates/lab/tests/fixtures/blueprint/service_info_model/Cargo.toml:2:8 Fix: rename the fixture off Cargo.toml (e.g. Cargo.toml.tmpl) — or relocate fixtures outside any path cargo will scan when resolving git deps.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
lhumina_code/hero_skills#307
No description provided.