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

Not able to inspect Realm db using chrome browser #5260

Closed
anil-k-s opened this issue Sep 14, 2017 · 3 comments
Closed

Not able to inspect Realm db using chrome browser #5260

anil-k-s opened this issue Sep 14, 2017 · 3 comments
Assignees

Comments

@anil-k-s
Copy link

Hi ,

I am using Realm gradle plugin 3.7.2 and stetho realm 2.1.0 , but when I connect to chrome it crashed app and I am not able to inspect db. I am getting below exception
09-14 17:32:57.139 8206-11244/com.sakal.sarkarnama E/AndroidRuntime: FATAL EXCEPTION: StethoWorker-main-123
Process: com.sakal.sarkarnama, PID: 8206
java.lang.NoClassDefFoundError: io/realm/internal/LinkView
at java.lang.Class.getDeclaredMethods(Native Method)
at java.lang.Class.getDeclaredMethods(Class.java:656)
at com.facebook.stetho.inspector.MethodDispatcher.buildDispatchTable(MethodDispatcher.java:115)
at com.facebook.stetho.inspector.MethodDispatcher.findMethodDispatcher(MethodDispatcher.java:53)
at com.facebook.stetho.inspector.MethodDispatcher.dispatch(MethodDispatcher.java:60)
at com.facebook.stetho.inspector.ChromeDevtoolsServer.handleRemoteRequest(ChromeDevtoolsServer.java:129)
at com.facebook.stetho.inspector.ChromeDevtoolsServer.handleRemoteMessage(ChromeDevtoolsServer.java:111)
at com.facebook.stetho.inspector.ChromeDevtoolsServer.onMessage(ChromeDevtoolsServer.java:87)
at com.facebook.stetho.websocket.WebSocketSession$1.handleTextFrame(WebSocketSession.java:176)
at com.facebook.stetho.websocket.WebSocketSession$1.onCompleteFrame(WebSocketSession.java:136)
at com.facebook.stetho.websocket.ReadHandler.readLoop(ReadHandler.java:44)
at com.facebook.stetho.websocket.WebSocketSession.handle(WebSocketSession.java:45)
at com.facebook.stetho.websocket.WebSocketHandler.doUpgrade(WebSocketHandler.java:117)
at com.facebook.stetho.websocket.WebSocketHandler.handleRequest(WebSocketHandler.java:83)
at com.facebook.stetho.server.http.LightHttpServer.dispatchToHandler(LightHttpServer.java:84)
at com.facebook.stetho.server.http.LightHttpServer.serve(LightHttpServer.java:61)
at com.facebook.stetho.inspector.DevtoolsSocketHandler.onAccepted(DevtoolsSocketHandler.java:52)
at com.facebook.stetho.server.ProtocolDetectingSocketHandler.onSecured(ProtocolDetectingSocketHandler.java:63)
at com.facebook.stetho.server.SecureSocketHandler.onAccepted(SecureSocketHandler.java:33)
at com.facebook.stetho.server.LazySocketHandler.onAccepted(LazySocketHandler.java:36)
at com.facebook.stetho.server.LocalSocketServer$WorkerThread.run(LocalSocketServer.java:167)
Caused by: java.lang.ClassNotFoundException: Didn't find class "io.realm.internal.LinkView" on path: DexPathList[[zip file "/data/app/com.sakal.sarkarnama-2.apk"],nativeLibraryDirectories=[/data/app-lib/com.sakal.sarkarnama-2, /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 java.lang.Class.getDeclaredMethods(Native Method) 
at java.lang.Class.getDeclaredMethods(Class.java:656) 
at com.facebook.stetho.inspector.MethodDispatcher.buildDispatchTable(MethodDispatcher.java:115) 
at com.facebook.stetho.inspector.MethodDispatcher.findMethodDispatcher(MethodDispatcher.java:53) 
at com.facebook.stetho.inspector.MethodDispatcher.dispatch(MethodDispatcher.java:60) 
at com.facebook.stetho.inspector.ChromeDevtoolsServer.handleRemoteRequest(ChromeDevtoolsServer.java:129) 
at com.facebook.stetho.inspector.ChromeDevtoolsServer.handleRemoteMessage(ChromeDevtoolsServer.java:111) 
at com.facebook.stetho.inspector.ChromeDevtoolsServer.onMessage(ChromeDevtoolsServer.java:87) 
at com.facebook.stetho.websocket.WebSocketSession$1.handleTextFrame(WebSocketSession.java:176) 
at com.facebook.stetho.websocket.WebSocketSession$1.onCompleteFrame(WebSocketSession.java:136) 
at com.facebook.stetho.websocket.ReadHandler.readLoop(ReadHandler.java:44) 
at com.facebook.stetho.websocket.WebSocketSession.handle(WebSocketSession.java:45) 
at com.facebook.stetho.websocket.WebSocketHandler.doUpgrade(WebSocketHandler.java:117) 
at com.facebook.stetho.websocket.WebSocketHandler.handleRequest(WebSocketHandler.java:83) 
at com.facebook.stetho.server.http.LightHttpServer.dispatchToHandler(LightHttpServer.java:84) 
at com.facebook.stetho.server.http.LightHttpServer.serve(LightHttpServer.java:61) 
at com.facebook.stetho.inspector.DevtoolsSocketHandler.onAccepted(DevtoolsSocketHandler.java:52) 
at com.facebook.stetho.server.ProtocolDetectingSocketHandler.onSecured(ProtocolDetectingSocketHandler.java:63) 
at com.facebook.stetho.server.SecureSocketHandler.onAccepted(SecureSocketHandler.java:33) 
at com.facebook.stetho.server.LazySocketHandler.onAccepted(LazySocketHandler.java:36) 
at com.facebook.stetho.server.LocalSocketServer$WorkerThread.run(LocalSocketServer.java:167) 

@Zhuinden
Copy link
Contributor

I'd assume it's because stetho-realm 2.1.0 is not compatible with Realm 3.7.1+ because it relies on io.realm.internal.LinkView which was replaced by io.realm.internal.OsList.

https://github.com/uPhyca/stetho-realm/blob/06ca641848c6fa57d23e78181335bf9f17958ee9/stetho_realm/src/main/java/com/uphyca/stetho_realm/Database.java#L32

@zaki50
Copy link
Contributor

zaki50 commented Sep 16, 2017

@Zhuinden Ah, yes! I need to update stetho-realm to support 3.7.1 or later.
I'll work on it after the current task (perhaps in this month).

@cmelchior
Copy link
Contributor

Closing this issue as it should be tracked here uPhyca/stetho-realm#62 instead

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 16, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants