Samples CI Enhancements -- Follow-up from PR #111 Review
Source: PAO's review of PR #111 identified 4 scope expansions beyond the initial #103 implementation. These are valid improvements but out of scope for the initial gate.
Context
PR #111 adds the initial samples-build CI gate (Part 3 of repo health). PAO's review identified additional improvements from the #103 PRD that were deferred to keep the initial PR focused on the core gate.
Proposed Enhancements
1. Separate workflow file (from squad-ci.yml)
Move samples-build job to .github/workflows/squad-samples.yml instead of embedding in squad-ci.yml.
2. SDK reference patching
Three samples use published npm refs instead of local workspace:
- cost-aware-router: "@bradygaster/squad-sdk": "^0.8.0"
- autonomous-pipeline: "@bradygaster/squad-sdk": "^0.8.0"
- storage-provider-azure: "@bradygaster/squad-sdk": "latest"
Without patching, samples validate against last published npm version, not in-PR SDK changes. Need a workflow step to patch references to file:../../packages/squad-sdk before npm install.
3. Environment-dependent sample handling (ci-skip-tests.json)
Some samples need external services to test:
- Tier A (pure SDK, run full tests): autonomous-pipeline, hello-squad, hook-governance, skill-discovery, streaming-chat, rock-paper-scissors, cost-aware-router
- Tier B (needs .env, skip tests): knock-knock
- Tier C (needs external services, build-only): azure-function-squad, storage-provider-azure, storage-provider-sqlite
Create samples/ci-skip-tests.json listing samples to skip test execution. Workflow reads this file and only runs npm test for Tier A samples.
4. ci-skip-tests.json configuration file
Commit samples/ci-skip-tests.json:
["knock-knock", "azure-function-squad", "storage-provider-azure", "storage-provider-sqlite"]
Related
Samples CI Enhancements -- Follow-up from PR #111 Review
Context
PR #111 adds the initial samples-build CI gate (Part 3 of repo health). PAO's review identified additional improvements from the #103 PRD that were deferred to keep the initial PR focused on the core gate.
Proposed Enhancements
1. Separate workflow file (from squad-ci.yml)
Move samples-build job to .github/workflows/squad-samples.yml instead of embedding in squad-ci.yml.
2. SDK reference patching
Three samples use published npm refs instead of local workspace:
Without patching, samples validate against last published npm version, not in-PR SDK changes. Need a workflow step to patch references to file:../../packages/squad-sdk before npm install.
3. Environment-dependent sample handling (ci-skip-tests.json)
Some samples need external services to test:
Create samples/ci-skip-tests.json listing samples to skip test execution. Workflow reads this file and only runs npm test for Tier A samples.
4. ci-skip-tests.json configuration file
Commit samples/ci-skip-tests.json:
["knock-knock", "azure-function-squad", "storage-provider-azure", "storage-provider-sqlite"]
Related