Repository navigation
refactor(web): replace promise chains and IIFEs with named functions - #172
Merged
TheGreatAxios merged 7 commits intoNov 4, 2026
Conversation
TheGreatAxios
marked this pull request as ready for review
November 4, 2026 22:14
|
Triage: Pass No changes needed from you. A maintainer will review this pull request. Stacked on #167: only this pull request's own changes were checked. |
TheGreatAxios
merged commit Nov 4, 2026
5e34551
into
cl-12110-remove-swallowed-errors-unchecked-casts-and-iifes-from-the
9 checks passed
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.
Last of the CL-12110 pull requests: the remaining
.catch()calls, promise chains, the IIFE and the hand-rolled login poll.Changes
human-fault.ts,api/artifacts.ts,api/projects.ts,workspace/index.tsx) sharerefusalBodyinapi/transport.ts. A body that is not JSON or cannot be read counts as "no body", so each caller shows its own wording; a read failure is logged, and anything else is rethrown.App.tsx,approaches-comparison.tsx,deliverable-block.tsx,pane-file.tsx,transcript.tsx,profiles.tsx,project-menu.tsx,settings.tsx,api/credentials.ts,single-flight.tsandload-room.tsare named async functions or try/finally blocks. The IIFE inloadProjectRoomis a named function.App.tsxcatches onlyApiFailure. The clipboard copy intranscript.tsxcatches onlyDOMException. A failed approach choice now shows the hub's readable message when there is one.QueryObserverwithrefetchIntervalinstead of aforloop withsetTimeout. It is not tied to a component, so leaving the screen mid-sign-in still finishes the login, as before. The five-minute deadline stays, polling continues while the browser reports offline, a cancelled poll aborts its request, and a query markedmeta: { persist: false }(the login poll) is kept out of the saved cache.App.tsx'sresponseCode().thenrefusal chain is left to #171, which turns it into a named function.Verification
deliverable-block.tsx's version view and compare share one read.bun run lint,format:check,typecheck,test,pins:verifyandvendor:verifypass.