When I try to sign a message with this simple function const signatue = await window.web3.eth.sign(hash, userAddress) I get an error.

In firefox I get Unhandled promise rejection DOMException: "The object could not be cloned."

The actual data I put into this function for example are: hash 0x2339863461be3f2dbbc5f995c5bf6953ee73f6437f37b0b44de4e67088bcd4c2 account_address 0x627306090abab3a6e1400e9345bc60c78a8bef57

I am using "web3": "^1.0.0-beta.47" and Metamask 6.1.0.

In "1.0.0-beta.46" Iam getting error I have already mentioned there Cannot sign a message with web3js (invalid from address)

In beta "^1.0.0-beta.37" everything works fine.

Please help me :(

The same error in chrome

              if (!error) {
   ...<omitted>... } could not be cloned.
    at i._write (chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn/inpage.js:1:114976)
    at b (chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn/inpage.js:1:133822)
    at chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn/inpage.js:1:136934
    at i.g.write (chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn/inpage.js:1:136961)
    at e.exports.y (chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn/inpage.js:1:126211)
    at chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn/inpage.js:1:37123
    at e.exports.s.emit (chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn/inpage.js:1:37193)
    at w (chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn/inpage.js:1:121050)
    at _ (chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn/inpage.js:1:120865)
    at e.exports.b.push (chrome-extension://nkbihfbeogaeaoehlefnkodbefgpgknn/inpage.js:1:121676)```

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.