Can't connect to mongodb using golang

I have been trying to connect to mongodb for days using the official driver I get errors I don’t understand
“Panic: unaligned 64-bit atomic operation”
With some some sequence of
runtime/internal/atomic.panicUnaligned

I have the same problem, did you find any solution ?

1 Like

Not yet but I tried hosting a mongodb and golang app on heroku it worked perfectly without any error

Note only on heroku, still not working on my pc

Hey @Usman_Maaji, a seemingly similar problem was resolved recently by PR #723 and released with Go Driver v1.7.3. Please try updating to v1.7.3 and see if that resolves your build issue.

Out of curiosity, what platform are you trying to build on when you get that “Panic: unaligned 64-bit atomic operation” error?

Fixed the issue, as @Matt_Dale said it was related to the go driver + library arm version (even though i purchased a 64 bit raspberry, it seemed i got delivered a 32 bit version which created a lot of library conflicts, reorder and reinstalled everything properly and it worked)

Thank you for the suggestion!