0.2: errors, command palette, first-run tour, reconnecting #84

Merged
littlefox merged 8 commits from issue-52-reconnect into main 2026-10-17 22:41:43 +00:00
Owner

Closes #59
Closes #57
Closes #58
Closes #52

Four stacked branches in one PR to save CI time (each run tests desktop, Android and iPhone):

  • #59 Errors in plain words with details behind a toggle; login says how to fix wrong password / unknown name / unreachable server; 20 s connect timeout; empty states that explain.
  • #57 Ctrl+K command palette (commands, your channels, server name lookup, post numbers) and shortcuts j/n/r/s/?.
  • #58 First-run tour: three cards in an empty reader, skippable, remembered in the user area; not for elisp users.
  • #52 Reconnect by itself after a dropped connection (backoff, password in memory only, TLS rules kept), back to the same channel and post. Hanging connections: #81.

Locally: 135/136 across the three profiles; the one failure (tls.spec downgrade on WebKit) passed 3/3 on repeat, noted in #76.

🤖 Generated with Claude Code

https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8

Closes #59 Closes #57 Closes #58 Closes #52 Four stacked branches in one PR to save CI time (each run tests desktop, Android and iPhone): - #59 Errors in plain words with details behind a toggle; login says how to fix wrong password / unknown name / unreachable server; 20 s connect timeout; empty states that explain. - #57 Ctrl+K command palette (commands, your channels, server name lookup, post numbers) and shortcuts j/n/r/s/?. - #58 First-run tour: three cards in an empty reader, skippable, remembered in the user area; not for elisp users. - #52 Reconnect by itself after a dropped connection (backoff, password in memory only, TLS rules kept), back to the same channel and post. Hanging connections: #81. Locally: 135/136 across the three profiles; the one failure (tls.spec downgrade on WebKit) passed 3/3 on repeat, noted in #76. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
Errors showed protocol text like "server error not-member (13,
status 6)". Now a message says what we tried and, in plain words, what
went wrong and what to do ("Du är inte medlem där. Gå med först.");
the raw error is under a "Detaljer" toggle. Login says how to fix a
wrong password, an unknown name or an unreachable server. The empty
reader no longer says "press space" (useless on a phone), and the
empty unread list, event log and empty channels say what to expect.

errors.spec.ts covers the login errors, a missing post with its
details, and the empty reader. Unused translation entries are gone.

Refs #59

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
Ctrl+K (Cmd+K) or g opens a palette that finds commands, your
channels, other channels and people (the server's name lookup) and
posts by number; arrow keys, Enter and Escape work, and it's an
accessible combobox. Shortcuts outside text fields: Space, Enter or j
for the default action, n new post, r reply, s save, ? for the list.

palette.spec.ts covers finding a channel, opening a post by number,
the selection keys, r, ?, and that shortcuts don't fire while typing.

Refs #57

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
After a first login the reader shows three cards: what channels and
the inbox are, how to read (the button, Space, or a swipe), and how to
reply. It's not a modal, so nothing is blocked. Skipping or finishing
saves `tour-seen` in the user area (before the card goes, so a quick
logout can't lose it), so it isn't shown again on any device. Emacs
client users never get it.

tour.spec.ts steps through, skips, and checks it stays gone after a
new login.

Refs #58

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
Sleep, a train tunnel, a Wi-Fi change or iOS suspending the app
dropped the connection and the user started over at the login page.
Now a dropped connection that wasn't a logout shows a "reconnecting"
bar (try now / log in again), and NeoKOM connects and logs in again
with backoff, using the password kept in memory for the session only.
The main view comes back on the new connection to the same channel
and post, reading nothing. A TLS session only reconnects with TLS
(D-026).

reconnect.spec.ts closes the app's WebSocket mid-session and checks
the banner, the automatic return to the same place with the same
unread counts, a working connection after, and that logging out isn't
treated as a drop. A connection that hangs without an error isn't
noticed yet: #81.

Refs #52

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
Tour only in an empty reader; 20 s connect timeout; test fixes
Some checks failed
ci / check (push) Successful in 12m47s
ci / desktop (push) Successful in 16m49s
ci / e2e (push) Failing after 26m47s
cac59788e6
The tour card sat above every post and pushed it down on short
screens; now it shows only while the reader is empty (until skipped
or finished). Connecting had no timeout, so a server that never
answers (or a port WebKit blocks) left the login page at
"Ansluter…" forever; net::open now gives up after 20 s with the
"couldn't reach the server" message. Specs: the tour runs as David
(Bertil's UI is English after i18n.spec), the reconnect check looks
for error text rather than a status line, and the unreachable server
is an unused high port.

Refs #58, #59, #52

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
e2e: swipe again until a post shows; one retry in CI
Some checks failed
ci / check (push) Has been cancelled
ci / e2e (push) Has been cancelled
ci / desktop (push) Has been cancelled
cfe2579daf
The Android swipe test's first swipe can land before the reader is
ready on a busy runner (run #127). And browser tests get one retry in
CI for the Chromium start-up crash (#76); retried passes still show as
flaky.

Refs #50, #76

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
e2e: 120 s per test in CI
All checks were successful
ci / check (push) Successful in 9m43s
ci / desktop (push) Successful in 12m39s
ci / e2e (push) Successful in 15m41s
a3d5a39e1b
The first test of each browser project failed while "setting up
page": starting WebKit (and Chromium) on a loaded shared runner took
50 s or more, which counts against the test's 60 s. CI gets 120 s.

Refs #76

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
littlefox referenced this pull request from a commit 2026-10-18 14:33:48 +00:00
Sign in to join this conversation.
No description provided.