Closed Bug 1724298 Opened 3 years ago Closed 3 years ago

Unable to query/installed add-ons from GeckoView GV: 92.0a1-2021080409393

Categories

(GeckoView :: General, defect, P1)

ARM
Android
defect

Tracking

(firefox90 unaffected, firefox91 unaffected, firefox92blocking fixed)

RESOLVED FIXED
92 Branch
Tracking Status
firefox90 --- unaffected
firefox91 --- unaffected
firefox92 blocking fixed

People

(Reporter: amejia, Assigned: agi)

References

(Regression)

Details

(Keywords: regression, Whiteboard: [geckoview:m93])

Attachments

(1 file)

Attached file adb.txt

We receive multiple reports of users having issue after updating to the new version of Fenix with GV: 92.0a1-2021080409393 .

Related Fenix tickes 1, 2 and 3.

We want to identify if there is an issue on GV, as we are going to cut beta next week.

I attached the logcat logs

Something that get repeated multiple times is Unexpected error: TypeError: can't access property "normalize", type is undefined even our own extension doesn't get installed .

08-05 13:36:51.476 E/App     (25083): Could not install browser-icons extension
08-05 13:36:51.476 E/App     (25083): java.lang.Exception: Unexpected error: TypeError: can't access property "normalize", type is undefined
08-05 13:36:51.476 E/App     (25083):   at org.mozilla.geckoview.WebExtensionController$$ExternalSyntheticLambda1.onException(Unknown Source)
08-05 13:36:51.476 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.lambda$map$1(GeckoResult.java:1)
08-05 13:36:51.476 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.$r8$lambda$lpeXvVUq93_sJmpP_N4UTuC5HHU(GeckoResult.java)
08-05 13:36:51.476 E/App     (25083):   at org.mozilla.geckoview.GeckoResult$$ExternalSyntheticLambda1.onException(Unknown Source)
08-05 13:36:51.476 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.lambda$thenInternal$4(GeckoResult.java:4)
08-05 13:36:51.476 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.$r8$lambda$AFxsnIxghFV7ZhrvgIHpdLryPVU(GeckoResult.java)
08-05 13:36:51.476 E/App     (25083):   at org.mozilla.geckoview.GeckoResult$$ExternalSyntheticLambda0.run(Unknown Source)
08-05 13:36:51.476 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.lambda$dispatchLocked$5(GeckoResult.java:2)
08-05 13:36:51.476 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.$r8$lambda$PbNUepeldwERMEcQ_iVWEzy-zTE(GeckoResult.java)
08-05 13:36:51.476 E/App     (25083):   at org.mozilla.geckoview.GeckoView$$ExternalSyntheticLambda0.run(Unknown Source)
08-05 13:36:51.476 E/App     (25083):   at android.os.Handler.handleCallback(Handler.java:751)
08-05 13:36:51.476 E/App     (25083):   at android.os.Handler.dispatchMessage(Handler.java:95)
08-05 13:36:51.476 E/App     (25083):   at android.os.Looper.loop(Looper.java:154)
08-05 13:36:51.476 E/App     (25083):   at android.app.ActivityThread.main(ActivityThread.java:6314)
08-05 13:36:51.476 E/App     (25083):   at java.lang.reflect.Method.invoke(Native Method)
08-05 13:36:51.476 E/App     (25083):   at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:872)
08-05 13:36:51.476 E/App     (25083):   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:762)
08-05 13:36:51.477 E/App     (25083): Could not install ads@mozac.org extension
08-05 13:36:51.477 E/App     (25083): java.lang.Exception: Unexpected error: TypeError: can't access property "normalize", type is undefined
08-05 13:36:51.477 E/App     (25083):   at org.mozilla.geckoview.WebExtensionController$$ExternalSyntheticLambda1.onException(Unknown Source)
08-05 13:36:51.477 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.lambda$map$1(GeckoResult.java:1)
08-05 13:36:51.477 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.$r8$lambda$lpeXvVUq93_sJmpP_N4UTuC5HHU(GeckoResult.java)
08-05 13:36:51.477 E/App     (25083):   at org.mozilla.geckoview.GeckoResult$$ExternalSyntheticLambda1.onException(Unknown Source)
08-05 13:36:51.477 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.lambda$thenInternal$4(GeckoResult.java:4)
08-05 13:36:51.477 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.$r8$lambda$AFxsnIxghFV7ZhrvgIHpdLryPVU(GeckoResult.java)
08-05 13:36:51.477 E/App     (25083):   at org.mozilla.geckoview.GeckoResult$$ExternalSyntheticLambda0.run(Unknown Source)
08-05 13:36:51.477 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.lambda$dispatchLocked$5(GeckoResult.java:2)
08-05 13:36:51.477 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.$r8$lambda$PbNUepeldwERMEcQ_iVWEzy-zTE(GeckoResult.java)
08-05 13:36:51.477 E/App     (25083):   at org.mozilla.geckoview.GeckoView$$ExternalSyntheticLambda0.run(Unknown Source)
08-05 13:36:51.477 E/App     (25083):   at android.os.Handler.handleCallback(Handler.java:751)
08-05 13:36:51.477 E/App     (25083):   at android.os.Handler.dispatchMessage(Handler.java:95)
08-05 13:36:51.477 E/App     (25083):   at android.os.Looper.loop(Looper.java:154)
08-05 13:36:51.477 E/App     (25083):   at android.app.ActivityThread.main(ActivityThread.java:6314)
08-05 13:36:51.477 E/App     (25083):   at java.lang.reflect.Method.invoke(Native Method)
08-05 13:36:51.477 E/App     (25083):   at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:872)
08-05 13:36:51.477 E/App     (25083):   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:762)
08-05 13:36:51.478 E/App     (25083): Could not install cookies@mozac.org extension
08-05 13:36:51.478 E/App     (25083): java.lang.Exception: Unexpected error: TypeError: can't access property "normalize", type is undefined
08-05 13:36:51.478 E/App     (25083):   at org.mozilla.geckoview.WebExtensionController$$ExternalSyntheticLambda1.onException(Unknown Source)
08-05 13:36:51.478 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.lambda$map$1(GeckoResult.java:1)
08-05 13:36:51.478 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.$r8$lambda$lpeXvVUq93_sJmpP_N4UTuC5HHU(GeckoResult.java)
08-05 13:36:51.478 E/App     (25083):   at org.mozilla.geckoview.GeckoResult$$ExternalSyntheticLambda1.onException(Unknown Source)
08-05 13:36:51.478 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.lambda$thenInternal$4(GeckoResult.java:4)
08-05 13:36:51.478 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.$r8$lambda$AFxsnIxghFV7ZhrvgIHpdLryPVU(GeckoResult.java)
08-05 13:36:51.478 E/App     (25083):   at org.mozilla.geckoview.GeckoResult$$ExternalSyntheticLambda0.run(Unknown Source)
08-05 13:36:51.478 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.lambda$dispatchLocked$5(GeckoResult.java:2)
08-05 13:36:51.478 E/App     (25083):   at org.mozilla.geckoview.GeckoResult.$r8$lambda$PbNUepeldwERMEcQ_iVWEzy-zTE(GeckoResult.java)
08-05 13:36:51.478 E/App     (25083):   at org.mozilla.geckoview.GeckoView$$ExternalSyntheticLambda0.run(Unknown Source)
08-05 13:36:51.478 E/App     (25083):   at android.os.Handler.handleCallback(Handler.java:751)
08-05 13:36:51.478 E/App     (25083):   at android.os.Handler.dispatchMessage(Handler.java:95)
08-05 13:36:51.478 E/App     (25083):   at android.os.Looper.loop(Looper.java:154)
08-05 13:36:51.478 E/App     (25083):   at android.app.ActivityThread.main(ActivityThread.java:6314)
08-05 13:36:51.478 E/App     (25083):   at java.lang.reflect.Method.invoke(Native Method)
08-05 13:36:51.478 E/App     (25083):   at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:872)
08-05 13:36:51.478 E/App     (25083):   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:762)

