Skip to content
This repository has been archived by the owner on May 10, 2021. It is now read-only.

"Error: The field to must have byte length of 20" #266

Open
aijdissanayake opened this issue Feb 12, 2019 · 0 comments
Open

"Error: The field to must have byte length of 20" #266

aijdissanayake opened this issue Feb 12, 2019 · 0 comments

Comments

@aijdissanayake
Copy link

aijdissanayake commented Feb 12, 2019

I'm trying to do a contract interaction with a contract deployed in ropsten test net and I'm getting the above error in the mobile app.

Dapp client side code: (according to the documentation at https://www.npmjs.com/package/uport-connect#quick-start )

import { Connect } from "uport-connect";
import registerResolver from 'ethr-did-resolver';
registerResolver();

const uport = new Connect('Test App 1', {
    network: "ropsten"
});

const approve = async (did) => {
    const uTokenContract = uport.contract(tokenContractABI).at(tokenContractAddress);
    await uTokenContract.approve(ServiceContractAddress, 10000, 'approveReq');
    await uport.onResponse('approveReq').then(payload => {
        const txId = payload.res;
        console.log(txId);
    });
};

Screenshot of the error in mobile app:
51790088_311710029486437_8631397639339900928_n

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

1 participant