fix(drafts): use existing draft message ID for In-Reply-To/References headers#516
Closed
dinakars777 wants to merge 1 commit intoopenclaw:mainfrom
Closed
fix(drafts): use existing draft message ID for In-Reply-To/References headers#516dinakars777 wants to merge 1 commit intoopenclaw:mainfrom
dinakars777 wants to merge 1 commit intoopenclaw:mainfrom
Conversation
… headers When updating a draft with --quote but without --reply-to-message-id, the existing draft's message ID was fetched but never used to set the In-Reply-To and References headers. This caused delivery failures on strict mail servers. Fixes openclaw#512
Collaborator
|
Thanks for the patch. I reviewed this against the current drafts update path and I do not think this is the right fix for #512: when --reply-to-message-id is omitted, this would fall back to the existing draft message ID, which can make the updated draft set In-Reply-To/References to the draft itself. Current code already handles the quote-from-existing-thread path by selecting a non-draft, non-self message from the thread, and the #512 silent-verification problem is better addressed by exposing the threading headers in gmail get metadata plus failing explicit reply targets that have no Message-ID. Closing this PR as not planned rather than landing a self-reference risk. |
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.
Fixes #512
When updating a draft with --quote but without --reply-to-message-id, the existing draft's message ID (existingMessageID) was fetched but never used to set the In-Reply-To and References headers. This caused replies to lose proper threading information.
The fix ensures that when no --reply-to-message-id is explicitly provided, the existing draft's message ID is used as a fallback, maintaining proper email threading.