Skip to content

Add trusted_packages for packages that skip the cooldown - #297

Merged
yourconscience merged 1 commit into
mainfrom
trusted-packages
Nov 17, 2026
Merged

yourconscience merged 1 commit into
mainfrom
trusted-packages

Conversation

@yourconscience

@yourconscience yourconscience commented Nov 17, 2026 •

Copy link
Copy Markdown
Owner

What and why

One package was exempt from the 72-hour cooldown in code: @openai/codex. This makes the exemption a setting.

trusted_packages: in tackroom.yaml (or tackroom.local.yaml) lists packages as npm:<name> or pypi:<name>. A new version of a listed package is never in cooldown: no registry lookup, nothing in the lock.

  • Without the key, a built-in list applies: npm:@openai/codex, npm:@anthropic-ai/claude-code and npm:@earendil-works/pi-coding-agent. The Pi package is the one tackroom itself names, and the registry lists github.com/earendil-works/pi as its repository.
  • A key you write replaces the list, so trusted_packages: [] gates every package.
  • An entry in any other form is a config error: config trusted_packages entry "foo" must be npm:<name> or pypi:<name>.
  • doctor names the trusted packages its package age check skipped.

Two reported gaps were checked on the way and turned out not to exist, so no code changed for them:

  • PyPI pre-releases. The docs said a version such as 1.0rc1 is not gated. It is, on main too. docs/skills.md now states the real, narrower gap: a single number followed by a tag (2a3), an underscore form, or an epoch.
  • Force-push after --allow-fresh. The claim was that a recorded skip carries over to a new head when upstream rewrites history. It does not: the decision is keyed by item and commit, and a new head got its own cooldown entry in a run against a rewritten repo.

The 3.0 release note comes with the PR that collects the notes for these fixes.

How I checked it

  • go build, go vet, go test ./... pass; lint reports 0 issues; the docs site builds with no warnings. No test was deleted.

  • With a binary from this branch in throwaway homes, an MCP server on npx -y @openai/[email protected] (a version that does not exist, so "publish time unknown" proves a lookup happened):

    • default list: not in cooldown; doctor prints 1 package-age exception (trusted_packages: npm:@openai/codex).
    • trusted_packages: []: cooldown mcp:codex-x: publish time unknown for npm:@openai/[email protected].
    • trusted_packages: [codex]: config validate fails with the message above.
  • The same with the list in tackroom.local.yaml and with a pypi: entry; config print, config inventory and config set work with the key present and absent.

  • Not run: the web view in a browser with the new key.

  • go test ./... and go vet ./... pass

  • I can explain this change without an AI tool

Summary by Sourcery

Make package cooldown exemptions configurable while retaining sensible defaults and exposing skipped trusted packages in diagnostics.

New Features:

  • Add configurable trusted package lists in tackroom.yaml or tackroom.local.yaml for npm and PyPI packages that bypass package cooldown checks.
  • Use a built-in trusted package list when no configuration is provided, while allowing an explicitly empty list to enforce cooldowns for every package.
  • Report trusted packages skipped by the package age check in doctor output.

Bug Fixes:

  • Correct the documented PyPI pre-release limitation while preserving cooldown enforcement for versions such as 1.0rc1.

Enhancements:

  • Validate trusted package entries and support configuration overlay semantics where a user-provided list replaces the defaults.

Documentation:

  • Document trusted_packages configuration, default trusted packages, validation behavior, and the narrower PyPI exact-version limitation.

@sourcery-ai

sourcery-ai Bot commented Nov 17, 2026

Copy link
Copy Markdown

Sorry @yourconscience, you've used your own review budget of 250,000 diff characters for the last 7 days.

You can request another review in 1 day and 4 hours by commenting @sourcery-ai review. Upgrade to get a review now.

@coderabbitai

coderabbitai Bot commented Nov 17, 2026

Copy link
Copy Markdown

Important

  • Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 226e2b59-e82c-4562-807d-a2bf4dafc4e2
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@sourcery-ai

sourcery-ai Bot commented Nov 17, 2026

Copy link
Copy Markdown

Reviewer's Guide

Data structures

Add the configuration field that distinguishes an absent trusted-package list from an explicitly empty one.

  • internal/app/app.go L25-28

Implementation

Apply trusted-package exemptions to cooldown reference selection and package-age checks, and define the defaults and entry validation they rely on.

  • internal/app/cooldown.go L299-303 (+3 small edits)
  • internal/app/package_age.go L63-67, L99-119 (+2 small edits)

Configuration

Preserve trusted-package overrides while merging configuration and reject entries that are not valid ecosystem-qualified package names.

  • internal/app/config.go L72-75, L390-399

Documentation

Document the trusted-package defaults and override behavior, and correct the stated PyPI pre-release cooldown gap.

  • docs/skills.md L91, L130-131

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@yourconscience yourconscience mentioned this pull request Nov 17, 2026
2 tasks done
@yourconscience
yourconscience merged commit d508441 into main Nov 17, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant