-
Notifications
You must be signed in to change notification settings - Fork 2
Description
hydra client update works by replacing the running process with pip install git+... to upgrade itself, always installing into the users home folder.
However, since replacing the running process eliminates the side effects of prefixing hydra client update with sudo, if the package is installed under sudo, there's no way for it to update itself.
Anyone with hydra installed under sudo currently (who followed our getting started guide prior to v0.0.3b3) will therefore be unable to use the upgrade helper and must either:
- always use
sudo pip3 install git+https://github.com/shipchain/hydra.git@master, which is longer and inconvenient but pretty much fine, but it needs to be documented somewhere...
or - run this one time right now to remove all the installed versions and just reinstall under your
~/.localdirectory, which will fix this problem for you forever:
pip3 uninstall -y hydra ; sudo pip3 uninstall -y hydra ; pip3 install git+https://github.com/shipchain/hydra.git@master
(and then log out and log in, andhydra -vshould show at least version0.0.3b3on the first line)
Hydra could try to engineer around this by changing off of the os.execpv method, but (1) and (2) above would still be relevant (because if we introduced the fix in v0.0.3b4, you'd still have to manually sudo your upgrade to download it) and frankly I'm not sure how else we can safely make this package update itself while it's still running. I think since we've updated the Getting Started Guide to no longer default to sudo installs, this issue can dangle, we ask users to run (2) above.