Flags: needinfo?(agi)

Looks like something in Schemas is going sideways, according to the reporter this regressed between 20210802093840 and 20210804093931, but I can't see any extension changes related to this.

We might have to add a stacktrace to the exception help with this.

Component: Extensions → Android
Flags: needinfo?(agi)
Product: GeckoView → WebExtensions

Forwarding some info from the original that could be useful:

Checked out the latest nightly (5 Aug) on my daughter's tablet and my phone. Both seem to be working fine (Lenovo Tab M10 on Android 10 & Moto G Stylus 2020 on Android 11). These both have arm64-v8a instruction sets, whereas my Samsung and LG tablets have armeabi-v7a.

There are three places where type.normalize is called in Schemas.jsm:

We should investigate SchemaRoot's normalize method (i.e. the schemas that pass through it to see whether there is any way for ns.get(prop) to return undefined. Since the report at https://github.com/mozilla-mobile/fenix/issues/20692 mentions that the installation failed, some manifest key might fail to parse.

I was able reproduce on my Moto G5 with Android 7, with a debuggable build. I'm not able to see the JS Console on about:debugging

When I try to install an add-on a see this stack trace.

2021-08-06 11:16:20.699 23622-23622/org.mozilla.fenix.debug W/System.err: InstallException: -3
2021-08-06 11:16:20.699 23622-23622/org.mozilla.fenix.debug W/System.err:     at org.mozilla.geckoview.WebExtensionController$$ExternalSyntheticLambda11.onException(Unknown Source)
2021-08-06 11:16:20.700 23622-23622/org.mozilla.fenix.debug W/System.err:     at org.mozilla.geckoview.GeckoResult.lambda$map$1(GeckoResult.java:410)
2021-08-06 11:16:20.702 23622-23622/org.mozilla.fenix.debug W/System.err:     at org.mozilla.geckoview.GeckoResult$$ExternalSyntheticLambda4.onException(Unknown Source)
2021-08-06 11:16:20.702 23622-23622/org.mozilla.fenix.debug W/System.err:     at org.mozilla.geckoview.GeckoResult.lambda$thenInternal$4$GeckoResult(GeckoResult.java:546)
2021-08-06 11:16:20.703 23622-23622/org.mozilla.fenix.debug W/System.err:     at org.mozilla.geckoview.GeckoResult$$ExternalSyntheticLambda2.run(Unknown Source)
2021-08-06 11:16:20.704 23622-23622/org.mozilla.fenix.debug W/System.err:     at org.mozilla.geckoview.GeckoResult.lambda$dispatchLocked$5(GeckoResult.java:742)
2021-08-06 11:16:20.704 23622-23622/org.mozilla.fenix.debug W/System.err:     at org.mozilla.geckoview.GeckoResult$$ExternalSyntheticLambda0.run(Unknown Source)
2021-08-06 11:16:20.705 23622-23622/org.mozilla.fenix.debug W/System.err:     at android.os.Handler.handleCallback(Handler.java:751)
2021-08-06 11:16:20.706 23622-23622/org.mozilla.fenix.debug W/System.err:     at android.os.Handler.dispatchMessage(Handler.java:95)
2021-08-06 11:16:20.706 23622-23622/org.mozilla.fenix.debug W/System.err:     at android.os.Looper.loop(Looper.java:154)
2021-08-06 11:16:20.707 23622-23622/org.mozilla.fenix.debug W/System.err:     at android.app.ActivityThread.main(ActivityThread.java:6123)
2021-08-06 11:16:20.707 23622-23622/org.mozilla.fenix.debug W/System.err:     at java.lang.reflect.Method.invoke(Native Method)
2021-08-06 11:16:20.708 23622-23622/org.mozilla.fenix.debug W/System.err:     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:867)
2021-08-06 11:16:20.709 23622-23622/org.mozilla.fenix.debug W/System.err:     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:757)

