jjzjj

java - ClassNotFoundException:没有找到类 "com.yandex.metrica.MetricaEventHandler"。统一插件

coder 2023-12-24 原文

应用程序在测试人员设备上崩溃,但在我的设备上没有。我尝试安装 appmetrica 插件,但它不起作用,appmetrica 控制台的统计信息为空并且此错误位于上方。

我找不到这个错误的解决方案。能否请您给出永久解决方案。我不知道如何解决它你能帮我吗?谢谢对不起我的英语。

    1 - java.lang.ClassNotFoundException
    in: dalvik.system.BaseDexClassLoader.findClass
    Tjava.lang.Error: FATAL EXCEPTION [main]Unity version     : 4.7.2f1
    Device model: samsung SM-T116Device fingerprint: samsung/goyave3gxx/goyave3g:4.4.4/KTU84P/T116XXU0AQA2:user/release-keysCaused 
    by: java.lang.RuntimeException: Unable to instantiate receiver com.yandex.metrica.MetricaEventHandler: 
    java.lang.ClassNotFoundException: Didn't find class "com.yandex.metrica.MetricaEventHandler" 
    on path: DexPathList[[zip file "/data/app/coloring.book.app-1.apk"],
    nativeLibraryDirectories=[/data/app-lib/coloring.book.app-1, /vendor/lib, /system/lib]] 
    at android.app.ActivityThread.handleReceiver(ActivityThread.java:2648)  
    at android.app.ActivityThread.access$1700(ActivityThread.java:166)  
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1359) 
    at android.os.Handler.dispatchMessage(Handler.java:102) 
    at android.os.Looper.loop(Looper.java:136)  
    at android.app.ActivityThread.main(ActivityThread.java:5584)    
    at java.lang.reflect.Method.invokeNative(Native Method) 
    at java.lang.reflect.Method.invoke(Method.java:515) 
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268) 
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084)    
    at dalvik.system.NativeStart.main(Native Method)Caused by: java.lang.ClassNotFoundException: 
    Didn't find class "com.yandex.metrica.MetricaEventHandler" 
    on path: DexPathList[[zip file "/data/app/coloring.book.app-1.apk"],
    nativeLibraryDirectories=[/data/app-lib/coloring.book.app-1, /vendor/lib, /system/lib]] 
    at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)   
    at java.lang.ClassLoader.loadClass(ClassLoader.java:497)    
    at java.lang.ClassLoader.loadClass(ClassLoader.java:457)    
    at android.app.ActivityThread.handleReceiver(ActivityThread.java:2643)  ... 10 more

AndroidManifest.xml

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="coloring.book.app" android:installLocation="preferExternal" android:theme="@android:style/Theme.NoTitleBar" android:versionCode="1" android:versionName="1.0">
  <supports-screens android:smallScreens="true" android:normalScreens="true" android:largeScreens="true" android:xlargeScreens="true" android:anyDensity="true" />
  <uses-sdk android:minSdkVersion="14" />

    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
  <uses-permission android:name="android.permission.INTERNET" />
  <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
  <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>

  <application android:icon="@drawable/app_icon" android:label="@string/app_name" android:debuggable="true" android:hardwareAccelerated="true">
    <activity android:name="com.neatplug.u3d.plugins.common.NPUnityPlayerActivity" android:label="@string/app_name" android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen" android:launchMode="singleTask" android:screenOrientation="sensor">
      <intent-filter>
        <action android:name="android.intent.action.MAIN" />
        <category android:name="android.intent.category.LAUNCHER" />
      </intent-filter>
      <meta-data android:name="android.app.lib_name" android:value="unity" />
      <meta-data android:name="unityplayer.ForwardNativeEventsToDalvik" android:value="true" />
    </activity>

    <activity android:configChanges="keyboardHidden|orientation" android:label="@string/app_name" android:name="com.unity3d.player.UnityPlayerActivity">
      <intent-filter>
        <action android:name="android.intent.action.MAIN"/>
        <category android:name="android.intent.category.LAUNCHER"/> 
      </intent-filter>
    </activity>

    <activity android:name="com.unity3d.player.VideoPlayer" android:label="@string/app_name" android:configChanges="keyboard|keyboardHidden|orientation" />
    <activity android:name="com.facebook.unity.FBUnityLoginActivity" android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen" android:theme="@android:style/Theme.Translucent.NoTitleBar.Fullscreen">
    </activity>
    <activity android:name="com.facebook.unity.FBUnityDialogsActivity" android:configChanges="fontScale|keyboard|keyboardHidden|locale|mnc|mcc|navigation|orientation|screenLayout|screenSize|smallestScreenSize|uiMode|touchscreen" android:theme="@android:style/Theme.Translucent.NoTitleBar.Fullscreen">
    </activity>
    <activity android:name="com.facebook.LoginActivity" android:configChanges="keyboardHidden|orientation" android:theme="@android:style/Theme.Translucent.NoTitleBar">
    </activity>
    <activity android:name="com.facebook.unity.FBUnityDeepLinkingActivity" android:exported="true">
    </activity>
    <meta-data android:name="com.facebook.sdk.ApplicationId" android:value="\ 844957685613468" />
    <meta-data android:name="unityplayer.ForwardNativeEventsToDalvik" android:value="true" />
    <activity android:name="com.neatplug.u3d.plugins.facebook.FriendPickerActivity" android:theme="@android:style/Theme.Translucent.NoTitleBar" android:label="@string/app_name" />
    <activity android:name="com.neatplug.u3d.plugins.facebook.LeaderboardActivity" android:theme="@android:style/Theme.Translucent.NoTitleBar" android:label="@string/app_name" />
    <receiver
  android:name="com.google.android.gms.gcm.GcmReceiver"
  android:exported="true"
  android:permission="com.google.android.c2dm.permission.SEND">
  <intent-filter>
    <action android:name="com.google.android.c2dm.intent.REGISTRATION"/>
    <action android:name="com.google.android.c2dm.intent.RECEIVE"/>

    <category android:name="com.yandex.mobile.metricapush.pluginunity"/>
  </intent-filter>
