8000 fix(boxes): refuse the name `self` when a box is created by bryan-minimal · Pull Request #3495 · gominimal/minimal · GitHub
[go: up one dir, main page]

Skip to content

fix(boxes): refuse the name self when a box is created - #3495

Open
bryan-minimal wants to merge 2 commits into
mainfrom
fix/box-name-self-reserved-at-create
Open

bryan-minimal wants to merge 2 commits into
mainfrom
fix/box-name-self-reserved-at-create

Conversation

@bryan-minimal
@bryan-minimal bryan-minimal commented Nov 17, 2026 •
Copy link
Copy Markdown
Member

What

self is the name that addresses the calling box (BOX-007), so no box may take it. A rename to self is refused. A creation was not: min session activate -n self made a box named self and published self.min.internal.

The store's reserved-name list, which creation reads, did not carry the name. This adds it, from the one constant the rename check already reads.

Behaviour

  • Creating a box named self, in any case, is refused as an invalid name (`self` is reserved), and nothing is filed.
  • Rename is unchanged: its own check runs first and gives the same refusal as before.
  • A box that already has the name keeps working. A save that does not change the name does not read the list, as for the other reserved names.

BOX-007 words the refusal as exit 3. This change does not touch exit codes; creation answers as it does for the other reserved names.

Testing

  • Two new store tests: creation refuses self, SELF and Self in a fresh store each, files nothing, and the same store then files an ordinary name; a record already named self can still be saved.
  • Through the product on Ubuntu 24.04: on the last release a session named self is created and listed; on this commit the creation is refused.
  • Workspace tests, lint and the native end-to-end script pass on this commit.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Bug Fixes
    • Prevented creating new sessions named “self,” regardless of capitalization.
    • Preserved existing legacy sessions named “self” when saving without changing the name.

`self` addresses the calling box (BOX-007). A rename to it was refused, but the
store filed a new box under it: the reserved-name list that creation reads did
not carry it, so `min session activate --name self` made a box and published
`self.min.internal`.

Add the name to that list, from the one constant the rename check reads. A box
already named `self` keeps working: a save that does not change the name does
not read the list.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@bryan-minimal
bryan-minimal requested a review from a team as a code owner November 17, 2026 15:52
@coderabbitai
coderabbitai Bot commented Nov 17, 2026 •
Copy link
Copy Markdown
Contributor

Explain Change →

Important

Review skipped

Review was skipped as 8000 selected files did not have any reviewable changes.

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: Essentials
  • Run ID: 74e6739e-5cb1-43d2-b8a8-909953f5c681
Commits

Reviewing files that changed from the base of the PR and between 485ea74 and 5d6173a.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review

No actionable comments were generated in the recent review.

Walkthrough

The reserved session names now include self. Tests verify that creation rejects ASCII case variants without changing the store, accepts selfish, and allows saving a legacy self-named record when its name remains unchanged.

Changes: Session name reservation

Layer / File(s) Summary
Reserved-name creation and legacy save
crates/boxes/src/store.rs
The reserved-name list adds self. Tests cover case-variant rejection at creation, acceptance of selfish, and saving an unchanged legacy name when promoting the record to active.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related issues

  • gominimal/minimal#2236: This change covers the criterion to refuse self at creation. It does not establish whether the required exit code is met.
  • gominimal/minimal#2879: This change covers the criterion to refuse self at creation. It does not establish whether the required exit code is met.

Suggested reviewers: mitodrummer, norrietaylor

Merge Risk: Minimal · previous review 485ea

Creating a box named self is now refused, matching the existing rename behavior. Existing boxes named self can still be saved if their name is unchanged. No merge-blocking risk was found.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title follows Conventional Commit form (fix(boxes): ...), is imperative and lower-case, and names the main change: creation now refuses the name self. It matches the raw summary, which adds `sel…
Description check Passed The description covers the change, its behaviour, and testing. It explains that box creation refuses self in any case, that rename behaviour is unchanged, and that saves of an existing self record…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title follows Conventional Commit form (fix(boxes): ...), is imperative and lower-case, and names the main change: creation now refuses the name self. It matches the raw summary, which adds self to RESERVED_SESSION_NAMES, and the objectives, which describe the same refusal. The title is 56 characters, so it is concise.

Full details: Description check

Explanation

The description covers the change, its behaviour, and testing. It explains that box creation refuses self in any case, that rename behaviour is unchanged, and that saves of an existing self record still work. It lists the new store tests and product verification on Ubuntu 24.04. The template's Summary section links no issue (Refs or Closes), and the Checklist items (docs updated, BREAKING CHANGE footer) are not ticked or addressed. These are minor gaps.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

A rabbit checked the names with care,
And found that self was not for there.
SELF and Self were turned away,
While selfish could remain and stay.
The old name kept its place today.

Recent review info

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: Essentials
  • Run ID: d973920f-f76e-4785-a890-fc7d52d177a5
Commits

Reviewing files that changed from the base of the PR and between 5c8c4e8 and 485ea74.

Files selected for processing: 1

  • crates/boxes/src/store.rs

Included review availability: This review used your included allowance. Your plan provides up to 5 included reviews per hour; 0 remain after this review.

@minimal-foundry
minimal-foundry Bot commented Nov 17, 2026 •
Copy link
Copy Markdown
Contributor

Approved: no findings at 5d6173af9d40.

Nothing to do.

Clobber: none seen.

@minimal-foundry minimal-foundry Bot left a comment
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minimal-review — approved

Verdict APPROVE — No findings.

Panel: 3 of 3 personas ran (correctness, security, supply-chain).

@minimal-foundry minimal-foundry Bot added the review:approved minimal-review approved the current head label Nov 17, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

review:approved minimal-review approved the current head

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

0