jotta / jotta-cli-issues

45 stars 1 forks source link

Selecting "no" during sync setup gives an error. #168

Closed aerique closed 2 years ago

aerique commented 2 years ago

jotta-cli release (jotta-cli version): 0.12.52975 (unstable)

Description of problem:

When setting up sync with jotta-cli sync setup --root /path/to/where/sync/shouldbe at one point the question about selective sync comes up and selecting n gives an error:

The existing sync folder on jottacloud.com contains 22 folders
jotta-cli can selectively ignore one or more of these folders if you do not wish to sync the data to this device
Do you want to setup selective sync? (y/n): n
ERROR  nothing selected

I had to start setup again, select y and then select no folders to ignore.

Expected:

Selecting n should work.

jotta-cli status (jotta-cli status):

Well, it works now, so:

$ jotta-cli status
------------------------------------------------------------------------------
 Account   : user@example.com on Jottacloud
 Usage     : 1.09TiB / 5.00TiB 
 Device    : jottacloud@work-laptop-msi
------------------------------------------------------------------------------
 Sync      :
------------------------------------------------------------------------------
   Path      : /home/user/Jottacloud
   Files     : 0 (0bytes)
   > Downloads : 36 (252.55MiB) / 44091 (43.61GiB)
   Mode      : listening to events
   Status    : Performing updates...
------------------------------------------------------------------------------
 No folders added to backup yet
------------------------------------------------------------------------------
OK

Relevant logs for the issue (~/.jottad/jottabackup.log or /var/lib/jotta/jottabackup.log )

Maybe this?:

pid:18490 2021/12/28 23:08:21 ===========
pid:18490 2021/12/28 23:08:21 Logging in
pid:18490 2021/12/28 23:08:24 login.session.ok
pid:18490 2021/12/28 23:08:24 jottad.startup.update-userinfo => user@example.com
Jottacloud 8dc0bd9ffdf358dbb84983f4e665caac
pid:18490 2021/12/28 23:08:24 updating backup DB from version 0 to 1
pid:18490 2021/12/28 23:08:24 logout.db.reset.ok
pid:18490 2021/12/28 23:08:24 ===========
pid:18490 2021/12/28 23:08:24 running 3 delayed startup tasks
pid:18490 2021/12/28 23:08:24 jottad.sync.setup-check: /home/user/.jottad/sync
/root
pid:18490 2021/12/28 23:08:25 jottad.jnote.connected @ 93f0509e-6826-11ec-9d13-90e
2bae6bf68
pid:18490 2021/12/28 23:08:39 jottad.created-device => jottacloud@work-laptop-msi
pid:18490 2021/12/28 23:11:01 sync.selective.local.err => sync is not started
pid:18490 2021/12/28 23:12:10 sync.selective.local.err => sync is not started
pid:18490 2021/12/28 23:12:25 sync.selective.local.err => sync is not started
pid:18490 2021/12/28 23:12:32 jottad.sync.initalizing => [/home/user/Jottacloud]
pid:18490 2021/12/28 23:12:32 updating sync DB from version 0 to 1
pid:18490 2021/12/28 23:12:32 updating sync DB from version 0 to 2
pid:18490 2021/12/28 23:12:32 error fetching tree: db.loadTree: Missing root
pid:18490 2021/12/28 23:12:32 jottad.sync.initalized => [/home/user/Jottacloud]
pid:18490 2021/12/28 23:12:32 sync debug upload: full
pid:18490 2021/12/28 23:16:15 jottad.sync.starting
[...]

Additional info:

I'm making a jotta-cli package for Guix, which is a kinda "special" Linux distribution, so this could all be my fault.

coopersimon commented 2 years ago

Hi aerique, that shouldn't happen for sure! Thanks for the report, we'll get that fixed for the next release.

coopersimon commented 2 years ago

This is fixed in the newest release.

Also - we have released sync on the stable branch now.

aerique commented 2 years ago

Also - we have released sync on the stable branch now.

That's good to know, thanks!