Post AaSBPDvxVefsLB0sGu by nmoo@mas.to
 (DIR) More posts by nmoo@mas.to
 (DIR) Post #AaSBPAlZHpa2W5829w by nmoo@mas.to
       2023-10-05T03:54:47Z
       
       0 likes, 1 repeats
       
       OH MY GOD I have apparently been running the `x64` build of Node for YEARS on my M1 and M2 machines. 🫠I was slowly going crazy with random errors like `[block != nullptr]: BasicBlock requested for unrecognized address (BuilderBase.h:550 block_for_offset)` which was apparently because Node was running in Rosetta.I was finally able to discover that `/usr/local/bin` was ahead of `/opt/homebrew/bin` in my path.
       
 (DIR) Post #AaSBPDvxVefsLB0sGu by nmoo@mas.to
       2023-10-05T03:56:00Z
       
       0 likes, 0 repeats
       
       I really do not want to think about how many cumulative hours I've wasted because of this over the years.On the plus side, my build times just improved a ridiculous amount!
       
 (DIR) Post #AaSBPFwk1iUMaBOWlk by nmoo@mas.to
       2023-10-05T03:59:21Z
       
       0 likes, 0 repeats
       
       Quick gut check if you think you might have the same issue:Open your terminal. Run `arch`. It should print `arm64`.Now run `node -p "os.arch()"`. It should also print `arm64`. If it doesn't, you've got the same problem I did.
       
 (DIR) Post #AaSBPKVd3wlwjXkRhg by nmoo@mas.to
       2023-10-05T04:06:58Z
       
       0 likes, 0 repeats
       
       And before you ask, yes I have been using multiple Node version management tools. Guess what?! They were all installed with `brew` to the `/usr/local/bin` path (the wrong one). When they tried to install Node, they checked which architecture was running and installed a matching build for Node (also the wrong one).AHHHHHHHHHHH