</receiver>
<receiver
  android:name="com.yandex.metrica.push.core.notification.MetricaPushBroadcastReceiver"
  android:exported="false" >
  <intent-filter>
    <action android:name="com.yandex.metrica.push.action.NOTIFICATION_ACTION"/>
  </intent-filter>
</receiver>
<service
  android:name="com.yandex.metrica.push.gcm.MetricaInstanceIDListenerService"
  android:exported="false">
  <intent-filter>
      <action android:name="com.google.android.gms.iid.InstanceID"/>
  </intent-filter>
</service> 
<service
  android:name="com.yandex.metrica.push.PushService"
  android:exported="false">
</service> 

<meta-data android:name="ymp_gcm_project_number" android:value="number:gcm_number"/>

<activity android:name="com.google.ads.AdActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/>

 <activity
        android:name="com.google.android.gms.ads.AdActivity"
        android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/>

<meta-data android:name="com.google.android.gms.version"
           android:value="@integer/google_play_services_version"/> 


    <!-- AppMetrica Services and Receivers -->
    <service android:enabled="true" android:exported="true" android:name="com.yandex.metrica.MetricaService" android:process=":Metrica">
      <intent-filter>
        <category android:name="android.intent.category.DEFAULT"/>
        <action android:name="com.yandex.metrica.IMetricaService"/>
        <data android:scheme="metrica"/>
      </intent-filter>
      <meta-data android:name="metrica:api:level" android:value="52"/>
    </service>
    <receiver android:enabled="true" android:exported="true" android:name="com.yandex.metrica.MetricaEventHandler">
      <intent-filter>
        <action android:name="com.android.vending.INSTALL_REFERRER"/>
      </intent-filter>
    </receiver>

  </application>

</manifest>

最佳答案

您能否提供有关发生崩溃的设备(型号、操作系统版本)的更多信息?看起来问题可能与混淆或多 dex 有关。

关于java - ClassNotFoundException:没有找到类 "com.yandex.metrica.MetricaEventHandler"。统一插件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42834411/

