MetaMask / MetaMask/metamask-mobile

metamask not showing sign message

Open
#4,526 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
3k
Forks
1.7k
Avg merge
1d 14h
Merged PRs (30d)
669

Description

### **Description**

Describe the task. What does this aim to solve?

### **Technical Details**

- override suspend fun personalSign(message: String): Session.MethodCall.Response {
return withContext(dispatchers.io) {
suspendCoroutine { continuation ->
sessionRepository.address?.let { address ->
sessionRepository.session?.let { session ->
val id = System.currentTimeMillis()
val messageParam = if (message.hasHexPrefix()) message else message.toHex()
Log.d("Sign message","address:${address}message${messageParam}")
session.performMethodCall(
Session.MethodCall.Custom(
id,
"eth_signTypedDataV4 ",
listOf(messageParam,address)
)
) { onResponse(id, it, continuation) }
// requestHandshake()
openWallet()
} ?: continuation.resumeWith(Result.failure(Throwable("Session not found!")))
} ?: continuation.resumeWith(Result.failure(Throwable("Address not found!")))
}
}
}

this code open wallet but not showing sign message

Contributor guide

Open the contributing guide

Research direction

Start with the shown personalSign method and trace session.performMethodCall, the eth_signTypedDataV4 request, and openWallet. Reproduce the call and verify that MetaMask displays the sign-message prompt rather than only opening the wallet.

Written by the indexing model from the issue text.

Assessment

Tech stack
kotlin
Domain
mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.