Repository navigation
Read account addresses that Mail records as the account URL authority - #5
Merged
Merged
Conversation
Current stores record an IMAP account's address as the whole authority of its AccountURL, such as imap://user%40example.com/, so URLComponents reports the address as the host and no user. Read the address from the host when the URL has no user, and keep reading the user form. Log why the account map gives no address: a missing, unreadable, or unrecognized map, an entry without an address, or an account that mailboxes refer to but the map does not list.
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.
iMCP's Mail service (mattt/iMCP#239) reported no account email for any mailbox on a real V10 store. Envelope read the address only from the user part of each
AccountURLinMailData/Signatures/AccountsMap.plist, such asimap://user%[email protected]/. A V10 map read by the che-apple-mail-mcp maintainer (PsychQuant/che-apple-mail-mcp#11) records IMAP accounts asimap://user%40example.com/instead: the percent-encoded address is the whole authority, soURLComponentsreports it as the host and the user isnil. Exchange accounts recordews://<opaque identifier>/, which has no address.Account.Mapnow reads the address from the host when the URL has no user, and still reads it from the user when a server host follows. Accounts without an address in their URL, such as Exchange accounts, still have anilemail.A missing or unreadable map still gives no addresses without an error, but Envelope now logs the reason with the subsystem
Envelopeand the categoryAccounts: the map is missing, cannot be read, or is not in a recognized format; an entry has no address, with its URL scheme; or mailboxes refer to an account that the map does not list. Account identifiers in these messages are private. The README describes where addresses come from and how to stream these messages.