Twitter links no longer work after Twitter automatically installs its PWA service worker (network connection corrupted)

RESOLVED WORKSFORME

Status

()

Firefox for Android
General
P2
major
RESOLVED WORKSFORME
27 days ago
12 days ago

People

(Reporter: mkaply, Unassigned)

Tracking

52 Branch
Points:
---

Firefox Tracking Flags

(firefox52- wontfix, firefox53 unaffected, firefox54 unaffected, firefox55 unaffected)

Details

(URL)

(Reporter)

Description

27 days ago
If you go to a page that has a twitter link (http://www.otsukare.info/2017/03/30/broken-discussion-on-css - click on provocative tweet) with the Twitter app installed, you instead get an error page:

Corrupted Content Error

The site at xxx has experience a network protocol violation that cannot be repaired.

If you uninstall the Twitter app, it works.

This fails on 52/52, works on nightly

Screenshot here:

https://irccloud.mozilla.com/file/C0DaSlOh/Screenshot_20170329-201923.png

Updated

22 days ago
tracking-fennec: --- → ?
<mib_q8iglh> I indeed have uninstalled the twitter app. After that, I restored Firefox using Titanium Backup, cleared cache en cookies. I will try with a fresh profiles with Twitter already uninstalled.
<mib_q8iglh> Okay, fresh install AFTER uninstalling the Twitter app, the links are working.
<mib_q8iglh> So removing the app does work
<mib_q8iglh> Restoring a firefox profile which I was using when Twitter was installed, the links don't work anymore. So somethink in the profile is corrupt?



Smells like ActivityChooserModel to me. ACM listens for ACTION_PACKAGE_REMOVED to update its state; restoring from backup would also restore the model registry file.
P2 and plus first to let the devs look into this.
tracking-fennec: ? → +
Priority: -- → P2

Comment 3

18 days ago
Before we go chasing down red herrings, I think mkaply meant the Twitter *Progressive Web* App. I've just hit this problem on Release and I've never even had the Twitter *Android* app installed.

A temporary - and less invasive - is to go to about:serviceworkers and unregister Twitter's service worker.
status-firefox52: --- → fix-optional
status-firefox53: --- → ?
status-firefox54: --- → ?
status-firefox55: --- → unaffected

Updated

18 days ago
Summary: Twitter links no longer work after installing the Twitter app (network connection corrupted) → Twitter links no longer work after Twitter automatically installs its PWA service worker (network connection corrupted)

Comment 4

18 days ago
So thankfully only 52 is affected and copy-pasting the same link into the adress bar is also working, but of course neither workaround is immediately obvious (and if uninstall the service worker it'll immediately install itself again the next time you visit Twitter).

As it's more than a week until our next release, is there something we can do until then?
tracking-fennec: + → ?
status-firefox53: ? → unaffected
status-firefox54: ? → unaffected
tracking-firefox52: --- → ?

Comment 5

16 days ago
Hi Jan, Mike
Sorry I can't reproduce this issue.
My STR:
1. Open Release/Nightly Fennec and go to twitter.com and login
2. In Fennec, Go to menu->Pages->Add to HomeScreen. A mobile launcher icon apears.
3. Close Fennec
4. Click the new added launcher[1]
5. Click a link in the feed. <---- I expected to see an error here, but I can't see any.

Could you please help me to reproduce it?



[1] Release version(52) shows the desktop icon with Twitter icon. But nightly shows only "T". But this is not related to this bug.
Flags: needinfo?(mozilla)
Flags: needinfo?(jh+bugzilla)

Comment 6

16 days ago
The homescreen shortcut is unrelated. My STR are:
1. Open about:serviceworkers and unregister anything by Twitter.
2. Click on the Twitter link here: http://logs.glob.uno/?c=mozilla%23mobile&s=7+Apr+2017&e=7+Apr+2017#c624248
3. It loads normally.
4. Switch to about:serviceworkers and refresh until you can see that the Twitter service worker has been successfully reinstalled (active cache name is showing an UUID)
5. Close the twitter tab and open the link from http://logs.glob.uno/?c=mozilla%23mobile&s=7+Apr+2017&e=7+Apr+2017#c624248 again
6. Page loading fails with the error mentioned above (Corrupted Content Error)
Flags: needinfo?(jh+bugzilla)
(Reporter)

Comment 7

16 days ago
The Twitter app situation was clearly a red herring. I honestly wasn't sure what was causing it and that was just a guess.

We still need to know what caused this even though it is fixed in Firefox 53 because if it is a 52 regression, we need to fix it in the ESR.

Are we sure it's fixed in 53?
Flags: needinfo?(mozilla)

Comment 8

16 days ago
Definitively fixed in 53 by https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=07b9aab24f30b7172e4b6553773c382200b32488&tochange=0c212b76bca625813bae097ff2b8765b07261895, i.e. most probably bug 1271692.
(Reporter)

Updated

16 days ago
Blocks: 1271692
No longer blocks: 1271692
Depends on: 1271692
I'm having difficulty reproducing this.  Do we know what exception is being thrown by the fetch event handler?  We could ask twitter to maybe fix that while we wait for FF53 to release.

Comment 10

16 days ago
When faking a mobile UA (so the mobile service worker gets installed) I can reproduce this on Desktop as well. Loading with the console open, I see e.g.
> TypeError: Referrer URL http://logs.glob.uno/?c=mozilla%23mobile&s=7+Apr+2017&e=7+Apr+2017 cannot be cross-origin to the entry settings object (https://mobile.twitter.com).  main.1dc737bd24d2b80a.js:1
Thanks.  I'll notify twitter about this.  They are making this mistake:

https://github.com/whatwg/fetch/issues/245#issue-140279457

We have updated to the new spec to avoid this exception in FF54.  AFAIK chrome has not implemented this yet, either.
Twitter says they have deployed a fix.  Can you retest?
Flags: needinfo?(mozilla)
Actually, they had to roll back for another issue.  We can re-test tomorrow.
Flags: needinfo?(mozilla)
status-firefox52: fix-optional → wontfix
tracking-firefox52: ? → -
tracking-fennec: ? → ---

Comment 14

12 days ago
FYI: We finished deploying the fix on April 12th, 16:12 America/Los_Angeles
(In reply to Paul Armstrong from comment #14)
> FYI: We finished deploying the fix on April 12th, 16:12 America/Los_Angeles

Thanks for the quick fix!  Verified I can follow the link to twitter on my FF52 fennec device now.

Marking WFM since we didn't actually change anything on our side here.
Status: NEW → RESOLVED
Last Resolved: 12 days ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.