From c3dfa7d9a3aae98ee544e0de839bdd4b64b79292 Mon Sep 17 00:00:00 2001 From: Nick Craig-Wood Date: Tue, 12 Jan 2021 17:09:44 +0000 Subject: [PATCH] jottacloud: fix token refresh failed: is not a regular file error Before this change the jottacloud token renewer would run and give the error: Token refresh failed: is not a regular file This is because the refresh runs on the root and it isn't a file. This was fixed by ignoring that specific error. See: https://forum.rclone.org/t/jottacloud-crypt-3-gb-copy-runs-for-a-week-without-completing/21173 --- backend/jottacloud/jottacloud.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/backend/jottacloud/jottacloud.go b/backend/jottacloud/jottacloud.go index 8aa1da551..0656d9d07 100644 --- a/backend/jottacloud/jottacloud.go +++ b/backend/jottacloud/jottacloud.go @@ -730,6 +730,9 @@ func NewFs(name, root string, m configmap.Mapper) (fs.Fs, error) { // Renew the token in the background f.tokenRenewer = oauthutil.NewRenew(f.String(), ts, func() error { _, err := f.readMetaDataForPath(ctx, "") + if err == fs.ErrorNotAFile { + err = nil + } return err })