Thanks to visit codestin.com
Credit goes to github.com

Skip to content

client.getAccountTransaction results in an error #41

@toshirot

Description

@toshirot

this code worked on 2019-09-01, but now I get an error.

code test-tx.js

  const libracore =require('libra-core')

  const client = new libracore.LibraClient({ network: libracore.LibraNetwork.Testnet });
  const accountAddress = '7f58df27522872ecfac340c5c072427e6f8083ca3c79bb748cdd1ae073dacc42';
  const sequenceNumber = 43; //can also use a string for really large sequence numbers;

  const transaction = client.getAccountTransaction(accountAddress, sequenceNumber); 

Run

node test-tx.js

Error

/home/tato/kabuda.net/html/test/libra/libra-core/node_modules/libra-core/build/client/Decoder.js:39
        const signedTransaction = signedTransactionWP.getSignedTransaction();
                                                      ^

TypeError: Cannot read property 'getSignedTransaction' of undefined
    at ClientDecoder.decodeSignedTransactionWithProof (/home/tato/kabuda.net/html/test/libra/libra-core/node_modules/libra-core/build/client/Decoder.js:39:55)
    at /home/tato/kabuda.net/html/test/libra/libra-core/node_modules/libra-core/build/client/index.js:109:38
    at Object.onReceiveStatus (/home/tato/kabuda.net/html/test/libra/libra-core/node_modules/grpc/src/client_interceptors.js:1207:9)
    at InterceptingListener._callNext (/home/tato/kabuda.net/html/test/libra/libra-core/node_modules/grpc/src/client_interceptors.js:568:42)
    at InterceptingListener.onReceiveStatus (/home/tato/kabuda.net/html/test/libra/libra-core/node_modules/grpc/src/client_interceptors.js:618:8)
    at callback (/home/tato/kabuda.net/html/test/libra/libra-core/node_modules/grpc/src/client_interceptors.js:845:24)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions