You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix: APM Materialize deletes the committed security-audit skill #237
APM Materialize opened #233, which deletes all 20 files of the committed external security-audit skill (.agents/skills/security-audit/) and drops its deployed_files from apm.lock.yaml, although apm.yml still pins cloudflare/security-audit-skill/skills/security-audit#c1c8a8c1.
Run 43461776196 (apm install --update --only apm, apm-cli 0.35.0) logs:
[i] Cleaned 21 stale deployed files for cloudflare/security-audit-skill/skills/security-audit
[!] Skipped .agents/skills/security-audit/AI-AND-LLM.md: no trustworthy local deployment baseline. ...
Root cause
It is not line endings or a Windows-generated lock. The committed files are LF and their SHA-256 hashes match apm.lock.yaml exactly.
APM 0.35.0 only trusts a skill file's overwrite baseline from per-user deployment receipts (~/.apm/deployment-receipts/ plus .apm-local/installation). It never trusts the committed lockfile (DeploymentMaterializationSession.baseline). A fresh CI checkout has no receipts. For a root-level skill package (claude_skill), _integrate_native_skill has no "unchanged, adopt it" shortcut, so every committed file is skipped as possibly user-edited. Nothing is deployed for the package, so the cleanup phase then deletes all 21 lock-tracked paths as stale.
Before apm install, APM Materialize removes the external skill folders recorded in apm.lock.yaml. APM then redeploys them from the pinned commit; a missing target needs no receipt. The committed copy stays the review baseline, so the materialize PR diff still shows upstream changes.
A guard (check) fails materialize, and PR CI, when a locked dependency deploys nothing, a deployed file is missing, or a committed .agents/skills/ file isn't claimed by the lock.
Activity
fix: harden the external skill guard against symlinks and empty skills
fix: fail materialize when an external primitive is git-ignored
fix: fail materialize when a pinned dependency loses a file
fix: compare the external primitive check with the PR base