Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/mobile: loading webviewchromium after Go.init crashes on 5.0.1 #9507

Closed
dskinner opened this issue Jan 5, 2015 · 7 comments

Comments

Projects
None yet
7 participants
@dskinner
Copy link
Member

commented Jan 5, 2015

After Go.init(this), attempting to call PublisherAdView.loadAd from com.google.android.gms:play-services:6.5.87 causes crash on 5.0.1 but not previous 4.x versions of android. PublisherAdView uses a WebView to load ads.

Very little information is provided in logcat on crash

7911-7911/com.app I/WebViewFactory﹕ Loading com.google.android.webview version 37 (1602158-arm) (code 111201)
7911-7911/com.app I/LibraryLoader﹕ Loading: webviewchromium
7911-7911/com.app E/libsigchain﹕ Warning: Unexpected sigaction action found 0xaff5decc
7911-7911/com.app I/LibraryLoader﹕ Time to load native libraries: 4 ms (timestamps 3728-3732)
7911-7911/com.app I/LibraryLoader﹕ Expected native library version number "",actual native library version number ""
7911-7911/com.app V/WebViewChromiumFactoryProvider﹕ Binding Chromium to main looper Looper (main, tid 1) {2bc39a28}
7911-7911/com.app I/LibraryLoader﹕ Expected native library version number "",actual native library version number ""
7911-7911/com.app I/chromium﹕ [INFO:library_loader_hooks.cc(106)] Chromium logging enabled: level = 0, default verbosity = 0
7911-7911/com.app I/BrowserStartupController﹕ Initializing chromium process, renderers=0
7911-7911/com.app W/art﹕ Attempt to remove local handle scope entry from IRT, ignoring
7911-7911/com.app W/chromium﹕ [WARNING:resource_bundle.cc(315)] locale_file_path.empty()
7911-7911/com.app I/chromium﹕ [INFO:aw_browser_main_parts.cc(63)] Load from apk succesful, fd=54 off=46780 len=2953
7911-7911/com.app I/chromium﹕ [INFO:aw_browser_main_parts.cc(78)] Loading webviewchromium.pak from, fd:55 off:229484 len:643667
7911-8173/com.app W/AudioManagerAndroid﹕ Requires BLUETOOTH permission
7911-7911/com.app I/Ads﹕ Starting ad request.
8185-8185/? I/dex2oat﹕ /system/bin/dex2oat --runtime-arg -classpath --runtime-arg  --instruction-set=arm --instruction-set-features=div --runtime-arg -Xrelocate --boot-image=/system/framework/boot.art --dex-file=/data/data/com.app/cache/ads1534321150.jar --oat-fd=86 --oat-location=/data/data/com.app/cache/ads1534321150.dex --runtime-arg -Xms64m --runtime-arg -Xmx512m
8185-8185/? I/dex2oat﹕ dex2oat took 82.342ms (threads: 2)
400-915/? I/WindowState﹕ WIN DEATH: Window{3d2a37ef u0 com.app/com.app.GridActivity}
130-130/? I/Zygote﹕ Process 7911 exited due to signal (11)
400-414/? I/ActivityManager﹕ Process com.app (pid 7911) has died

Notable is E/libsigchain﹕ Warning: Unexpected sigaction action found 0xaff5decc after webviewchromium loads native code, which is an error from the ART runtime: https://android.googlesource.com/platform/art/+/master/sigchainlib/sigchain.cc#161

I believe that's why 4.x is not affected. I was not able to reproduce this issue with the sole use of a simple WebView loading a website.

I have found that allowing a single PublisherAdView.load call to complete successfully (to allow webviewchromium native code to load first) followed by Go.init does work successfully, including afterwards creating new ad views and more calls to PublisherAdView.load.

I'll put together a minimal sample soon.

@minux

This comment has been minimized.

Copy link
Member

commented Jan 5, 2015

the ownership of signal handlers is going to be an issue when
mixing two runtimes (ART and Go).

@mikioh mikioh added the repo-mobile label Jan 5, 2015

@rsc rsc added this to the Unplanned milestone Apr 10, 2015

@rsc rsc changed the title mobile: loading webviewchromium after Go.init crashes on 5.0.1 x/mobile: loading webviewchromium after Go.init crashes on 5.0.1 Apr 14, 2015

@rsc rsc modified the milestones: Unreleased, Unplanned Apr 14, 2015

@rsc rsc removed the repo-mobile label Apr 14, 2015

@crawshaw

This comment has been minimized.

Copy link
Contributor

commented Jul 14, 2015

I believe the basic signal forwarding added in https://golang.org/cl/8712 (5c8fbc6) takes care of this.

@crawshaw crawshaw closed this Jul 14, 2015

@dskinner

This comment has been minimized.

Copy link
Member Author

commented Jul 17, 2015

I don't think this is resolve unless my issue is related to something separate. I'm still experiencing a crash that's the same as the original reported.

If a sample app would be helpful, I'd be happy to produce this based on the latest gomobile bits. I tested this against

golang: a81c656
gomobile:32ad533813ffd084a

producing an aar from such for inclusion in a project

@dskinner

This comment has been minimized.

Copy link
Member Author

commented Jul 17, 2015

sorry, updating the original but go hash is: a81c656

@crawshaw

This comment has been minimized.

Copy link
Contributor

commented Jul 17, 2015

If you can provide a failing program I'll take a look next week.

@crawshaw crawshaw reopened this Jul 17, 2015

@crawshaw crawshaw self-assigned this Jul 17, 2015

@dskinner

This comment has been minimized.

Copy link
Member Author

commented Jul 17, 2015

ok, will do, as a heads up, the program will use RecyclerView to interlace PublisherAdView's in a stream of stories (such as slashdot) which should reproduce the issue.

@hyangah

This comment has been minimized.

Copy link
Contributor

commented Sep 23, 2015

Looking into #12725, I guess this is related to misuse of the context.
We no longer require the go.Go class. I am closing this issue. (obsolete)

@hyangah hyangah closed this Sep 23, 2015

@golang golang locked and limited conversation to collaborators Sep 23, 2016

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.