defold / extension-admob

Defold native extension which provides access to AdMob functionality on Android and iOS
https://www.defold.com/extension-admob/
MIT License
37 stars 12 forks source link

Crash when viewing ads. #14

Closed VLAHIN closed 1 year ago

VLAHIN commented 2 years ago

crash When viewed for the first time, it works fine, but when you view ads again in the same game session, the game just closes, giving these errors. Another cache of the game grows to 4 mb.

JCash commented 2 years ago

In your screenshot, you only include messages from one process, and it's not a callstack from the engine itself. I think you should use the full logcat to see what errors are output there.

Also, please avoid screenshots of text, as it makes it much harder to read, but also harder to copy paste and search with.

VLAHIN commented 2 years ago

На вашем скриншоте вы включаете только сообщения от одного процесса, и это не стек вызовов от самого движка. Я думаю, вам следует использовать полный журнал, чтобы увидеть, какие ошибки там выводятся.

Кроме того, избегайте снимков экрана с текстом, так как это затрудняет чтение, но также затрудняет копирование, вставку и поиск.

How can I collect information in more detail? Big cache games can be the reason? After all, when you launch ads for the first time, everything is fine, and the subsequent ones already cause a failure. Maybe there is a way to clear the data after browsing?

JCash commented 2 years ago

I'd recommend using adb logcat to get the full log (i.e. remove the "-s defold"). That way there should be much more detailed information about what went wrong.

As for the functionality itself, I'd have to ask @AGulev or @britzl if they perhaps knows more about it.

britzl commented 2 years ago

@VLAHIN could you please try the example app that comes with the extension?

VLAHIN commented 2 years ago

@VLAHIN, не могли бы вы попробовать пример приложения, которое поставляется с расширением?

The example does not load or display ads. And so there is no advertising for a reward, in which I have a crash. =)

VLAHIN commented 2 years ago

Full log during a crash

logcat.txt

VLAHIN commented 2 years ago

I found out that it has something to do with the webview.I set the developer mode to multiprocessing webview and the problem disappeared. (there were no crashes in 20 minutes of playing and watching ads). But I don’t understand yet whether other users will have such a problem in the release version.

britzl commented 2 years ago

The example does not load or display ads

It doesn't? I tested it on a device running Android 11 a week ago and as far as I recall it worked as expected. @AGulev any ideas?

I found out that it has something to do with the webview.I set the developer mode to multiprocessing webview and the problem disappeared.

What kind of Android device are you testing on?

VLAHIN commented 2 years ago

На каком устройстве Android вы тестируете?

Meizu M5 Note. I have installed UnityAds. It works without interruption. I found a thread on stackoverflow , it says it's because of the webview. I don’t know how to solve this yet. Perhaps my device is not working correctly, because the webview is built into the shell of the operating system and it is not possible to update it. If you need more information, please tell me what needs to be done.

britzl commented 2 years ago

I'm not sure how to proceed. @AGulev do you have any ideas?

AGulev commented 2 years ago

@VLAHIN so, if I understand right you can't download and install(or update) this app ? https://play.google.com/store/apps/details?id=com.google.android.webview&hl=en_GB&gl=US

VLAHIN commented 2 years ago

@VLAHIN Итак, если я правильно понимаю, вы не можете загрузить и установить (или обновить) это приложение? https://play.google.com/store/apps/details?id=com.google.android.webview&hl=en_GB&gl=US

I'm not sure if this crash is due to this. Doesn't unity ads also use webview? And there is no such problem. I can install this particular application, but I have two such applications. One installed and one system built into the shell.

AGulev commented 2 years ago

I'm not sure if there is something we can do on the extension side. Crashlog doesn't contain anything related to the engine/extension:

