hypercore-protocol / hyperdrive-daemon

Hyperdrive, batteries included.
MIT License
156 stars 23 forks source link

[fs mount] relative paths result in error #23

Open edrex opened 4 years ago

edrex commented 4 years ago

So this is happening (@beta, clean ~/.hyperdrive):

❯ cd ~/Hyperdrive/home   
❯ hyperdrive fs mount how-to-dweb 3e2b381627df0d670bdb2c5e45ac851225266836aba0c5f727261669f47c91dc
Could not mount the drive:
Error: You can only mount drives underneath the root drive at /home/eric/Hyperdrive/home

See also #21.

andrewosh commented 4 years ago

Hey @edrex,

Sorry you hit those issues over the weekend! Looks like you figured out that all the latest development's been happening on hyperdrive-daemon@beta on npm -- I'm gonna publish a note in the README and also push a patch to the latest tag that prints a message making this clear.

As for the CLI arguments to the various commands, we changed the mounting approach recently so that there's a hidden mountpoint in ~/.hyperdrive/mnt which is then symlinked to ~/Hyperdrive. The main motivation for doing that is just to make things cleaner in the OSX Finder. Unfortunately that had the side-effect of breaking the default arguments for the commands (since the current working directory resolves to the "hidden" mountpoint, unfortunately). The fix is coming today.

In the meantime, a quick fix is to just use absolute paths for all the CLI arguments.

Thanks for opening the issues -- really helpful for us! General note though: we're iterating quickly but expect things to be rough around the edges. Though there's a beta tag published, we haven't publicly entered the "beta-ready" state yet. Fair warning :)

edrex commented 4 years ago

I'm here as a fresh-eyed tester DLv77AkUMAI-sQ6 but I hear you that you're still iterating on features so it's a bit early. I'll keep my feedback to stuff that seems final and otherwise avoid making your tracker noisy while you're trying to focus on finishing up features.

I'm gonna publish a note in the README and also push a patch to the latest tag that prints a message making this clear.

SGTM, #20 can close then.

In the meantime, a quick fix is to just use absolute paths for all the CLI arguments.

I found that workaround, should have dropped a comment. Thank you :)