有关java - ClassNotFoundException:没有找到类 "com.yandex.metrica.MetricaEventHandler"。统一插件的更多相关文章

  1. ruby-on-rails - rails : "missing partial" when calling 'render' in RSpec test - 2

    我正在尝试测试是否存在表单。我是Rails新手。我的new.html.erb_spec.rb文件的内容是:require'spec_helper'describe"messages/new.html.erb"doit"shouldrendertheform"dorender'/messages/new.html.erb'reponse.shouldhave_form_putting_to(@message)with_submit_buttonendendView本身,new.html.erb,有代码:当我运行rspec时,它失败了:1)messages/new.html.erbshou

  2. ruby-on-rails - 由于 "wkhtmltopdf",PDFKIT 显然无法正常工作 - 2

    我在从html页面生成PDF时遇到问题。我正在使用PDFkit。在安装它的过程中,我注意到我需要wkhtmltopdf。所以我也安装了它。我做了PDFkit的文档所说的一切......现在我在尝试加载PDF时遇到了这个错误。这里是错误:commandfailed:"/usr/local/bin/wkhtmltopdf""--margin-right""0.75in""--page-size""Letter""--margin-top""0.75in""--margin-bottom""0.75in""--encoding""UTF-8""--margin-left""0.75in""-

  3. ruby - 难道Lua没有和Ruby的method_missing相媲美的东西吗? - 2

    我好像记得Lua有类似Ruby的method_missing的东西。还是我记错了? 最佳答案 表的metatable的__index和__newindex可以用于与Ruby的method_missing相同的效果。 关于ruby-难道Lua没有和Ruby的method_missing相媲美的东西吗?,我们在StackOverflow上找到一个类似的问题: https://stackoverflow.com/questions/7732154/

  4. ruby - 检查 "command"的输出应该包含 NilClass 的意外崩溃 - 2

    为了将Cucumber用于命令行脚本,我按照提供的说明安装了arubagem。它在我的Gemfile中,我可以验证是否安装了正确的版本并且我已经包含了require'aruba/cucumber'在'features/env.rb'中为了确保它能正常工作,我写了以下场景:@announceScenario:Testingcucumber/arubaGivenablankslateThentheoutputfrom"ls-la"shouldcontain"drw"假设事情应该失败。它确实失败了,但失败的原因是错误的:@announceScenario:Testingcucumber/ar

  5. ruby-on-rails - rails 目前在重启后没有安装 - 2

    我有一个奇怪的问题:我在rvm上安装了ruby​​onrails。一切正常,我可以创建项目。但是在我输入“railsnew”时重新启动后,我有“程序'rails'当前未安装。”。SystemUbuntu12.04ruby-v"1.9.3p194"gemlistactionmailer(3.2.5)actionpack(3.2.5)activemodel(3.2.5)activerecord(3.2.5)activeresource(3.2.5)activesupport(3.2.5)arel(3.0.2)builder(3.0.0)bundler(1.1.4)coffee-rails(

  6. ruby - 在没有 sass 引擎的情况下使用 sass 颜色函数 - 2

    我想在一个没有Sass引擎的类中使用Sass颜色函数。我已经在项目中使用了sassgem,所以我认为搭载会像以下一样简单:classRectangleincludeSass::Script::FunctionsdefcolorSass::Script::Color.new([0x82,0x39,0x06])enddefrender#hamlengineexecutedwithcontextofself#sothatwithintemlateicouldcall#%stop{offset:'0%',stop:{color:lighten(color)}}endend更新:参见上面的#re

  7. java - 等价于 Java 中的 Ruby Hash - 2

    我真的很习惯使用Ruby编写以下代码:my_hash={}my_hash['test']=1Java中对应的数据结构是什么? 最佳答案 HashMapmap=newHashMap();map.put("test",1);我假设? 关于java-等价于Java中的RubyHash,我们在StackOverflow上找到一个类似的问题: https://stackoverflow.com/questions/22737685/

  8. ruby-on-rails - 迷你测试错误 : "NameError: uninitialized constant" - 2

    我遵循MichaelHartl的“RubyonRails教程:学习Web开发”,并创建了检查用户名和电子邮件长度有效性的测试(名称最多50个字符,电子邮件最多255个字符)。test/helpers/application_helper_test.rb的内容是:require'test_helper'classApplicationHelperTest在运行bundleexecraketest时,所有测试都通过了,但我看到以下消息在最后被标记为错误:ERROR["test_full_title_helper",ApplicationHelperTest,1.820016791]test

  9. ruby-on-rails - 相关表上的范围为 "WHERE ... LIKE" - 2

    我正在尝试从Postgresql表(table1)中获取数据,该表由另一个相关表(property)的字段(table2)过滤。在纯SQL中,我会这样编写查询:SELECT*FROMtable1JOINtable2USING(table2_id)WHEREtable2.propertyLIKE'query%'这工作正常:scope:my_scope,->(query){includes(:table2).where("table2.property":query)}但我真正需要的是使用LIKE运算符进行过滤,而不是严格相等。然而,这是行不通的:scope:my_scope,->(que

  10. 使用 ACL 调用 upload_file 时出现 Ruby S3 "Access Denied"错误 - 2

    我正在尝试编写一个将文件上传到AWS并公开该文件的Ruby脚本。我做了以下事情:s3=Aws::S3::Resource.new(credentials:Aws::Credentials.new(KEY,SECRET),region:'us-west-2')obj=s3.bucket('stg-db').object('key')obj.upload_file(filename)这似乎工作正常,除了该文件不是公开可用的,而且我无法获得它的公共(public)URL。但是当我登录到S3时,我可以正常查看我的文件。为了使其公开可用,我将最后一行更改为obj.upload_file(file

随机推荐