Closed Bug 1718411 Opened 3 years ago Closed 3 years ago

TB 91: Adding a search engine from an XML file doesn't work

Categories

(Thunderbird :: Search, defect)

Thunderbird 91
defect

Tracking

(thunderbird_esr91+ fixed, thunderbird91+ affected, thunderbird94 wontfix)

RESOLVED FIXED
95 Branch
Tracking Status
thunderbird_esr91 + fixed
thunderbird91 + affected
thunderbird94 --- wontfix

People

(Reporter: jose, Assigned: mkmelin)

References

(Regression)

Details

(Keywords: regression)

Attachments

(1 file)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.114 Safari/537.36

Steps to reproduce:

Try to add a search engine from an XML file

Actual results:

Console error:
Uncaught (in promise)
Exception { name: "NS_ERROR_FAILURE", message: "addEngine: Error adding engine:\n[Exception... "Invalid URI passed to SearchEngine constructor" nsresult: "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame :: resource://gre/modules/OpenSearchEngine.jsm :: _install :: line 95" data: no]", result: 2147500037, filename: "resource://gre/modules/SearchService.jsm", lineNumber: 1861, columnNumber: 0, data: null, stack: "addOpenSearchEngine@resource://gre/modules/SearchService.jsm:1861:24\n", location: XPCWrappedNative_NoHelper }

Expected results:

Should have worked.

Keywords: regression

Somehow file: URLs are no longer permitted, see:
https://hg.mozilla.org/mozilla-central/rev/63167d041bb4#l21.133

So how do TB users add search engines these days? I noticed that in Daily there are only Google and DDG on offer these days.

Regressed by: 1690750

Bug 1427317, attachment 9030183 [details] [diff] [review] was aiming at getting search engines online.

The quickest fix is to remove M-C code that checks for the http(s) scheme:
https://github.com/Betterbird/thunderbird-patches/blob/main/91/bugs/1718411-search-engine-from-file-m-c.patch
Of course not future-proof, but fixes the regression for the user.

That's also in Firefox code which we can't touch. Unless the Firefox folks can be convinced to remove it or change it to something that can be overridden.

We could indeed revive relevant parts of attachment 9030183 [details] [diff] [review]. Actually adding from a local xml file I can't think is very common. Adding from url would be much nicer, but it would require some strings...

Status: UNCONFIRMED → NEW
Ever confirmed: true
Blocks: tb91found
Summary: Daily: Adding a search engine from an XML file doesn't work → TB 91: Adding a search engine from an XML file doesn't work

https://bugzilla.mozilla.org supports this so can be used for testing

Assignee: nobody → mkmelin+mozilla
Status: NEW → ASSIGNED

Pushed by mkmelin@iki.fi:
https://hg.mozilla.org/comm-central/rev/9006837ffea3
add search engine by url or discovery. r=henry

Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 95 Branch

Probably best to let 10n work happen during the 94 cycle. Then I suppose we can take it for 91. The localization will be missing for some (but fall back to English). Anyway, on 91 it's completely broken so can't really get much worse...

Comment on attachment 9245090 [details]
Bug 1718411 - add search engine by url or discovery. r=henry

[Approval Request Comment]
Regression caused by (bug #): bug 1690750
User impact if declined: Add search engine doesn't work.
Testing completed (on c-c, etc.): c-c, soon beta
Risk to taking this patch (and alternatives if risky): it's not working. Alternatively just hide the "Add" button and don't allow the functionality - it's not much used I would think.

Attachment #9245090 - Flags: approval-comm-esr91?

Comment on attachment 9245090 [details]
Bug 1718411 - add search engine by url or discovery. r=henry

[Triage Comment]
approved for esr91

Attachment #9245090 - Flags: approval-comm-esr91? → approval-comm-esr91+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: