Refusing to connect to local node

Hey everyone, I just started on the Cosmos SDK and want to write a script that can sign and send transactions via a remote call.
I started by following this tutorial:
I have a local node running, I can send transactions, I can see the transactions passing through.
Now, to send transactions from a remote call, I am using CosmJS, once I write my script then any website can use that CosmJS script.
I am following this tutorial:

I make sure my node is running, but when I run the experiment-local.ts, I get this error:

TypeError: fetch failed
    at Object.fetch (node:internal/deps/undici/undici:11929:11)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async HttpClient.execute (code/cosmos/cosmjs-sandbox/node_modules/@cosmjs/tendermint-rpc/src/rpcclients/httpclient.ts:52:43)
    at async Function.detectVersion (code/cosmos/cosmjs-sandbox/node_modules/@cosmjs/tendermint-rpc/src/tendermint34/tendermint34client.ts:42:22)
    at async Function.create (code/cosmos/cosmjs-sandbox/node_modules/@cosmjs/tendermint-rpc/src/tendermint34/tendermint34client.ts:36:22)
    at async Function.connect (code/cosmos/cosmjs-sandbox/node_modules/@cosmjs/stargate/src/stargateclient.ts:155:22)
    at async runAll (code/cosmos/cosmjs-sandbox/experiment-local.ts:16:20) {
  cause: Error: connect ECONNREFUSED
      at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1481:16) {
    errno: -111,
    code: 'ECONNREFUSED',
    syscall: 'connect',
    address: '',
    port: 26657

What could be an issue causing this to fail to connect?
I cannot seem to find anything related to error code -111
Any help is appreciated :slight_smile:

I also can probably get the same results by writing a Go script and having it run on a server that talks to my node, but the example found here seems to be missing some details:
Since I based my node off the simd app that runs on v0.45.4
I also need to make sure that I am using the proper methods for the proper version

Scam. Don’t click anything from this bottom feeder for “support”.

Hey Ryan, just wanted to confirm something. I included some links to the official cosmos tutorials just to give better context on what I was doing since everything I have written up has been directly taken from the cosmos tutorial. Is there anything wrong with what I posted?

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.