I was able to reproduce the issue on GeckoView example Build id 20210806160038, trying to install https://addons.mozilla.org/firefox/downloads/file/3816867/ublock_origin-1.37.2-an+fx.xpi shows the following logcat error:

08-06 20:41:48.550  4127  4160 D GeckoViewConsole: onEvent GeckoView:WebExtension:Install {"installId":"7db1dd03-f209-4fa0-a70e-532315b3a684","locationUri":"https://addons.mozilla.org/firefox/downloads/file/3816867/ublock_origin-1.37.2-an+fx.xpi"}
08-06 20:41:48.562   388  1031 E NetlinkEvent: NetlinkEvent::FindParam(): Parameter 'TIME_NS' not found
08-06 20:41:48.562   388  1031 E NetlinkEvent: NetlinkEvent::FindParam(): Parameter 'UID' not found
08-06 20:41:48.571  4127  4160 D GeckoViewActivity: onHistogram name: NETWORK_CACHE_V2_HIT_TIME_MS, value: [J@64b430
08-06 20:41:49.424  4127  4160 I GeckoConsole: 1628275309424    addons.xpi      WARN    Download of https://addons.mozilla.org/firefox/downloads/file/3816867/ublock_origin-1.37.2-an+fx.xpi failed: TypeError: can't access property "normalize", type is undefined(resource://gre/modules/Schemas.jsm:3559:18) JS Stack trace: normalize@Schemas.jsm:3559:18
08-06 20:41:49.424  4127  4160 I GeckoConsole: normalize@Schemas.jsm:3749:28
08-06 20:41:49.424  4127  4160 I GeckoConsole: _getNormalizedManifest@Extension.jsm:957:20
08-06 20:41:49.424  4127  4160 I GeckoConsole: parseManifest@Extension.jsm:997:33

Device details:
Vendor and Model: Sony Xperia Z2
OS version: Android 6.0.1
CPU: Snapdragon 801 (armeabi-v7a)

I can also not profile the current Fenix Nightly anymore as well as the current GV example. Trying to connect to the GV example app only shows no open tabs and shows the following logcat

08-06 20:55:20.220  4127  4160 I Gecko   : console.error: "Error while calling actor 'root's method 'listTabs'" "TabDescriptorActor is not defined"
08-06 20:55:20.222  4127  4160 E GeckoConsole: [JavaScript Error: "Error while calling actor 'root's method 'listTabs' TabDescriptorActor is not defined"]
08-06 20:55:20.222  4127  4160 I Gecko   : console.error: (new ReferenceError("TabDescriptorActor is not defined", "resource://devtools/server/actors/webbrowser.js", 318))
08-06 20:55:20.224  4127  4160 E GeckoConsole: [JavaScript Error: "ReferenceError: TabDescriptorActor is not defined"]
08-06 20:55:20.248  4127  4160 I Gecko   : console.error: "Error while calling actor 'root's method 'listProcesses'" "ProcessDescriptorActor is not defined"
08-06 20:55:20.250  4127  4160 E GeckoConsole: [JavaScript Error: "Error while calling actor 'root's method 'listProcesses' ProcessDescriptorActor is not defined"]
08-06 20:55:20.251  4127  4160 I Gecko   : console.error: (new ReferenceError("ProcessDescriptorActor is not defined", "resource://devtools/server/actors/root.js", 452))
08-06 20:55:20.251  4127  4160 E GeckoConsole: [JavaScript Error: "ReferenceError: ProcessDescriptorActor is not defined"]
08-06 20:55:20.254  4127  4160 I Gecko   : console.error: "Error while calling actor 'root's method 'getProcess'" "ProcessDescriptorActor is not defined"
08-06 20:55:20.255  4127  4160 E GeckoConsole: [JavaScript Error: "Error while calling actor 'root's method 'getProcess' ProcessDescriptorActor is not defined"]
08-06 20:55:20.255  4127  4160 I Gecko   : console.error: (new ReferenceError("ProcessDescriptorActor is not defined", "resource://devtools/server/actors/root.js", 494))
08-06 20:55:20.255  4127  4160 E GeckoConsole: [JavaScript Error: "ReferenceError: ProcessDescriptorActor is not defined"]

Bringing it back to GeckoView as this is very likely something broken beyond extensions.

Severity: -- → S2
Component: Android → General
Priority: -- → P1
Product: WebExtensions → GeckoView

I narrowed the range by excluding test-only / clearly unrelated patches at the bottom (including a large land + backout):

https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=4d5846f47a99e2302b8d6f792d0af824e7c68848&tochange=d0cdb408805e4c6a53b095c2c346273cf1de4242

Ok from further investigation it looks like I might have made a mistake in the regression range, trying again.

this is the command (for robwu): ./mach mozregression -n gve --arch arm -g 91

[Tracking Requested - why for this release]:
Cannot run extensions on ARM builds of GeckoView / Fenix since a few days, not even built-in ones.
We should not release a Beta version of Firefox for Android (or publish the Android-Components library) with this bug.

(x86 works fine, hence unit tests are passing; but we aren't running ARM builds of GeckoView in CI)

OS: All → Android
Hardware: Unspecified → ARM

Something interesting: at this commit: https://hg.mozilla.org/integration/autoland/rev/524aef2e3307f6977ba024b560d94441d1c39d05

My local full build has this bug, but my local artifact build doesn't. So there's likely some build flag causing this? I'm wondering if that's related to the lite build changes.

We should probably have a quick smoke test for this on arm builds.

/edited

Assignee: nobody → agi

I caved and git bisected. Looks like https://hg.mozilla.org/integration/autoland/rev/c3094bf072953ed649b5c81a9466508056e49803 is responsible for this.

I'm verifying that reverting that commit fixes this on top of master.

(In reply to Agi Sferro | :agi | ni? for questions | ⏰ PST | he/him from comment #14)

I'm verifying that reverting that commit fixes this on top of master.

Verified. This indeed appear to be caused by Bug 1341265.

anba: can we get 1341265 backed out? We can't ship beta with this bug in.

Flags: needinfo?(andrebargull)
Regressed by: 1341265
Has Regression Range: --- → yes

iain: requesting to you too since you reviewed the patches.

Flags: needinfo?(iireland)

If reverting that commit fixes this issue, go ahead and back out the patches. This is just a performance improvement; we can figure out the problem and land it again later.

Flags: needinfo?(iireland)

Thanks. I asked the sheriffs to revert the change. I'll verify that the bug is fixed once we have a build.

Flags: needinfo?(andrebargull)

It would be interesting to know why the SM arm32 simulator tests didn't catch this. We also run SM arm64 simulator jobs and Jit tests on actual arm64 devices without failure.

(In reply to Ryan VanderMeulen [:RyanVM] from comment #19)

It would be interesting to know why the SM arm32 simulator tests didn't catch this. We also run SM arm64 simulator jobs and Jit tests on actual arm64 devices without failure.

It would indeed. We definitely need some sort of regression testing for this.

I verified that I can reproduce the bug before the backout: https://treeherder.mozilla.org/jobs?repo=autoland&selectedTaskRun=HMbrGyDaRWO4uxpeHraHHw.0&searchStr=android%2Carm&revision=6f71100cb98ada8eefd9d5bd175543635e85be47

Using GeckoViewExample here: https://firefox-ci-tc.services.mozilla.com/api/queue/v1/task/HMbrGyDaRWO4uxpeHraHHw/runs/0/artifacts/public/build/geckoview_example.apk

And I cannot reproduce the bug after the backout: https://treeherder.mozilla.org/jobs?repo=autoland&searchStr=android%2Carm&revision=a1d9ddb4fb7941b513a163f408f588c966515dc3

Using GeckoViewExample here: https://firefox-ci-tc.services.mozilla.com/api/queue/v1/task/PnZ77K51Tqy1v_JmLmPYbg/runs/0/artifacts/public/build/geckoview_example.apk

(In reply to Ryan VanderMeulen [:RyanVM] from comment #19)

It would be interesting to know why the SM arm32 simulator tests didn't catch this. We also run SM arm64 simulator jobs and Jit tests on actual arm64 devices without failure.

We simply didn't have a test which used the specific inputs needed to trigger this bug. :-/

The bug is only reproducible on 32-bit systems and because x86 doesn't get the optimisations from bug 1341265 in the first place (due to not having enough registers), the bug was effectively ARM32 only.

Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 92 Branch
Whiteboard: [geckoview:m93]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: