Repository navigation
Fix profile modal stuck on the spinner when the latest tweet is truncated - #573
Merged
dimdenGD merged 1 commit intoNov 11, 2026
Merged
Conversation
users/show.json embeds the latest tweet as `status` without a `user` object. TwitterUser.fromJSONObject builds lastStatus from it and sets lastStatus.user only afterwards, so _generateHTMLText throws on this.user.screenName while adding the "Expand tweet" link to a tweet that ends with "…". The exception is swallowed by the Deferred chain and the profile modal stays on its spinner. Fall back to https://twitter.com/i/status/<id> when the status has no user. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JgJm3VTmJ9WHQjoyaBDJFY
dimdenGD
added a commit
that referenced
this pull request
Nov 11, 2026
Fix profile modal stuck on the spinner when the latest tweet is truncated
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.
Opening the profile of some accounts leaves the modal on its loading spinner forever. Nothing is logged in the console.
When it happens
users/show.json.Cause
users/show.jsonembeds the latest tweet asstatus, without auserobject.TwitterUser.fromJSONObjectbuildslastStatusfrom it and setslastStatus.useronly afterwards. While it is being built,TwitterStatus._generateHTMLTextadds the "Expand tweet" link and readsthis.user.screenName, which throws becausethis.useris still undefined. The exception is swallowed inside the Deferred chain, so neither the success nor the error handler of the profile modal runs.Fix
Fall back to
https://twitter.com/i/status/<id>when the status has no user (one line infiles/bundle.js).How it was tested
The real profile component, user cache, API client and user parser from
files/bundle.jswere loaded in an isolated page with only the transport stubbed, using a response shaped likeusers/show.json:Not tested: the patched bundle in a live, logged-in OTD session.
I used Claude (an AI assistant) to track this down, write the fix and run the test above. The commit is co-authored accordingly.