Photon disconnected from WiFi, cli stopped working

Hi guys,

yesterday, my Photon, which was working for about 4 months stopped connecting to home wi-fi - green led is flashing constantly. Reset, soft reset doesn’t help.

I performed wi fi reset and wanted to use cli to update the credentials, however cli is not working for me anymore as well. I reinstalled cli, now it shows me this:

user:~ user$ particle
Error loading command /usr/local/lib/node_modules/particle-cli/commands/AccessTokenCommands.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/CloudCommands.js Error: Cannot find module 'serialport'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/ConfigCommand.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/FlashCommand.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/FunctionCommand.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/HelpCommand.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/KeyCommands.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/PublishCommand.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/SerialCommand.js Error: Cannot find module 'serialport'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/SetupCommand Error: Cannot find module 'bl'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/SubscribeCommand.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/UpdateCommand.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/VariableCommand.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/WebhookCommands.js Error: Cannot find module 'brace-expansion'
Error loading command /usr/local/lib/node_modules/particle-cli/commands/WirelessCommand Error: Cannot find module 'brace-expansion'
particle: Unknown command: "help"

Does anyone know what happened and how it can be solved? Thank you

UPD:
cli problem solved, had to clean npm cache. Still interested why Photon stopped connecting to wifi

What happens if you place the Photon in safe mode? Does it connect?

I tried that, but Photon was flashing green all the time, not connecting to wifi

Have you been able to wipe the WiFi credentials and set them anew?

A possible reason (at least pre 0.4.9) was that if your device suffered a brown-out the credentials (or other settings) could get corrupted. I'm not sure if this was already fixed tho'.

(or has something with your WiFi changed - new neighbhour with a "loud" WiFi interfering with yours?)

Thanks for your answer

Yes, I wiped it out wifi list and reconncted successfully. The main reason for this long test was the reliability, since many Blynk clients ask about that. This is why it’s really important to figure out what have happened.

Huh? What do you mean with that? I'm unaware of this command :blush:

If you mean particle wireless list then this does not wipe previous credentials from the device.

Sorry for the confusion. I pressed the setup button for 10 sec to wipe out the known wifi networks. Then used cli to connect to home wifi.

There is a chance that something happened to the router, but I can’t imagine what. I guess we never know now what happened. Have you experienced smth like this before?

I have two routers with one SSID and I sometimes get similar things.
Also lease time and running out of DHCP IPs when I’ve got lots of guests on my guest LAN cause similar issues.