[ISSUE] Repeated self-destruct of particle CLI installation

Hey Team,

I'm running the Particle Workbench through VSCode under Win10 Pro, and have been having a recurring issue about once every couple of months with the Particle CLI. Basically everything will be working as normal, then for no reason I can see, both the VS Code Extension and the CLI stops being able to flash my devices, either OTA or by USB, with an error that looks similar to this:

PS E:\Code\Repos\Brn404X\BoronInitTest\target\5.3.0\boron> particle flash XXXXXXXXXXXXXXXX .\BoronInitTest.bin
Cannot find module 'core-js/library/fn/object/assign'
Require stack:
- C:\Users\David\AppData\Local\particle\node_modules\particle-cli\node_modules\babel-runtime\core-js\object\assign.js
- C:\Users\David\AppData\Local\particle\node_modules\particle-cli\node_modules\particle-api-js\lib\Particle.js
- C:\Users\David\AppData\Local\particle\node_modules\particle-cli\src\cmd\api.js
- C:\Users\David\AppData\Local\particle\node_modules\particle-cli\src\cmd\flash.js
- C:\Users\David\AppData\Local\particle\node_modules\particle-cli\src\cli\flash.js
- C:\Users\David\AppData\Local\particle\node_modules\particle-cli\src\cli\index.js
- C:\Users\David\AppData\Local\particle\node_modules\particle-cli\src\app\cli.js
- C:\Users\David\AppData\Local\particle\node_modules\particle-cli\src\index.js
- C:\Users\David\AppData\Local\particle\[eval]

I attempted a particle update-cli, and that returned Updating CLI... no plugins to update.

The fix in the past has been to uninstall and re-install the CLI and all the workbench addons. While this has been a usable workaround, it'd be great if there was something I could do that didn't cost me 1/2 an hour out of my day, as it always seems to crop up when there's an urgent bugfix I want to test. I've had to pull the trigger on the workaround again for today's failure, as I really needed to get this code out for testing, but for the next time it happens, if there's anything else I can try that'd be awesome.

Cheers all,
-- Dave Wood

1 Like

Hi @DKWood - I'll send this to our design team to take a look. Would you be willing to hop on a quick call potentially to discuss further?

Hi Marek,

Thanks for reaching out, and apologies for the delayed reply, I've been somewhat under the pump here with other matters. I'd be happy to discuss when I can make a bit of time, probably later in the week. I'm Sydney (GMT+10) based, so time zones can be a bit of a challenge, but I'm sure we can align somewhere.

-- Dave

Actually @jalbersr -> can you DM @DKWood to schedule a call later this week? Would love to have Ilse on as well, just to take a look at WB from a Design perspective.

Looks like the same issue is getting me. Just out of the blue after Windows forced a restart overnight.

I have attempted "update-cli" with no luck

The un-install and reinstall all the workbench components also has not worked for me.

@Support - mind taking a look?

Is this your CLI or Workbench that's broken?

Could you maybe try the nuclear option and delete your particle directory?
It should be here: C:\Users<your username>\AppData\Local\particle and then try the installer again?

I was not able to compile, I have info under this thread. I did have to nuke the particle directory and I am back up and running.

1 Like

There was an issue with the CLI that an update fixed. Thanks for the feedback though!

1 Like

Just wanted to chime in here - i'm still seeing a similar issue.
I'm at our warehouse reflashing a few dozen Photons and at almost exactly 2:00 EST (~22 minutes before this post) today the cli stopped working. It had been working all morning.

 !   Cannot find module 'pseudomap'
Require stack:
- C:\Users\tommy\AppData\Local\particle\node_modules\particle-cli\node_modules\lru-cache\index.js
- C:\Users\tommy\AppData\Local\particle\node_modules\particle-cli\node_modules\semver\classes\range.js
- C:\Users\tommy\AppData\Local\particle\node_modules\particle-cli\node_modules\semver\classes\comparator.js
- C:\Users\tommy\AppData\Local\particle\node_modules\particle-cli\node_modules\semver\index.js
- C:\Users\tommy\AppData\Local\particle\node_modules\particle-cli\src\lib\has-supported-node.js
- C:\Users\tommy\AppData\Local\particle\node_modules\particle-cli\src\index.js
- C:\Users\tommy\AppData\Local\particle\[eval]
 !   See C:\Users\tommy\AppData\Local\particle\error.log for more info.

I deleted node_modules and updated manually and it seems to be working now... can I disable the automatic updates to prevent this from happening in the future?

1 Like