fix(handoff): normalize identity in sendHandoffMail (#780)
The handoff mail bead was created with un-normalized assignee (e.g., gastown/crew/holden) but mailbox queries use normalized identity (gastown/holden), causing self-mail to be invisible to the inbox. Export addressToIdentity as AddressToIdentity and call it in sendHandoffMail() to normalize the agent identity before storing, matching the normalization performed in Router.sendToSingle(). Fix handoff mail delivery (hq-snp8)
This commit is contained in:
@@ -56,7 +56,7 @@ func NewMailboxBeads(identity, workDir string) *Mailbox {
|
||||
func NewMailboxFromAddress(address, workDir string) *Mailbox {
|
||||
beadsDir := beads.ResolveBeadsDir(workDir)
|
||||
return &Mailbox{
|
||||
identity: addressToIdentity(address),
|
||||
identity: AddressToIdentity(address),
|
||||
workDir: workDir,
|
||||
beadsDir: beadsDir,
|
||||
legacy: false,
|
||||
@@ -66,7 +66,7 @@ func NewMailboxFromAddress(address, workDir string) *Mailbox {
|
||||
// NewMailboxWithBeadsDir creates a mailbox with an explicit beads directory.
|
||||
func NewMailboxWithBeadsDir(address, workDir, beadsDir string) *Mailbox {
|
||||
return &Mailbox{
|
||||
identity: addressToIdentity(address),
|
||||
identity: AddressToIdentity(address),
|
||||
workDir: workDir,
|
||||
beadsDir: beadsDir,
|
||||
legacy: false,
|
||||
|
||||
Reference in New Issue
Block a user