Project

General

Profile

Bug #17007

JavaScript sometimes blocked on Tor Browser first start ⇒ "Watching a WebM video over HTTPS" and "Playing an Ogg audio track" scenarios are fragile: blocked by NoScript click-to-play

Added by intrigeri 3 months ago. Updated 4 days ago.

Status:
Confirmed
Priority:
High
Assignee:
-
Category:
-
Target version:
-
Start date:
Due date:
% Done:

0%

Feature Branch:
Type of work:
Research
Blueprint:
Starter:
Affected tool:
Browser

Description

As part of this ticket, stop accepting "Tails - Trying a testing version of Tails" in the test suite: that was introduced in b69a4dc6ab5094b4682ddf75f77d34d7fa51f330 (but keep the rest of the commit).

This scenario has failed 38 times, over the last 2 months, at the "I can watch a WebM video over HTTPs" step, so I'm going to mark it as fragile.

Interestingly, in the failure I've looked into, I see a NoScript click-to-play placeholder, while we're supposed to let WebM play automatically these days.
I've seen another situation when JavaScript does not get executed: see b69a4dc6ab5094b4682ddf75f77d34d7fa51f330, so I'm wondering if it might be that sometimes, Tor Browser gets configured with a higher security slider level than what we want. Hence setting priority >> normal, to investigate if that's a bug in Tails or in our test suite.

As per #11592#note-8 and following comments:

  • This bug affects Tails 3.x as well as Buster-based branches ⇒ not a regression in Buster.
  • This bug already occurred between Aug 7 and Aug 19, with Tor Browser 8.5.4 ⇒ not a regression in Tor Browser 8.5.5.

Nevertheless, as per #17053#note-2, the first time sajolida saw this bug was a couple days ago, while running 4.0~beta2. Under the hypothesis that this bug is caused by a race condition, we can infer that:

  • Either something changed recently, that makes us lose this race condition more often in general.
  • Or something changed recently, that makes us lose this race condition more often with sajolida's config and hardware.

On https://jenkins.tails.boum.org/view/RM/job/test_Tails_ISO_devel/ I've been annotating failed test suite runs with the reasons for failures. But I've been doing this only since August 31 so that's not enough to bisect what "recently" means exactly here. One would need to analyze a bunch of test suite runs between Aug 9 (when we started running the full test suite on the devel branch) and Aug 31. I've sampled 6 jobs in this timespan and I've seen that JS was disabled in 2 of them:

Then I've looked at 6 consecutive jobs from Aug 10-12 (jobs 1801-1806, d9a8be5b683b38ceff7987bf71bd949ac37c34b0 to 051bb7c1b3090498058ba0924afe8bf0149b1f92) and could spot only one case when JS was disabled (0a1ea458111f16833e10cb02c4cd445990c32019).

For comparison, in the 20 runs since the beginning of September, I've attributed test failures to this bug 11 times. So yeah, it looks like the bug happens more often. Note, however, that Jenkins has been particularly busy in late Aug & early September, compared to the usual; workload variations can affect the occurrence rate of such race conditions.

04_37_11_Watching_a_WebM_video.png View (99.6 KB) intrigeri, 08/30/2019 01:48 PM


Related issues

Related to Tails - Bug #16613: TorButton and/or NoScript are not fully set up on first Tor Browser launch: breaks circuits display and security slider Resolved
Related to Tails - Bug #15777: NoScript and HTTPS Everywhere icons are not shown on first start Resolved 08/09/2018
Related to Tails - Bug #15905: JavaScript disabled by default on recent builds from testing Resolved 09/02/2018
Related to Tails - Bug #11592: Step "[...] has loaded in the Tor Browser" is fragile Resolved 07/22/2016
Duplicated by Tails - Bug #17053: JavaScript sometimes broken in Tor Browser 8.5.5 Duplicate
Blocks Tails - Feature #16209: Core work: Foundations Team Confirmed

Associated revisions

Revision 956da152 (diff)
Added by intrigeri 2 months ago

