unable to type in Compose Window when forwarding; 0x80004005 (NS_ERROR_FAILURE) [nsIIOService.newURI]"
Categories
(Thunderbird :: Message Compose Window, defect)
Tracking
(Not tracked)
People
(Reporter: calum.mackay, Assigned: jorgk-bmo)
References
Details
(Keywords: regression)
Attachments
(2 files, 1 obsolete file)
1.32 KB,
patch
|
jorgk-bmo
:
review+
|
Details | Diff | Splinter Review |
9.61 KB,
image/png
|
Details |
With current Daily, when forwarding a message (as attachment, non-HTML email), it's not possible to type in the compose window.
I notice that a new paperclip glyph is showing for the attachment area on the RHS, which is new since the last working build.
Last working build I have: Daily 0527
First bad build i have: Daily 0530
and broken thereafter up to and including Daily 0602
I'll try to narrow that down further.
NS_NOINTERFACE: Component returned failure code: 0x80004002 (NS_NOINTERFACE) [nsISupports.QueryInterface] stack-trace-collector.js:75
[Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIIOService.newURI]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame :: chrome://messenger/content/messengercompose/MsgComposeCommands.js :: AddAttachments :: line 4408" data: no] MsgComposeCommands.js:4408:29
AddAttachments chrome://messenger/content/messengercompose/MsgComposeCommands.js:4408
ComposeStartup chrome://messenger/content/messengercompose/MsgComposeCommands.js:2911
ComposeLoad chrome://messenger/content/messengercompose/MsgComposeCommands.js:3035
onload chrome://messenger/content/messengercompose/messengercompose.xul:1
NS_ERROR_NOT_AVAILABLE: Cannot call openModalWindow on a hidden window Prompter.jsm:345
NS_ERROR_NOT_AVAILABLE: Cannot call openModalWindow on a hidden window Prompter.jsm:345
openModalWindow resource://gre/modules/Prompter.jsm:345
openPrompt resource://gre/modules/Prompter.jsm:566
alert resource://gre/modules/Prompter.jsm:615
alert resource://gre/modules/Prompter.jsm:55
ComposeLoad chrome://messenger/content/messengercompose/MsgComposeCommands.js:3038
onload chrome://messenger/content/messengercompose/messengercompose.xul:1
Reporter | ||
Comment 1•5 years ago
|
||
MacOS 10.14.5
Reporter | ||
Comment 2•5 years ago
|
||
can't narrow further: there are no builds on ftp.m.org between 0527 & 0530.
Assignee | ||
Comment 3•5 years ago
|
||
Yes, I can reproduce this. It doesn't work for forwarding an IMAP message, works OK for a message from a local folder. Looks like a fallout from bug 1550945, first parts landed on 2019-05-30. Thanks for reporting, I'll take a look.
Assignee | ||
Comment 4•5 years ago
|
||
OK, the URL is something like:
imap-message://jorgk%40jorgk.com@mail.your-server.de/INBOX/spambucket#14321
I don't see why that doesn't work.
Assignee | ||
Comment 5•5 years ago
|
||
This fixes the issue. No idea why that was working differently before.
Assignee | ||
Comment 6•5 years ago
|
||
Oh, for the reviewer. The issue is that nsImapService::NewURI() calls nsImapService::GetServerFromUrl() and that calls FindServerByURI() and that doesn't find anything on the imap-message URL.
Comment on attachment 9069814 [details] [diff] [review] 1556242-discard-message.patch Review of attachment 9069814 [details] [diff] [review]: ----------------------------------------------------------------- Thanks, works for me. What URI are we trying to look up in this case? Is it from the original message (the attached one) to detect in which account we are to set up the sending identity, etc.? ::: mailnews/base/src/nsMsgAccountManager.cpp @@ +1727,5 @@ > > nsAutoCString type; > rv = aURI->GetScheme(type); > + if (StringEndsWith(type, nsDependentCString("-message"))) > + type.SetLength(type.Length() - 8); Please add a comment that we strip the '-message' suffix here. Or would it be better to strip it at the caller before it entering the nsMsgAccountManager::FindServerByURI() ?
Assignee | ||
Comment 8•5 years ago
|
||
It's not a lookup. "New URI" constructs a new nsIURI object, in this case an nsIImapUrl, for a spec. The spec has the scheme "imap-message" which is the URI of the attached message. It's turned into an object here:
https://searchfox.org/comm-central/rev/66bdc4565824a8c59d34ba88c3d8e70448356a71/mail/components/compose/content/MsgComposeCommands.js#4408 - reported in comment #0.
I looked at the callers. They pass around the nsIURI object, so in order to strip the "-message", we'd have to create a new nsIURI object with the the modified scheme. It's easier to do when the spec is again extracted as a string.
Besides, nsMsgAccountManager::FindServerByURI() should really be equipped to remove/convert undesired suffixes.
The big question is: Why is this required now. How was the nsIURI constructed before bug 1550945 and what was passed to nsMsgAccountManager::FindServerByURI() in that case. That's not an easy question to answer since it would mean reverting the local build to before that bug to debug it.
Assignee | ||
Comment 9•5 years ago
|
||
OK, going back to C-C rev c999415db730, M-C d8321d0b2c5b43933c5e9f201934ec7d4c from
https://treeherder.mozilla.org/#/jobs?repo=comm-central&revision=c999415db730294e7cc75c8e509ad1818695978c
to investigate. Not fun.
Assignee | ||
Comment 10•5 years ago
|
||
OK, I added debug in nsImapService::NewURI() and it doesn't get called on the imap-message spec. Hmm, so which protocol handler handles it?
Assignee | ||
Comment 11•5 years ago
|
||
Well, nsMailboxService::NewURI() doesn't handle it either. imap-message isn't really a registered scheme, those *-message URLs are some sort of hack. IIRC Kent tried to work out what's behind them, but to my knowledge, he didn't document it.
As it stands, I think we need to go with the patch here, see reasoning in comment #8.
Assignee | ||
Comment 12•5 years ago
|
||
Added comment and shifted the code into the if
block.
Comment 13•5 years ago
|
||
Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/2be4f664709c
Discard '-message' part of URL scheme in nsMsgAccountManager::FindServerByURI(). r=aceman DONTBUILD
Assignee | ||
Updated•5 years ago
|
Reporter | ||
Comment 14•5 years ago
|
||
thanks very much indeed, Jörg
Assignee | ||
Comment 15•5 years ago
•
|
||
Turned out that the fix was wrong, anyway, the right fix will be in bug 1556981.
EDIT: Spoke too early, looks like we need this fix after all.
Reporter | ||
Comment 16•5 years ago
|
||
Interesting, thanks.
Regardless, with 0606 my problem here is fixed, and I don't see any of the problems mentioned in bug 1556981, other than a paperclip icon not a TB icon (see attached).
Reporter | ||
Comment 17•5 years ago
|
||
Assignee | ||
Comment 18•5 years ago
|
||
That icon is wrong and will be fixed in bug 1556981. That bug also has attachments showing the correct icon (attachment 9069929 [details]).
Description
•