Squirrel / Squirrel.Windows

An installation and update framework for Windows desktop apps
MIT License
7.35k stars 1.03k forks source link

Can't acquire lock for uninstalling, when updating #1709

Open Alonzzzo2 opened 3 years ago

Alonzzzo2 commented 3 years ago

This just happened to me. Tried to uninstall but at the squirrel-uninstall log, I get 'Failed to grab lockfile'. Though it retries to grab the lock for a couple of times, it failed every time, cause during this time, my app was checking for update / downloading and installing an update.

I think the fix may be to kill the app before acquiring the lock, if that doesn't break anything.

WDYT?

anaisbetts commented 3 years ago

Your app is most likely running while being uninstalled - tbh, I wouldn't worry about this, if a user uninstalls an app while it's running they kindaaaaa should expect things to Not Go Smoothly

Alonzzzo2 commented 3 years ago

Thanks What if the kill-the-app code will run before trying to acquire the lock? Its a solution for this scenario, if it doesn't cause other issues