fix: fetch comment replies from crit-web during share sync#350
Merged
tomasz-tomczyk merged 1 commit intomainfrom Apr 24, 2026
Merged
fix: fetch comment replies from crit-web during share sync#350tomasz-tomczyk merged 1 commit intomainfrom
tomasz-tomczyk merged 1 commit intomainfrom
Conversation
Previously, `crit fetch` and re-share silently dropped replies from web-authored comments because the webComment struct had no Replies field. - Add webReply struct and Replies field to webComment - Update mergeWebComments to map replies onto Comment.Replies - Add fetchWebComments() that also returns reply updates for existing comments (matched by external_id) - Update runFetch and runShareExisting callers - Add TestShareSyncFetchReplies and TestShareSyncFetchRepliesOnExistingComments integration tests Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
42a1409 to
a478483
Compare
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.
Summary
crit fetch(and re-share sync) silently dropped replies from web-authored comments becausewebCommentstruct had noRepliesfieldwebReplystruct andRepliesfield towebCommentmergeWebCommentsto map replies ontoComment.Repliesfor new commentsfetchWebComments()that also returns reply updates for existing comments (matched byexternal_id)runFetchandrunShareExistingcallersReview
Test plan
TestShareSyncFetchReplies— share, seed comment + 2 replies on web, re-share, verify replies in local.crit.jsonTestShareSyncFetchRepliesOnExistingComments— share with local comment, upsert to set external_id, seed reply on web, re-share, verify reply merged into existing local comment🤖 Generated with Claude Code