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

Trezor with Walletconnect #565

Open
jjoshm opened this issue Dec 26, 2021 · 1 comment
Open

Trezor with Walletconnect #565

jjoshm opened this issue Dec 26, 2021 · 1 comment

Comments

@jjoshm
Copy link

jjoshm commented Dec 26, 2021

to reproduce:

  • connect Trezor T
  • open Chrome and navigate to a DApp f.e zapper.fi
  • connect the wallet with Walletconnect and Walleth
  • sign message f.e zapper daily quest
  • enter trezor passphrase in walleth
  • accept passphrase on trezor display
  • accept sign massage on trezor display
  • -> trezor freezes and walleth crashes

Also transactions doesn't work with Walletconnect and Trezor. But the crash only happens when signing

@jjoshm
Copy link
Author

jjoshm commented Dec 26, 2021

after restarting walleth I was able to copy a crash log:

file: /data/user/0/org.walleth/files/0.51.4-1640531611281.tracedroid
Android Version: 10
Phone Model: SM-G965F\nTraceDroid Version: 4.1\nStacktrace: java.lang.RuntimeException: Unable to start service org.walleth.walletconnect.WalletConnectService@f793bcb with null: java.lang.StringIndexOutOfBoundsException: String index out of range: -1
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:4105)
at android.app.ActivityThread.access$1800(ActivityThread.java:219)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1891)
at android.os.Handler.dispatchMessage(Handler.java:107)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7356)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:491)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:940)
Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -1
at java.lang.String.substring(String.java:2064)
at org.walletconnect.Session$Config$Companion.fromWCUri(Session.kt:54)
at org.walleth.walletconnect.WalletConnectHandler.processURI(WalletConnectHandler.kt:22)
at org.walleth.walletconnect.WalletConnectService.onStartCommand(WalletConnectService.kt:91)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:4087)
... 8 more
\nLog: 3 current handler class=com.android.internal.os.RuntimeInit$KillApplicationHandler
3 Writing unhandled exception to: /data/user/0/org.walleth/files/0.51.4-1640531611281.tracedroid
file: /data/user/0/org.walleth/files/0.51.4-1640531610758.tracedroid
Android Version: 10
Phone Model: SM-G965F\nTraceDroid Version: 4.1\nStacktrace: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Method.invoke(Native Method)
at org.walleth.khartwarewallet.trezor.messages.MessageAdapterKt.parseMessageWithType(MessageAdapter.kt:16)
at org.walleth.khartwarewallet.trezor.messages.MessageExchangeManager$readMessage$1.invoke(MessageExchangeManager.kt:51)
at org.walleth.khartwarewallet.trezor.messages.MessageExchangeManager$readMessage$1.invoke(MessageExchangeManager.kt:12)
at org.walleth.khartwarewallet.trezor.usb.USBUtilKt.withUSBRequest(USBUtil.kt:21)
at org.walleth.khartwarewallet.trezor.messages.MessageExchangeManager.readMessage(MessageExchangeManager.kt:26)
at org.walleth.khartwarewallet.trezor.messages.MessageExchangeManager.exchangeMessage(MessageExchangeManager.kt:18)
at org.walleth.trezor.BaseTrezorActivity$connectAndExecute$1$2$1.invokeSuspend(BaseTrezorActivity.kt:89)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
at android.os.Handler.handleCallback(Handler.java:883)
at android.os.Handler.dispatchMessage(Handler.java:100)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7356)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:491)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:940)
Caused by: java.net.ProtocolException: Expected LENGTH_DELIMITED but was 0
at com.squareup.wire.ProtoReader.beforeLengthDelimitedScalar(ProtoReader.kt:400)
at com.squareup.wire.ProtoReader.readString(ProtoReader.kt:263)
at com.squareup.wire.ProtoAdapterKt$commonString$1.decode(ProtoAdapter.kt:724)
at com.squareup.wire.ProtoAdapterKt$commonString$1.decode(ProtoAdapter.kt:709)
at io.trezor.deviceprotocol.ButtonRequest$ProtoAdapter_ButtonRequest.decode(ButtonRequest.java:154)
at io.trezor.deviceprotocol.ButtonRequest$ProtoAdapter_ButtonRequest.decode(ButtonRequest.java:119)
at com.squareup.wire.ProtoAdapter.decode(ProtoAdapter.kt:321)
at com.squareup.wire.ProtoAdapter.decode(ProtoAdapter.kt:319)
... 17 more
\nLog: 3 current handler class=com.android.internal.os.RuntimeInit$KillApplicationHandler
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limi

t at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
I writeMessage: Writing 1 chunks
I writeMessage: Writing 1 chunks
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
I writeMessage: Writing 1 chunks
I writeMessage: Writing 1 chunks
I writeMessage: Writing 1 chunks
I writeMessage: Writing 16 chunks
I writeMessage: Writing 1 chunks
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of

type java.lang.String cannot be converted to JSONArray
W Problem with JSON from EtherScan: Value Max rate limit reached, please use API Key for higher rate limit at result of type java.lang.String cannot be converted to JSONArray
3 Writing unhandled exception to: /data/user/0/org.walleth/files/0.51.4-1640531610758.tracedroid

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@jjoshm and others