Closed Bug 1630041 Opened 4 months ago Closed 4 months ago

Thunderbird ignores app.update.url, breaking stats.thunderbird.net

Categories

(Thunderbird :: Preferences, defect)

defect

Tracking

(thunderbird76 affected, thunderbird77 fixed)

RESOLVED FIXED
Thunderbird 77.0
Tracking Status
thunderbird76 --- affected
thunderbird77 --- fixed

People

(Reporter: sancus, Assigned: rjl)

References

(Regression)

Details

(Keywords: regression)

Attachments

(2 files)

Thunderbird should be using the value in app.update.url when it checks for updates, instead it is directly hitting 'aus5.mozilla.org'. This breaks our stats.

This can easily be tested by opening the error console, enabling XHR and then going to Help -> "About Daily' to trigger an update check. On 68, you will see a request to aus.thunderbird.net first, and then to aus5.mozilla.org as the redirect is followed.

In both 77.0a1 and 76.0beta, there is no hit on aus.thunderbird.net

I see the count for 76.0a1 cratering on March 28th(GMT), so it's possible a change released that day caused this.

This was caused by Bug 1568994 and Rob said he'd work on it!

Depends on: 1568994
Assignee: nobody → rob

We have to modify application.ini already for other reasons, so I should be able to change the AppUpdate.URL field easily enough.
Currently on Thunderbird 77 it looks like this:

[AppUpdate]
URL=https://aus5.mozilla.org/update/6/%PRODUCT%/%VERSION%/%BUILD_ID%/%BUILD_TARGET%/%LOCALE%/%CHANNEL%/%OS_VERSION%/%SYSTEM_CAPABILITIES%/%DISTRIBUTION%/%DISTRIBUTION_VERSION%/update.xml
No longer depends on: 1568994
Keywords: regression
Regressed by: 1568994

(In reply to Rob Lemley [:rjl] from comment #2)

We have to modify application.ini already for other reasons, so I should be able to change the AppUpdate.URL field easily enough.
Currently on Thunderbird 77 it looks like this:

[AppUpdate]
URL=https://aus5.mozilla.org/update/6/%PRODUCT%/%VERSION%/%BUILD_ID%/%BUILD_TARGET%/%LOCALE%/%CHANNEL%/%OS_VERSION%/%SYSTEM_CAPABILITIES%/%DISTRIBUTION%/%DISTRIBUTION_VERSION%/update.xml

Yup, the only thing that needs to be changed there is the domain, so:
URL=https://aus.thunderbird.net/update/6/%PRODUCT%/%VERSION%/%BUILD_ID%/%BUILD_TARGET%/%LOCALE%/%CHANNEL%/%OS_VERSION%/%SYSTEM_CAPABILITIES%/%DISTRIBUTION%/%DISTRIBUTION_VERSION%/update.xml

We should also probably remove the preference from our prefs.js and add a note pointing to the bug similarly to Firefox: https://hg.mozilla.org/mozilla-central/rev/12efcfc5555a#l1.13

I was wrong above, we do not modify application.ini, but my idea is to have a value like MOZ_APPUPDATE_HOST that would be substituted at build time when application.ini is generated.

Then application.ini.in would contain:

#if MOZ_UPDATER
[AppUpdate]
URL=https://@MOZ_APPUPDATE_HOST@/update/6/%PRODUCT%/%VERSION%/%BUILD_ID%/%BUILD_TARGET%/%LOCALE%/%CHANNEL%/%OS_VERSION%/%SYSTEM_CAPABILITIES%/%DISTRIBUTION%/%DISTRIBUTION_VERSION%/update.xml
#endif

I'd like to set MOZ_APPUPDATE_HOST in confvars.sh, which I believe requires changing old-configure.in. I'll start on something that takes this approach.

NI bytesized - does that sound acceptable?

Flags: needinfo?(ksteuber)

Side note, it looks like the enterprise policy code just force-sets the app.update.url preference. It probably needs to be updated as well.
https://searchfox.org/comm-central/rev/2131bede09ff0e7273bc77f669150491cd0d7685/mail/components/enterprisepolicies/Policies.jsm#79-83

(In reply to Rob Lemley [:rjl] from comment #5)

Side note, it looks like the enterprise policy code just force-sets the app.update.url preference. It probably needs to be updated as well.
https://searchfox.org/comm-central/rev/2131bede09ff0e7273bc77f669150491cd0d7685/mail/components/enterprisepolicies/Policies.jsm#79-83

There's a note about that in the Mozilla patch: https://hg.mozilla.org/mozilla-central/rev/cd6bf21b54db#l1.15
"UpdateService.jsm will check for this policy directly when determining the update URL."

Override the default update server URL with Thunderbird's.
Requires the corresponding patch in Mozilla attached to the same bug.

Bug 1568994 moved the URL for the update server to application.ini. Thunderbird
uses a different hostname for the update URL; the URL path is the same.

I've added a set_config('MOZ_APPUPDATE_HOST') to Thunderbird's moz.configure
file which will override the default.

I think it makes sense.

Flags: needinfo?(ksteuber)
Summary: Thunderbird ignores app.update.url → Thunderbird ignores app.update.url, breaking stats.thunderbird.net
Version: Trunk → 76
Pushed by thunderbird@calypsoblue.org:
https://hg.mozilla.org/integration/autoland/rev/71e4f9b9f80b
Allow setting the update host via set define at build time. r=glandium
Attachment #9140640 - Flags: review?(geoff)
Status: NEW → RESOLVED
Closed: 4 months ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 77.0
Attachment #9140640 - Flags: review?(geoff) → review+
Pushed by thunderbird@calypsoblue.org:
https://hg.mozilla.org/comm-central/rev/76857b526d5e
Set aus server for Thunderbird in mail/moz.configure. r=darktrojan DONTBUILD

[QA] - On today's Daily build (77.0a1 (2020-04-24) BuildID 20200424173214) I verified that the correct update server is used. (via Devtools console)

You need to log in before you can comment on or make changes to this bug.