jest-dynamodb icon indicating copy to clipboard operation
jest-dynamodb copied to clipboard

Issue in globalSetup after upgrading to Node 18

Open mahdi opened this issue 1 year ago • 2 comments

After upgrading to Node 18, I'm unable to run tests with Jest and after debugging it I noticed that it's throwing the following error while trying to run this: [dynamoDB.listTables({})]

Error: connect ECONNREFUSED ::1:8052
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1487:16) {
  errno: -61,
  code: 'ECONNREFUSED',
  syscall: 'connect',
  address: '::1',
  port: 8052,
  '$metadata': { attempts: 1, totalRetryDelay: 0 }
}

It seems that this happens on my local machine only as when CircleCI tried to run the tests everything worked fine.

mahdi avatar Jan 16 '23 16:01 mahdi

What OS are you running locally? Could it be b/c of missing Java that is required to run DDB local?

vladholubiev avatar Feb 06 '23 12:02 vladholubiev

Confirmed that Node 18 fails. See https://github.com/shelfio/jest-dynamodb/issues/194

Downgrading to Node 16 and it runs fine. Java is installed ofc, openjdk version "11.0.16" 2022-07-19

paul-uz avatar Mar 03 '23 15:03 paul-uz