Skip to content

fix(cli): preserve full URL targets in truncated box titles - #446

Merged
Brooooooklyn merged 2 commits into
voidzero-dev:mainfrom
yangshun:codex/fix-deploy-url-truncation
Oct 18, 2026
Merged

Brooooooklyn merged 2 commits into
voidzero-dev:mainfrom
yangshun:codex/fix-deploy-url-truncation

Conversation

@yangshun

@yangshun yangshun commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Description

Deployment URLs in narrow summary box titles lose their terminal hyperlink when the renderer truncates the title.

✓ built in 120ms
◇ Preparing deployment...
◇ Applying D1 migrations...
╭─ https://void-todo.yangshun.workers…─╮
│                                      │
│  Worker: void-todo                   │
│  D1 migrations up to date            │
│                                      │
╰──────────────────────────────────────╯

✓ Successfully deployed!

Clicking on it led me to https://void-todo.yangshun.workers… which is an invalid domain.

Fix

Keep the shortened title and attach the original full URL as its hyperlink destination.

I tried out another ways like shifting the URL into the box, but settled on this approach as it requires the minimal changes.

Validation

  • Focused deployment summary and terminal hyperlink tests
  • vp run test (affected tests)
  • vp run --no-cache test:all (formatting, lint, builds, typechecking, and the full test suite)
  • Packed React consumer smoke tests with npm and pnpm

Tested the following in my terminal, URL is truncated but clicking on it opens the full URL in the browser.

 FORCE_HYPERLINK=1 node --input-type=module <<'JS'
import { note } from './packages/void/src/cli/output.ts';

note(
  'Worker: todo-app\nD1 migrations up to date',
  'https://example.com/?app=todo-app&deployment=0123456789abcdef',
  { output: { columns: 40, write: chunk => process.stdout.write(chunk) } },
);
JS
╭─ https://example.com/?app=todo-app&…─╮
│                                      │
│  Worker: todo-app                    │
│  D1 migrations up to date            │
│                                      │
╰──────────────────────────────────────╯

AI disclosure

Used GPT-6.1 Sol Max. It's initial direction was superfluous and modified a lot of code. I decided on this approach which is IMO the smallest change needed to fix the issue.

Maintainer follow-up

Rebased onto main, with one commit on top: the cut title is found by matching the URL itself (its longest start followed by …) instead of the / (\S*…)/ regex, so no other word ending in … can be taken as the link label.

🤖 Generated with Claude Code

yangshun and others added 2 commits October 18, 2026 14:10
The title is matched against the URL itself: the longest start of the
URL followed by "…". Any other word that ends in "…" can no longer be
taken for the link label.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@Brooooooklyn
Brooooooklyn force-pushed the codex/fix-deploy-url-truncation branch from b1695a3 to 43ada20 Compare October 18, 2026 06:14
@Brooooooklyn
Brooooooklyn merged commit 07b3cb6 into voidzero-dev:main Oct 18, 2026
18 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.

2 participants