Repository navigation
Conversation
sergical
marked this pull request as ready for review
October 6, 2026 22:28
betegon
requested changes
Oct 8, 2026
betegon
left a comment
Member
There was a problem hiding this comment.
Before merging:
- Stabilize the pane sizing in
ink-app.tsx/ink-snake.tsx. At 80×20, pressinggthen ↑ changes the measured board width and pauses the game before its first tick, without a terminal resize. Keep the score/help visible and add a regression covering narrow and wide terminals. - Respect
NO_COLORin the renderer while keeping the cell types distinguishable. - Add the required JSDoc for the new engine exports and type fields.
The engine/UI split and shared shortcuts fit the repo. Property/model-based tests would suit the engine invariants, but that preference is not a separate merge blocker.
Member
Author
|
@betegon Thanks for the review. Fixed in 0ea3fc8:
|
betegon
approved these changes
Oct 9, 2026
sergical
added a commit
that referenced
this pull request
Oct 15, 2026
Adds `sentry games snake`, so the Snake game from the `sentry init` waiting screen can be played on its own. Stacked on #1432. - The command runs full-screen in the alternate screen. esc, q or ctrl+c quits and restores the terminal. - It errors when there is no TTY or when an AI agent runs the CLI. `SENTRY_INIT_GAME` does not apply here. - `loadInkSidecar()` is extracted from `createInkUI` with no behavior change, so the init wizard and the game load the sidecar the same way. - Generated docs and skill references include the new `games` route. Breaking Changes: None --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Claude <claude@anthropic.com> Co-authored-by: betegon <miguelbetegongarcia@gmail.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
`sentry init` spends a long time waiting on the remote setup workflow. While it waits, a small box invites the user to press `g` and play Snake in the activity pane. The setup spinner and progress sidebar stay visible. The game yields the pane when the wizard needs attention: a prompt, a new warning or error, or the end of the run closes the board and pauses the game, and the invite then offers to resume. Game state lives outside WizardStore so each tick re-renders only the board, which is drawn as a single half-block string. `pnpm --filter sentry run proto:snake` drives the real Ink UI through a fake, offline workflow for local testing. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Hide the waiting-screen game with SENTRY_INIT_GAME=0 and when an AI agent runs the CLI. Measure the game pane with useBoxMetrics instead of calculating it from the frame layout. A terminal resize now keeps the run, pauses it, and moves the snake inside the new board. The run starts over only when the snake cannot fit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Esc paused the run only in the board's unmount effect, after the invite had rendered, so the invite kept the play copy. Pause before closing. Ink writes no intermediate frames when it detects CI, so the live snake tests read an empty frame there. Force interactive mode in those tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The board stopped at 60 columns and the invite shrank to its text, so the gap to the sidebar changed with content. Both now fill the pane, and the pane gap is two columns, which reads as wide as the one-row gap between sidebar panels. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The game pane sized itself from content: its flex basis followed the board and the "Press an arrow key to start" hint. Pressing an arrow key cleared the hint, the pane width changed, and resizeSnake paused the run before its first tick. The pane now ignores its content width while the game shows, and the hint has its own truncated line below the score. With NO_COLOR or plain output the board draws without escape codes, using @ for the head, o for the body, * for food, and a space for empty cells. Add JSDoc to the engine exports and type fields, regression tests for 80x20 and 160x50 terminals, NO_COLOR tests, and fast-check engine invariants. Co-authored-by: Claude <claude@anthropic.com>
Adds `sentry games snake`, so the Snake game from the `sentry init` waiting screen can be played on its own. Stacked on #1432. - The command runs full-screen in the alternate screen. esc, q or ctrl+c quits and restores the terminal. - It errors when there is no TTY or when an AI agent runs the CLI. `SENTRY_INIT_GAME` does not apply here. - `loadInkSidecar()` is extracted from `createInkUI` with no behavior change, so the init wizard and the game load the sidecar the same way. - Generated docs and skill references include the new `games` route. Breaking Changes: None --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Claude <claude@anthropic.com> Co-authored-by: betegon <miguelbetegongarcia@gmail.com>
Co-authored-by: Claude <claude@anthropic.com>
sergical
force-pushed
the
feat/cli-init-snake
branch
from
October 15, 2026 18:18
ba78133 to
2e16786
Compare
Contributor
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 2e16786. Configure here.
The step timer depended on the whole game state, so each queued turn cancelled the pending step and started a full new interval. Fast steering stalled the snake. Re-arm the timer only when the snake moves, its status changes, or its speed changes. Co-authored-by: Claude <claude@anthropic.com>
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
sentry initwaits a long time on the remote setup workflow. This PR adds an optional Snake game to the waiting screen. Press g to play.snake-game.ts) is pure state plus a half-block renderer. Each tick re-renders only the board.SENTRY_INIT_GAME=0hides the game. It is also hidden when an AI agent runs the CLI.useBoxMetrics. A resize pauses the run and keeps it.pnpm --filter sentry run proto:snakeruns the UI against a fake, offline workflow.Breaking Changes