Test suite: revert hack that masks a real bug (refs: #17007).

Let's take the risk to trigger this bug more often for now,
in order to learn whether Tor Browser 9.0 fixes it.

Revision dcbeaf52 (diff)
Added by intrigeri about 1 month ago

Revert "Test suite: revert hack that masks a real bug (refs: #17007)."

This reverts commit 956da152d30c2ef1ff74578e1634090107367e01.

We now know that Tor Browser 9.0a7 is affected by this bug too, so let's ensure
we can test other functionality even when this bug happens.

History

#1 Updated by intrigeri 3 months ago

  • Subject changed from "Watching a WebM video over HTTPS" test is fragile to "Watching a WebM video over HTTPS" and "Playing an Ogg audio track" scenarios are fragile

Same for "Playing an Ogg audio track": I often see a NoScript click-to-play placeholder.

#2 Updated by intrigeri 3 months ago

  • Subject changed from "Watching a WebM video over HTTPS" and "Playing an Ogg audio track" scenarios are fragile to "Watching a WebM video over HTTPS" and "Playing an Ogg audio track" scenarios are fragile: blocked by NoScript click-to-play

#3 Updated by intrigeri 3 months ago

#4 Updated by intrigeri 2 months ago

  • Subject changed from "Watching a WebM video over HTTPS" and "Playing an Ogg audio track" scenarios are fragile: blocked by NoScript click-to-play to JS sometimes blocked on Tor Browser first start ⇒ "Watching a WebM video over HTTPS" and "Playing an Ogg audio track" scenarios are fragile: blocked by NoScript click-to-play
  • Category deleted (Test suite)
  • Target version set to Tails_3.17

I've just seen this while doing the 4.0~beta2 manual test suite: JS was blocked on first start. The security slider says "Standard" as expected. Nothing fishy in the logs. Restarting Tor Browser fixes the problem.

Let's try to investigate a bit. Given our test suite sees this pretty often, it should be rather easy to collect whatever debugging info we need: let our test suite save it as build artifacts.

#5 Updated by intrigeri 2 months ago

  • Subject changed from JS sometimes blocked on Tor Browser first start ⇒ "Watching a WebM video over HTTPS" and "Playing an Ogg audio track" scenarios are fragile: blocked by NoScript click-to-play to JavaScript sometimes blocked on Tor Browser first start ⇒ "Watching a WebM video over HTTPS" and "Playing an Ogg audio track" scenarios are fragile: blocked by NoScript click-to-play

#6 Updated by intrigeri 2 months ago

  • Related to Bug #16613: TorButton and/or NoScript are not fully set up on first Tor Browser launch: breaks circuits display and security slider added

#7 Updated by intrigeri 2 months ago

  • Related to Bug #15777: NoScript and HTTPS Everywhere icons are not shown on first start added

#8 Updated by intrigeri 2 months ago

To whoever will work on this, if you need to dive into the code, segfault wrote this elsewhere:

Took me a while to find the code responsible for this, because I expected that it changes firefox preferences (i.e. the ones editable via about:config). But that doesn't seem to be case - just FTR (maybe someone finds this when we have to check stuff like that again): NoScript is controlled via WebExtension messages, the code is in src/modules/noscript-control.js in torbutton.git.

#9 Updated by intrigeri 2 months ago

  • Related to Bug #15905: JavaScript disabled by default on recent builds from testing added

#10 Updated by intrigeri 2 months ago

  • Description updated (diff)

#11 Updated by intrigeri 2 months ago

  • Target version changed from Tails_3.17 to Tails_4.0

#12 Updated by intrigeri 2 months ago

  • Duplicated by Bug #17053: JavaScript sometimes broken in Tor Browser 8.5.5 added

#13 Updated by intrigeri 2 months ago

  • Description updated (diff)

(Analyzed a bit occurrence rate on Jenkins.)

#14 Updated by intrigeri 2 months ago

  • Related to Bug #11592: Step "[...] has loaded in the Tor Browser" is fragile added

#15 Updated by intrigeri 2 months ago

  • Assignee set to intrigeri

Next step: check if / how often this happens on the Tor Browser 9.0 branch (#16356). I'll do that once the test suite on that branch is robust enough to draw any such conclusion.

#16 Updated by intrigeri 2 months ago

  • Status changed from Confirmed to In Progress

#17 Updated by intrigeri 2 months ago

  • Status changed from In Progress to Confirmed

#18 Updated by intrigeri 2 months ago

  • Blocked by Bug #17056: Make test suite robust with Tor Browser 9.0 added

#19 Updated by intrigeri about 2 months ago

  • Assignee deleted (intrigeri)

I won't be able to work on this before Saturday.

#20 Updated by segfault about 2 months ago

  • Blocked by Bug #17100: devel branch FTBFS: linux-image-5.2.0-2-amd64 not available added

#21 Updated by segfault about 2 months ago

  • Blocked by deleted (Bug #17100: devel branch FTBFS: linux-image-5.2.0-2-amd64 not available)

#22 Updated by intrigeri about 1 month ago

  • Priority changed from Elevated to High
  • Target version deleted (Tails_4.0)

Unfortunately, Tor Browser 9.0 is affected too :/

I'll remove the target version + bump priority for now as:

  • 3.x is affected too and I doubt we'll find time to fix this in 4.0.
  • It's a major bug and we should prioritize it as soon as we can.

#23 Updated by intrigeri about 1 month ago

  • Blocked by deleted (Bug #17056: Make test suite robust with Tor Browser 9.0)

#24 Updated by intrigeri about 1 month ago

  • Status changed from Confirmed to In Progress

#25 Updated by intrigeri about 1 month ago

  • Status changed from In Progress to Confirmed

Not quite in progress :/

#26 Updated by intrigeri 4 days ago

Hi @emmapeel,
@goupille,
and @numbat!

Did you see this reported since 4.0~beta2 was released? How often?

Also available in: Atom PDF