Repository navigation
fix(clients): desktop and mobile unit test failures - #268
Merged
Merged
Conversation
Real defects: - mobile: the hosted-agent identity bundle wiped the agent secret before copying the bundle out of a no-copy BytesBuilder, so the sealed envelope carried an all-zero key. Copy first, then wipe. - mobile: an owner-write retry signed its fresh proof in the same second as the burnt one, giving the same event id. The retry now signs at least one second later. - mobile: the bare-link pass found Markdown links with a regex that rereads the rest of an unclosed `[` run from every opener, which is quadratic on long malformed input (the near-limit openers test took 108 s). A one-pass scanner finds the same spans. - desktop: an upstream sync dropped the fork's respond-to picker change: a pasted npub or hex key is offered whatever the search returns, and the search asks for the member picker's page size (25). Restored on top of upstream's truncateNpub and squircle avatars. - desktop: the lockfile resolved linkifyjs 4.3.2 for desktop and 4.3.3 for @tiptap/extension-link, so Link's onCreate registered the buzz protocol on a different linkify instance than composerMessageLinkNode and bareLinks read. Desktop now resolves 4.3.3 as well. Test-only: - desktop: under NODE_ENV=test TanStack Router treats a jsdom process as a client and sets up scroll restoration through bare history, addEventListener and scrollTo. The router tests now expose them. - desktop: the older-route requester test matched "request" inside the wrapper's data-testid; it now checks visible text only. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J3gDfAMsUq8X2NqFTrbJc6 Signed-off-by: Ross Hartmann <rosshartmann@RosssMacStudio.attlocal.net>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J3gDfAMsUq8X2NqFTrbJc6 Signed-off-by: Ross Hartmann <rosshartmann@RosssMacStudio.attlocal.net>
Resolve the fork inventory conflict: keep main's entries (including its huddle removal delta) and add the desktop unit fixes delta. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J3gDfAMsUq8X2NqFTrbJc6 Signed-off-by: Ross Hartmann <rosshartmann@RosssMacStudio.attlocal.net>
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.
This fixes a set of desktop and mobile unit test failures. Five are real defects and two are test-only fixes.
Real defects
identityBundlewiped the agent secret before it copied the bundle out of aBytesBuilder(copy: false). The builder still held a reference to the secret, so the sealed envelope carried 32 zero bytes. The bundle is now copied out first and the secret wiped after. Caught byhosted_agent_create_flow_test: the envelope opens with the provisioning key.created_atgives the same event id, which the API has already burnt. The retry now signs at least one second after the previous attempt. Caught byhosted_agent_management_test: a write re-signs a replayed proof.!?\[[^\]\n]*\]\([^)\s]*\). On an unclosed run ([[[[…,[x]([x](…) the regex rereads the rest of the input from every opener. The 256 KB near-limit test took 108 s against its 2 s ceiling. A one-pass scanner with precomputed stop indexes finds the same spans. It was checked against the regex on 200k random strings with no mismatch, and it handles each 256 KB case in a few milliseconds.RespondToFieldchange from aac9e12. That change offers a pasted npub or hex key whatever the search returns, and the people search asks for the member picker's page size (25). This restores it on top of upstream'struncateNpuband squircle avatars.linkifyjs4.3.2 for desktop and 4.3.3 for@tiptap/extension-link. Link'sonCreateregistered thebuzzprotocol on 4.3.3, whilecomposerMessageLinkNodeandbareLinksread 4.3.2, so pastedbuzz://links were not found there. Desktop now resolves 4.3.3, and the lockfile has a single instance.pnpm install --frozen-lockfile --lockfile-onlypasses.Test-only
NODE_ENV=test(desktop). In that mode, TanStack Router's nodeisServerexport is undefined. The router then treats a jsdom process as a client and sets up scroll restoration through barehistory,addEventListenerandscrollTo, which jsdom only puts onwindow. The three router-mounting tests (openChannelDirectoryResolver,inboxReopenNavigation,useRetainedProjectGitViews) now expose them.data-testid. It now checks visible text only.Not changed here
Tests were not run locally.
🤖 Generated with Claude Code
https://claude.ai/code/session_01J3gDfAMsUq8X2NqFTrbJc6