Skip to content

Safety Net plugin blocks preamble cleanup commands #474

@Agentic-Builds

Description

@Agentic-Builds

Problem

Users running claude-code-safety-net alongside gstack hit false-positive blocks on two preamble commands:

  1. find ~/.gstack/sessions -mmin +120 -type f with the delete flag — blocked by Safety Net's rule against find with delete
  2. rm -rf operations outside cwd (e.g., /tmp/ cleanup) — blocked when cwd is ~

Impact

Every skill invocation that runs the standard preamble will fail on the first blocked command, requiring manual workarounds. The browse daemon itself works fine once the preamble is bypassed.

Suggested fix

Replace the blocked patterns with Safety Net-compatible alternatives:

# Instead of find with delete flag:
find ~/.gstack/sessions -mmin +120 -type f -exec rm {} +

# Or even simpler:
find ~/.gstack/sessions -mmin +120 -type f | xargs rm -f 2>/dev/null

These accomplish the same cleanup without triggering Safety Net's rules.

Environment

  • gstack (latest from cc-marketplace)
  • Safety Net v0.8.1
  • macOS (Darwin 25.4.0)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions