Getting error with version 3.x SDK

I believe this is the same issue as I faced, reported in this post: Trouble connecting with nodejs

I was solved by awaiting the completion of the first Cluster.connect call. Your initialization seems slightly different so I’m not sure which one needs to be awaited, but I’m fairly confident that is the issue.