Skip to content

Orphan sweep silently deletes unmanaged praxis-* skill directories #54

Description

@anujhydrabadi

Bug

RemoveOrphanedByPrefix("praxis-", hosts, keep) (internal/skillinstall/installer.go:321, called after every bundle fetch in runPostAuthSetup) os.RemoveAlls any praxis-* directory under a host's skill dir that is not in the fresh catalog, not in the receipt, and not a meta-skill.

A user- or third-party-authored skill that happens to be named praxis-myown/ (never installed by this CLI — so not in the receipt) is silently deleted on next praxis login / refresh-skills. The code comments document the prefix as a reserved namespace (installer.go:308-317), but nothing warned the user when their directory got swept, and deletion is unrecoverable.

Suggested fix

Keep the reserved-namespace policy but make the sweep safe:

  1. Only remove directories the CLI can prove it created — e.g. require a receipt entry OR a marker file (.praxis-managed) written at install time. Unknown praxis-* dirs get a loud warning ("found praxis-prefixed skill not managed by this CLI: — rename it or remove it; the praxis- prefix is reserved") instead of deletion.
  2. At minimum: log every path the sweep deletes (today it's silent), and print a summary line after login.
  3. Test: pre-existing unmanaged praxis-foo/ survives login and produces the warning.

Found during the praxis skills/gateway audit (2026-07-06).

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions