Skip to content

Revert the #49 URL-fragment fix: it breaks URL scraping from stdout - #53

Merged
richlegrand merged 1 commit into
mainfrom
revert-url-fragment
Nov 9, 2026
Merged

richlegrand merged 1 commit into
mainfrom
revert-url-fragment

Conversation

@richlegrand

Copy link
Copy Markdown
Owner

Reverts the #49 fix. Keeps the version bump, so 0.5.3 ships the #48 PIN-prompt
fix on its own.

The fix stripped the access code from the startup URL whenever stdout was not
a terminal. That line is also how programs learn the URL: tests/e2e/conftest.py
runs the listener with stdout=subprocess.PIPE and greps
URL:\s*(https://\S+) for it. A pipe is not a terminal, so the harness got a
URL with no credential and nothing could connect. e2e failed across every suite
that needs a connection.

That is not a test artifact. Any script harvesting the URL from stdout breaks
the same way, and URL: at the start of the line is a contract this project
deliberately protects.

isTTY was the wrong test. It separates a terminal from everything else, when
the distinction wanted is a system log from a script -- and both of those are
pipes. The real version needs daemon detection (JOURNAL_STREAM,
INVOCATION_ID, parent pid 0 or 1 for procd and containers), an override for
when the guess is wrong, and an e2e test pinning that a piped-but-not-daemon
listener still prints the whole URL. Follow-up issue has the detail.

serve_display.go and serve_display_test.go are byte-identical to their
state before the fix, which is what has shipped since 0.5.0.

@richlegrand
richlegrand merged commit 351536c into main Nov 9, 2026
5 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