09-03 01:41:11.887 31460 31460 W google-breakpad: ### ### ### ### ### ### ### ### ### ### ### ### ###
09-03 01:41:11.887 31460 31460 W google-breakpad: Chrome build fingerprint:
09-03 01:41:11.887 31460 31460 W google-breakpad: 1.0
09-03 01:41:11.888 31460 31460 W google-breakpad: 1
09-03 01:41:11.888 31460 31460 W google-breakpad: c212fd71-e1d3-4b49-9f08-878f16747dd9
09-03 01:41:11.888 31460 31460 W google-breakpad: ### ### ### ### ### ### ### ### ### ### ### ### ###
09-03 01:41:11.967 31460 31460 I defold  : INFO:CRASH: Successfully wrote Crashdump to file: /data/user/0/com.example.todo/files/_crash
09-03 01:41:11.967 31460 31460 E defold  : ERROR:CRASH: CALL STACK:
09-03 01:41:11.967 31460 31460 E defold  : 
09-03 01:41:11.967 31460 31460 E defold  : # 0 pc       0x1fd1 /system/bin/app_process32 InvokeUserSignalHandler+156
09-03 01:41:11.967 31460 31460 E defold  : # 1 pc     0x13f07f /system/lib/libart.so _ZN3art12FaultManager11HandleFaultEiP7siginfoPv+222
09-03 01:41:11.967 31460 31460 E defold  : # 2 pc      0x170b4 /system/lib/libc.so <unknown>+0
09-03 01:41:11.967 31460 31460 E defold  : # 3 pc     0x24d5ac /system/app/webview/webview.apk <unknown>+0
09-03 01:41:11.967 31460 31460 E defold  : # 4 pc     0x26b7fd /system/app/webview/webview.apk <unknown>+0
09-03 01:41:11.967 31460 31460 E defold  : # 5 pc     0x26b877 /system/app/webview/webview.apk <unknown>+0
09-03 01:41:11.967 31460 31460 E defold  : # 6 pc      0x438f7 ...@webview@webview.apk@classes.dex <unknown>+0
09-03 01:41:11.967 31460 31460 E defold  : 
09-03 01:41:11.967 31460 31460 E defold  : 
09-03 01:41:11.968 31460 31460 F libc    : Fatal signal 11 (SIGSEGV), code 1, fault addr 0x0 in tid 31460 (om.example.todo)
09-03 01:41:11.971 31709 31709 I AEE_AED : handle_request(0)
09-03 01:41:11.972 31709 31709 I AEE_AED : check process 31460 name:om.example.todo
09-03 01:41:11.972 31709 31709 I AEE_AED : tid 31460 abort msg address:0x00000000, si_code:1 (request from 31460:10296)
09-03 01:41:11.972 31709 31709 W AEE_AED : debuggerd: handling request: pid=31460 uid=10296 gid=10296 tid=31460
09-03 01:41:11.974 31709 31709 I AEE_AED : [preset_info] pid: 31460, tid: 31460, name: om.example.todo  >>> com.example.todo <<<
09-03 01:41:12.006  1078  1213 I PerfService: PerfServiceNative_boostEnableAsync:6
09-03 01:41:12.040   313   313 I wmt_launcher: fw log ctrl flag has been set
09-03 01:41:12.040   313   313 I wmt_launcher: fw dynamic ctrl flag has been set
09-03 01:41:12.075  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.075  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.076  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.076  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.076  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.076  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.077  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.077  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.077  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.077  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.077  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.077  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.078  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.078  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.078  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.078  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.079  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.079  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.079  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.079  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.079  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.079  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.080  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.080  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.080  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.080  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.080  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.081  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.081  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.081  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.081  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.081  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.081  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.081  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.082  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.082  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.091  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.091  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.091  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.091  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.091  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.091  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.092  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.092  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.092  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.092  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.092  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.092  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.093  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.093  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.093  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.094  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.094  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.094  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.094  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.094  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.094  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.095  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.095  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.095  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.095  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.095  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.095  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.096  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.096  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.096  1325  1325 I FlymeFontsHelper: UserId == 0
09-03 01:41:12.099 31709 31709 I AEE_AED : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
09-03 01:41:12.099 31709 31709 I AEE_AED : Build fingerprint: 'Meizu/M1621/M1621:7.0/NRD90M/1552461762:user/release-keys'
09-03 01:41:12.099 31709 31709 I AEE_AED : Revision: '0'
09-03 01:41:12.099 31709 31709 I AEE_AED : ABI: 'arm'
09-03 01:41:12.099 31709 31709 I AEE_AED : pid: 31460, tid: 31460, name: om.example.todo  >>> com.example.todo <<<
09-03 01:41:12.099 31709 31709 I AEE_AED : signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
09-03 01:41:12.099 31709 31709 I AEE_AED :     r0 00000000  r1 e592a460  r2 ffbf7664  r3 00000000
09-03 01:41:12.099 31709 31709 I AEE_AED :     r4 ffbf75cc  r5 e73ed008  r6 ffbf75b4  r7 12fc9f10
09-03 01:41:12.099 31709 31709 I AEE_AED :     r8 00000000  r9 ffbf7660  sl e592a460  fp bc1b1a00
09-03 01:41:12.099 31709 31709 I AEE_AED :     ip ccba385d  sp ffbf75a8  lr ccba3801  pc ccb855b0  cpsr 200f0030
09-03 01:41:12.102 31709 31709 I AEE_AED : 
09-03 01:41:12.102 31709 31709 I AEE_AED : backtrace:
09-03 01:41:12.102 31709 31709 I AEE_AED :     #00 pc 0024d5b0  /system/app/webview/webview.apk (offset 0x4d3e000)
09-03 01:41:12.102 31709 31709 I AEE_AED :     #01 pc 0026b7fd  /system/app/webview/webview.apk (offset 0x4d3e000)
09-03 01:41:12.102 31709 31709 I AEE_AED :     #02 pc 0026b877  /system/app/webview/webview.apk (offset 0x4d3e000)
09-03 01:41:12.102 31709 31709 I AEE_AED :     #03 pc 001f88f7  /data/dalvik-cache/arm/system@app@webview@webview.apk@classes.dex (offset 0x1b5000)

Yes, Unity uses webview as well. But everything related to webview itself is inside bothe these SDKs. The extension does nothing with webview.

@VLAHIN, не могли бы вы попробовать пример приложения, которое поставляется с расширением?

The example does not load or display ads. And so there is no advertising for a reward, in which I have a crash. =)

Could you please try to test the example application of the admob extension on your phone one more time and make sure you use Debug version of the app (it won't work in release version)

bedryck commented 2 years ago

admob Hey guys, I have strange behavior on my android emulator. Maybe it doesn't relate to this issue, but it can have sense. When I call load_interstitial or load_rewarded and API returns CODE: 0, everything ok, but when I call load_banner I think I have code 0as well, but the app crashed. Check the attached gif it more clear)

AGulev commented 2 years ago

@bedryck I've never tested it on emulator if you can repo it on a device as well, please open a ticket with logs.

bedryck commented 2 years ago

Sure, I can do it in 4-5 days when I will have a device. I was just worried that this could happen on a real device.

britzl commented 1 year ago

No update from user. Closing.