"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files
Go azure-blobazure-blob-storageazure-filesbackblaze-b2cloud-storagedropboxencryptionftpfuse-filesystemgogolanggoogle-cloud-storagegoogle-driveonedriveopenstack-swiftrclones3sftpsyncwebdav
bisync: fix endless retry loop for skipped files - fixes #9939
nielashe6a2ddb2f888
diff --git a/cmd/bisync/checkfn.go b/cmd/bisync/checkfn.goindex a2d773666..162c0f3ed 100644--- a/cmd/bisync/checkfn.go+++ b/cmd/bisync/checkfn.go@@ -5,6 +5,7 @@ import ("context""fmt""strings"+ "sync""github.com/rclone/rclone/backend/crypt""github.com/rclone/rclone/cmd/bisync/bilib"@@ -134,20 +135,37 @@ func DownloadCheckFn(ctx context.Context, dst, src fs.Object) (equal bool, noHas}// check potential conflicts (to avoid renaming if already identical)-func (b *bisyncRun) checkconflicts(ctxCheck context.Context, filterCheck *filter.Filter, fs1, fs2 fs.Fs) (bilib.Names, error) {- matches := bilib.Names{}+func (b *bisyncRun) checkconflicts(ctxCheck context.Context, filterCheck *filter.Filter, fs1, fs2 fs.Fs) (matches bilib.Names, matches1, matches2 *fileList, err error) {+ matches = bilib.Names{}+ matches1, matches2 = newFileList(), newFileList()if filterCheck.HaveFilesFrom() {fs.Debugf(nil, "There are potential conflicts to check.")if b.opt.TestFnConflictCheck != nil {b.opt.TestFnConflictCheck()}+ // the sizes already match, and they are all a check could compare here+ ci := fs.GetConfig(ctxCheck)+ if ci.SizeOnly || (ci.IgnoreChecksum && fs1.Hashes().Overlap(fs2.Hashes()).Count() == 0) {+ fs.Infof(nil, "Not checking potential conflicts, as only their sizes could be compared, and those already match.")+ for file := range filterCheck.Files() {+ matches.Add(file)+ if b.march.ls1.has(file) {+ b.march.ls1.getPut(file, matches1)+ }+ if b.march.ls2.has(file) {+ b.march.ls2.getPut(file, matches2)+ }+ }+ return matches, matches1, matches2, nil+ }+opt, close, checkopterr := check.GetCheckOpt(fs1, fs2)if checkopterr != nil {b.critical = trueb.retryable = truefs.Debugf(nil, "GetCheckOpt error: %v", checkopterr)- return matches, checkopterr+ return matches, matches1, matches2, checkopterr}defer close()@@ -155,6 +173,22 @@ func (b *bisyncRun) checkconflicts(ctxCheck context.Context, filterCheck *filteropt = b.WhichCheck(ctxCheck, opt)+ // record the objects found identical, so they can be compared with the listing snapshot+ var mu sync.Mutex+ checkFn := opt.Check+ opt.Check = func(ctx context.Context, dst, src fs.Object) (differ bool, noHash bool, err error) {+ differ, noHash, err = checkFn(ctx, dst, src)+ if err == nil && !differ {+ f1 := b.comparedFields(ctx, src, b.march.ls1.hash)+ f2 := b.comparedFields(ctx, dst, b.march.ls2.hash)+ mu.Lock()+ matches1.put(src.Remote(), f1.size, f1.time, f1.hash, "", "-")+ matches2.put(dst.Remote(), f2.size, f2.time, f2.hash, "", "-")+ mu.Unlock()+ }+ return differ, noHash, err+ }+fs.Infof(nil, "Checking potential conflicts...")check := operations.CheckFn(ctxCheck, opt)fs.Infof(nil, "Finished checking the potential conflicts. %s", check)@@ -171,9 +205,22 @@ func (b *bisyncRun) checkconflicts(ctxCheck context.Context, filterCheck *filter} else {fs.Debugf(nil, "None of the conflicts were determined to be identical.")}+ }+ return matches, matches1, matches2, nil+}+// comparedFields returns the fields of o that bisync compares, the same way+// the listing records them.+func (b *bisyncRun) comparedFields(ctx context.Context, o fs.Object, hashType hash.Type) (fi fileInfo) {+ fi.size = o.Size()+ if b.opt.Compare.Modtime {+ fi.time = o.ModTime(ctx).In(TZ)+ }+ if b.opt.Compare.Checksum && hashType != hash.None {+ fi.hash, _ = o.Hash(ctx, hashType)+ fi.hash, _ = b.tryDownloadHash(ctx, o, fi.hash)}- return matches, nil+ return fi}// WhichEqual is similar to WhichCheck, but checks a single object.diff --git a/cmd/bisync/deltas.go b/cmd/bisync/deltas.goindex aecdacb16..dadde841f 100644--- a/cmd/bisync/deltas.go+++ b/cmd/bisync/deltas.go@@ -290,8 +290,8 @@ func (b *bisyncRun) applyDeltas(ctx context.Context, ds1, ds2 *deltaSet) (resulthandled := bilib.Names{}renameSkipped := bilib.Names{}deletedonboth := bilib.Names{}- skippedDirs1 := newFileList()- skippedDirs2 := newFileList()+ skipped1 := newFileList()+ skipped2 := newFileList()b.renames = renames{}ctxMove := b.opt.setDryRun(ctx)@@ -361,7 +361,7 @@ func (b *bisyncRun) applyDeltas(ctx context.Context, ds1, ds2 *deltaSet) (result}// if there are potential conflicts to check, check them all here (outside the loop) in one fell swoop- matches, err := b.checkconflicts(ctxCheck, filterCheck, b.fs1, b.fs2)+ matches, matches1, matches2, err := b.checkconflicts(ctxCheck, filterCheck, b.fs1, b.fs2)for _, file := range ds1.sort() {alias := b.aliases.Alias(file)@@ -388,8 +388,8 @@ func (b *bisyncRun) applyDeltas(ctx context.Context, ds1, ds2 *deltaSet) (result// if files are identical, leave them alone instead of renamingif (dirs1.has(file) || dirs1.has(alias)) && (dirs2.has(file) || dirs2.has(alias)) {fs.Infof(nil, "This is a directory, not a file. Skipping equality check and will not rename: %s", file)- b.march.ls1.getPut(file, skippedDirs1)- b.march.ls2.getPut(file, skippedDirs2)+ b.march.ls1.getPut(file, skipped1)+ b.march.ls2.getPut(file, skipped2)b.debugFn(file, func() {b.debug(file, fmt.Sprintf("deltas dir: %s, ls1 has name?: %v, ls2 has name?: %v", file, b.march.ls1.has(b.DebugName), b.march.ls2.has(b.DebugName)))})@@ -415,10 +415,14 @@ func (b *bisyncRun) applyDeltas(ctx context.Context, ds1, ds2 *deltaSet) (resultb.indent("Path1", p2, "Queue copy to Path2")copy1to2.Add(b.march.ls1.getTryAlias(file, alias))}- } else {+ } else if b.sameCompared(b.march.ls1, matches1, b.march.ls1.getTryAlias(file, alias), b.fs1) &&+ b.sameCompared(b.march.ls2, matches2, b.march.ls2.getTryAlias(file, alias), b.fs2) {fs.Infof(nil, "Files are equal! Skipping: %s", file)- renameSkipped.Add(file)- renameSkipped.Add(alias)+ b.march.ls1.getPut(b.march.ls1.getTryAlias(file, alias), skipped1)+ b.march.ls2.getPut(b.march.ls2.getTryAlias(file, alias), skipped2)+ } else {+ // the snapshot isn't the state we found equal, so leave the prior listing for the next run+ fs.Infof(nil, "Files are equal but changed after the listing was made, so will check again next run: %s", file)}} else {fs.Debugf(nil, "Files are NOT equal: %s", file)@@ -530,8 +534,8 @@ func (b *bisyncRun) applyDeltas(ctx context.Context, ds1, ds2 *deltaSet) (resultqueues.copy2to1 = copy2to1queues.renameSkipped = renameSkippedqueues.deletedonboth = deletedonboth- queues.skippedDirs1 = skippedDirs1- queues.skippedDirs2 = skippedDirs2+ queues.skipped1 = skipped1+ queues.skipped2 = skipped2return}@@ -632,3 +636,12 @@ func (b *bisyncRun) updateAliases(ctx context.Context, ds1, ds2 *deltaSet) {addAliases(delMap1, fullMap2)addAliases(delMap2, fullMap1)}++// sameCompared reports whether file has the same values in the listing+// snapshot and in the checked list, in every field bisync compares.+func (b *bisyncRun) sameCompared(snapshot, checked *fileList, file string, f fs.Info) bool {+ if !checked.has(file) {+ return false+ }+ return len(b.fileInfoDiffs(file, file, snapshot, checked, f, f, snapshot.hash, snapshot.hash)) == 0+}diff --git a/cmd/bisync/listing.go b/cmd/bisync/listing.goindex c57928557..f5fc54efb 100644--- a/cmd/bisync/listing.go+++ b/cmd/bisync/listing.go@@ -186,29 +186,35 @@ func (ls *fileList) getHash(file string) string {}func (b *bisyncRun) fileInfoEqual(file1, file2 string, ls1, ls2 *fileList) bool {- equal := trueif ls1.isDir(file1) && ls2.isDir(file2) {- return equal+ return true+ }+ diffs := b.fileInfoDiffs(file1, file2, ls1, ls2, b.fs1, b.fs2, b.opt.Compare.HashType1, b.opt.Compare.HashType2)+ for _, diff := range diffs {+ b.indent("ERROR", file1, diff)}+ return len(diffs) == 0+}++// fileInfoDiffs describes each field bisync compares where file1 in ls1+// (on f1, with hash type ht1) differs from file2 in ls2 (on f2, with ht2).+func (b *bisyncRun) fileInfoDiffs(file1, file2 string, ls1, ls2 *fileList, f1, f2 fs.Info, ht1, ht2 hash.Type) (diffs []string) {if b.opt.Compare.Size {if sizeDiffers(ls1.getSize(file1), ls2.getSize(file2)) {- b.indent("ERROR", file1, fmt.Sprintf("Size not equal in listing. Path1: %v, Path2: %v", ls1.getSize(file1), ls2.getSize(file2)))- equal = false+ diffs = append(diffs, fmt.Sprintf("Size not equal in listing. Path1: %v, Path2: %v", ls1.getSize(file1), ls2.getSize(file2)))}}if b.opt.Compare.Modtime {- if timeDiffers(b.fctx, ls1.getTime(file1), ls2.getTime(file2), b.fs1, b.fs2) {- b.indent("ERROR", file1, fmt.Sprintf("Modtime not equal in listing. Path1: %v, Path2: %v", ls1.getTime(file1), ls2.getTime(file2)))- equal = false+ if timeDiffers(b.fctx, ls1.getTime(file1), ls2.getTime(file2), f1, f2) {+ diffs = append(diffs, fmt.Sprintf("Modtime not equal in listing. Path1: %v, Path2: %v", ls1.getTime(file1), ls2.getTime(file2)))}}if b.opt.Compare.Checksum && !b.queueOpt.ignoreListingChecksum {- if b.hashDiffers(ls1.getHash(file1), ls2.getHash(file2), b.opt.Compare.HashType1, b.opt.Compare.HashType2, ls1.getSize(file1), ls2.getSize(file2)) {- b.indent("ERROR", file1, fmt.Sprintf("Checksum not equal in listing. Path1: %v, Path2: %v", ls1.getHash(file1), ls2.getHash(file2)))- equal = false+ if b.hashDiffers(ls1.getHash(file1), ls2.getHash(file2), ht1, ht2, ls1.getSize(file1), ls2.getSize(file2)) {+ diffs = append(diffs, fmt.Sprintf("Checksum not equal in listing. Path1: %v, Path2: %v", ls1.getHash(file1), ls2.getHash(file2)))}}- return equal+ return diffs}// also returns false if not found@@ -627,9 +633,7 @@ func (b *bisyncRun) modifyListing(ctx context.Context, src fs.Fs, dst fs.Fs, res}}- // recheck the ones we skipped because they were equal- // we never got their info because they were never synced.- // TODO: add flag to skip this? (since it re-lists)+ // recheck the ones we didn't rename due to --dry-runif queues.renameSkipped.NotEmpty() {skippedList := queues.renameSkipped.ToList()for _, file := range skippedList {@@ -638,7 +642,7 @@ func (b *bisyncRun) modifyListing(ctx context.Context, src fs.Fs, dst fs.Fs, res}}}- // skipped dirs -- nothing to recheck, just add them+ // skipped dirs and equal files -- nothing to recheck, just add them from the snapshot// (they are not necessarily there already, if they are new)path1List := srcListpath2List := dstList@@ -646,11 +650,11 @@ func (b *bisyncRun) modifyListing(ctx context.Context, src fs.Fs, dst fs.Fs, respath1List = dstListpath2List = srcList}- if !queues.skippedDirs1.empty() {- queues.skippedDirs1.getPutAll(path1List)+ if !queues.skipped1.empty() {+ queues.skipped1.getPutAll(path1List)}- if !queues.skippedDirs2.empty() {- queues.skippedDirs2.getPutAll(path2List)+ if !queues.skipped2.empty() {+ queues.skipped2.getPutAll(path2List)}if filterRecheck.HaveFilesFrom() {diff --git a/cmd/bisync/operations.go b/cmd/bisync/operations.goindex 2c8b1d173..05df06e1b 100644--- a/cmd/bisync/operations.go+++ b/cmd/bisync/operations.go@@ -63,9 +63,9 @@ type bisyncRun struct {type queues struct {copy1to2 bilib.Namescopy2to1 bilib.Names- renameSkipped bilib.Names // not renamed because it was equal- skippedDirs1 *fileList- skippedDirs2 *fileList+ renameSkipped bilib.Names // not renamed due to --dry-run+ skipped1 *fileList // dirs and equal files not renamed, from the Path1 snapshot+ skipped2 *fileList // dirs and equal files not renamed, from the Path2 snapshotdeletedonboth bilib.Names}diff --git a/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.copy2to1.que b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.copy2to1.quenew file mode 100644index 000000000..029f3e190--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.copy2to1.que@@ -0,0 +1 @@+"file1.txt"diff --git a/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path1.lst b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path1.lstnew file mode 100644index 000000000..080041dd4--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path1.lst@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 10 - - 2001-03-04T00:00:00.000000000+0000 "file1.txt"+- 22 - - 2002-05-06T00:00:00.000000000+0000 "file2.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path1.lst-new b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path1.lst-newnew file mode 100644index 000000000..080041dd4--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path1.lst-new@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 10 - - 2001-03-04T00:00:00.000000000+0000 "file1.txt"+- 22 - - 2002-05-06T00:00:00.000000000+0000 "file2.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path1.lst-old b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path1.lst-oldnew file mode 100644index 000000000..6e7bfe106--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path1.lst-old@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 10 - - 2001-03-04T00:00:00.000000000+0000 "file1.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file2.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path2.lst b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path2.lstnew file mode 100644index 000000000..080041dd4--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path2.lst@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 10 - - 2001-03-04T00:00:00.000000000+0000 "file1.txt"+- 22 - - 2002-05-06T00:00:00.000000000+0000 "file2.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path2.lst-new b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path2.lst-newnew file mode 100644index 000000000..080041dd4--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path2.lst-new@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 10 - - 2001-03-04T00:00:00.000000000+0000 "file1.txt"+- 22 - - 2002-05-06T00:00:00.000000000+0000 "file2.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path2.lst-old b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path2.lst-oldnew file mode 100644index 000000000..6e7bfe106--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/golden/_testdir_path1.._testdir_path2.path2.lst-old@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 10 - - 2001-03-04T00:00:00.000000000+0000 "file1.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file2.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window/golden/test.log b/cmd/bisync/testdata/test_conflict_window/golden/test.lognew file mode 100644index 000000000..89bb38812--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/golden/test.log@@ -0,0 +1,237 @@+[36m(01) :[0m [34mtest conflict window[0m+++[36m(02) :[0m [34mtest initial bisync[0m+[36m(03) :[0m [34mbisync resync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Copying Path2 files to Path1+INFO : - [34mPath2[0m [35mResync is copying files to[0m - [36mPath1[0m+INFO : There was nothing to transfer+INFO : - [36mPath1[0m [35mResync is copying files to[0m - [36mPath2[0m+INFO : There was nothing to transfer+INFO : Resync updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(04) :[0m [34mtest new on both paths, same size and modtime, different content - file1 (file1A, file1B)[0m+[36m(05) :[0m [34mtouch-glob 2001-01-02 {datadir/} file1*.txt[0m+[36m(06) :[0m [34mcopy-as {datadir/}file1A.txt {path1/} file1.txt[0m+[36m(07) :[0m [34mcopy-as {datadir/}file1B.txt {path2/} file1.txt[0m++[36m(08) :[0m [34mtest bisync with Path2 becoming identical to Path1 before the check, with a newer modtime[0m+[36m(09) :[0m [34mtouch-glob 2001-03-04 {datadir/} file1A.txt[0m+[36m(10) :[0m [34mhook before-check copy-as {datadir/}file1A.txt {path2/} file1.txt[0m+[36m(11) :[0m [34mbisync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile1.txt[0m+INFO : Path1: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile1.txt[0m+INFO : Path2: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Applying changes+NOTICE: [36mhook before-check:[0m [34mcopy-as {datadir/}file1A.txt {path2/} file1.txt[0m+INFO : Checking potential conflicts...+NOTICE: {path2String}: 0 differences found+NOTICE: {path2String}: 1 matching files+INFO : Finished checking the potential conflicts. %!s(<nil>)+NOTICE: - [34mWARNING[0m [35mNew or changed in both paths[0m - [36mfile1.txt[0m+INFO : Files are equal but changed after the listing was made, so will check again next run: file1.txt+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(12) :[0m [34mtest bisync after file1 changed before the check[0m+[36m(13) :[0m [34mbisync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile1.txt[0m+INFO : Path1: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile1.txt[0m+INFO : Path2: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Applying changes+INFO : Checking potential conflicts...+NOTICE: {path2String}: 0 differences found+NOTICE: {path2String}: 1 matching files+INFO : Finished checking the potential conflicts. %!s(<nil>)+NOTICE: - [34mWARNING[0m [35mNew or changed in both paths[0m - [36mfile1.txt[0m+INFO : file1.txt: Files are equal but will copy anyway to update modtime (will not rename)+INFO : - [34mPath2[0m [35m[32mQueue copy to[0m Path1[0m - [36m{path1/}file1.txt[0m+INFO : - [34mPath2[0m [35mDo queued copies to[0m - [36mPath1[0m+INFO : There was nothing to transfer+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(14) :[0m [34mtest recover with --resync if the previous runs failed[0m+[36m(15) :[0m [34mbisync resync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Copying Path2 files to Path1+INFO : - [34mPath2[0m [35mResync is copying files to[0m - [36mPath1[0m+INFO : There was nothing to transfer+INFO : - [36mPath1[0m [35mResync is copying files to[0m - [36mPath2[0m+INFO : There was nothing to transfer+INFO : Resync updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(16) :[0m [34mtest new on both paths and identical - file2 (file2A)[0m+[36m(17) :[0m [34mtouch-glob 2002-01-02 {datadir/} file2A.txt[0m+[36m(18) :[0m [34mcopy-as {datadir/}file2A.txt {path1/} file2.txt[0m+[36m(19) :[0m [34mcopy-as {datadir/}file2A.txt {path2/} file2.txt[0m++[36m(20) :[0m [34mtest bisync with both paths changing file2 identically before the check[0m+[36m(21) :[0m [34mtouch-glob 2002-03-04 {datadir/} file2B.txt[0m+[36m(22) :[0m [34mhook before-check copy-as {datadir/}file2B.txt {path1/} file2.txt[0m+[36m(23) :[0m [34mhook before-check copy-as {datadir/}file2B.txt {path2/} file2.txt[0m+[36m(24) :[0m [34mbisync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile2.txt[0m+INFO : Path1: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile2.txt[0m+INFO : Path2: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Applying changes+NOTICE: [36mhook before-check:[0m [34mcopy-as {datadir/}file2B.txt {path1/} file2.txt[0m+NOTICE: [36mhook before-check:[0m [34mcopy-as {datadir/}file2B.txt {path2/} file2.txt[0m+INFO : Checking potential conflicts...+NOTICE: {path2String}: 0 differences found+NOTICE: {path2String}: 1 matching files+INFO : Finished checking the potential conflicts. %!s(<nil>)+NOTICE: - [34mWARNING[0m [35mNew or changed in both paths[0m - [36mfile2.txt[0m+INFO : Files are equal but changed after the listing was made, so will check again next run: file2.txt+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(25) :[0m [34mtest bisync with both paths changing file2 identically before the check again[0m+[36m(26) :[0m [34mtouch-glob 2002-05-06 {datadir/} file2C.txt[0m+[36m(27) :[0m [34mhook before-check copy-as {datadir/}file2C.txt {path1/} file2.txt[0m+[36m(28) :[0m [34mhook before-check copy-as {datadir/}file2C.txt {path2/} file2.txt[0m+[36m(29) :[0m [34mbisync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile2.txt[0m+INFO : Path1: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile2.txt[0m+INFO : Path2: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Applying changes+NOTICE: [36mhook before-check:[0m [34mcopy-as {datadir/}file2C.txt {path1/} file2.txt[0m+NOTICE: [36mhook before-check:[0m [34mcopy-as {datadir/}file2C.txt {path2/} file2.txt[0m+INFO : Checking potential conflicts...+NOTICE: {path2String}: 0 differences found+NOTICE: {path2String}: 1 matching files+INFO : Finished checking the potential conflicts. %!s(<nil>)+NOTICE: - [34mWARNING[0m [35mNew or changed in both paths[0m - [36mfile2.txt[0m+INFO : Files are equal but changed after the listing was made, so will check again next run: file2.txt+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(30) :[0m [34mtest bisync after file2 stops changing[0m+[36m(31) :[0m [34mbisync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile2.txt[0m+INFO : Path1: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile2.txt[0m+INFO : Path2: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Applying changes+INFO : Checking potential conflicts...+NOTICE: {path2String}: 0 differences found+NOTICE: {path2String}: 1 matching files+INFO : Finished checking the potential conflicts. %!s(<nil>)+NOTICE: - [34mWARNING[0m [35mNew or changed in both paths[0m - [36mfile2.txt[0m+INFO : Files are equal! Skipping: file2.txt+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0mdiff --git a/cmd/bisync/testdata/test_conflict_window/initial/RCLONE_TEST b/cmd/bisync/testdata/test_conflict_window/initial/RCLONE_TESTnew file mode 100644index 000000000..d8ca97c2a--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/initial/RCLONE_TEST@@ -0,0 +1 @@+This file is used for testing the health of rclone accesses to the local/remote file system. Do not delete.diff --git a/cmd/bisync/testdata/test_conflict_window/initial/file1.txt b/cmd/bisync/testdata/test_conflict_window/initial/file1.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window/initial/file2.txt b/cmd/bisync/testdata/test_conflict_window/initial/file2.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window/initial/file3.txt b/cmd/bisync/testdata/test_conflict_window/initial/file3.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window/initial/file4.txt b/cmd/bisync/testdata/test_conflict_window/initial/file4.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window/initial/file5.txt b/cmd/bisync/testdata/test_conflict_window/initial/file5.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window/initial/file6.txt b/cmd/bisync/testdata/test_conflict_window/initial/file6.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window/initial/file7.txt b/cmd/bisync/testdata/test_conflict_window/initial/file7.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window/initial/file8.txt b/cmd/bisync/testdata/test_conflict_window/initial/file8.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window/modfiles/file1A.txt b/cmd/bisync/testdata/test_conflict_window/modfiles/file1A.txtnew file mode 100644index 000000000..72a707eba--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/modfiles/file1A.txt@@ -0,0 +1 @@+Version Adiff --git a/cmd/bisync/testdata/test_conflict_window/modfiles/file1B.txt b/cmd/bisync/testdata/test_conflict_window/modfiles/file1B.txtnew file mode 100644index 000000000..9084e7c47--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/modfiles/file1B.txt@@ -0,0 +1 @@+Version Bdiff --git a/cmd/bisync/testdata/test_conflict_window/modfiles/file2A.txt b/cmd/bisync/testdata/test_conflict_window/modfiles/file2A.txtnew file mode 100644index 000000000..9da053fde--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/modfiles/file2A.txt@@ -0,0 +1 @@+First versiondiff --git a/cmd/bisync/testdata/test_conflict_window/modfiles/file2B.txt b/cmd/bisync/testdata/test_conflict_window/modfiles/file2B.txtnew file mode 100644index 000000000..b5bb6653e--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/modfiles/file2B.txt@@ -0,0 +1 @@+Second versiondiff --git a/cmd/bisync/testdata/test_conflict_window/modfiles/file2C.txt b/cmd/bisync/testdata/test_conflict_window/modfiles/file2C.txtnew file mode 100644index 000000000..1f034c581--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/modfiles/file2C.txt@@ -0,0 +1 @@+Third version, longerdiff --git a/cmd/bisync/testdata/test_conflict_window/scenario.txt b/cmd/bisync/testdata/test_conflict_window/scenario.txtnew file mode 100644index 000000000..da7efbd33--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window/scenario.txt@@ -0,0 +1,43 @@+test conflict window+# Check identical files when the paths change between the listing snapshot and the check for identical files+# - Path2 becomes identical to Path1 before the check, with a newer modtime file1 (file1A, file1B)+# - Both paths change identically before the check on two runs in a row, then stop file2 (file2A, file2B, file2C)++test initial bisync+bisync resync++test new on both paths, same size and modtime, different content - file1 (file1A, file1B)+touch-glob 2001-01-02 {datadir/} file1*.txt+copy-as {datadir/}file1A.txt {path1/} file1.txt+copy-as {datadir/}file1B.txt {path2/} file1.txt++test bisync with Path2 becoming identical to Path1 before the check, with a newer modtime+touch-glob 2001-03-04 {datadir/} file1A.txt+hook before-check copy-as {datadir/}file1A.txt {path2/} file1.txt+bisync++test bisync after file1 changed before the check+bisync++test recover with --resync if the previous runs failed+bisync resync++test new on both paths and identical - file2 (file2A)+touch-glob 2002-01-02 {datadir/} file2A.txt+copy-as {datadir/}file2A.txt {path1/} file2.txt+copy-as {datadir/}file2A.txt {path2/} file2.txt++test bisync with both paths changing file2 identically before the check+touch-glob 2002-03-04 {datadir/} file2B.txt+hook before-check copy-as {datadir/}file2B.txt {path1/} file2.txt+hook before-check copy-as {datadir/}file2B.txt {path2/} file2.txt+bisync++test bisync with both paths changing file2 identically before the check again+touch-glob 2002-05-06 {datadir/} file2C.txt+hook before-check copy-as {datadir/}file2C.txt {path1/} file2.txt+hook before-check copy-as {datadir/}file2C.txt {path2/} file2.txt+bisync++test bisync after file2 stops changing+bisyncdiff --git a/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.copy1to2.que b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.copy1to2.quenew file mode 100644index 000000000..9ed593ba3--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.copy1to2.que@@ -0,0 +1 @@+"file2.txt"diff --git a/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.copy2to1.que b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.copy2to1.quenew file mode 100644index 000000000..029f3e190--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.copy2to1.que@@ -0,0 +1 @@+"file1.txt"diff --git a/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path1.lst b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path1.lstnew file mode 100644index 000000000..bb8f18d7a--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path1.lst@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 7 - - 0001-01-01T00:00:00.000000000+0000 "file1.txt"+- 10 - - 0001-01-01T00:00:00.000000000+0000 "file2.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path1.lst-new b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path1.lst-newnew file mode 100644index 000000000..0e54f093c--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path1.lst-new@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 0001-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 6 - - 0001-01-01T00:00:00.000000000+0000 "file1.txt"+- 10 - - 0001-01-01T00:00:00.000000000+0000 "file2.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path1.lst-old b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path1.lst-oldnew file mode 100644index 000000000..93287a281--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path1.lst-old@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 6 - - 0001-01-01T00:00:00.000000000+0000 "file1.txt"+- 6 - - 0001-01-01T00:00:00.000000000+0000 "file2.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path2.lst b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path2.lstnew file mode 100644index 000000000..bb8f18d7a--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path2.lst@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 7 - - 0001-01-01T00:00:00.000000000+0000 "file1.txt"+- 10 - - 0001-01-01T00:00:00.000000000+0000 "file2.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path2.lst-new b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path2.lst-newnew file mode 100644index 000000000..d165f9935--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path2.lst-new@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 0001-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 7 - - 0001-01-01T00:00:00.000000000+0000 "file1.txt"+- 6 - - 0001-01-01T00:00:00.000000000+0000 "file2.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path2.lst-old b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path2.lst-oldnew file mode 100644index 000000000..93287a281--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/golden/_testdir_path1.._testdir_path2.path2.lst-old@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 6 - - 0001-01-01T00:00:00.000000000+0000 "file1.txt"+- 6 - - 0001-01-01T00:00:00.000000000+0000 "file2.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file3.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_conflict_window_size/golden/test.log b/cmd/bisync/testdata/test_conflict_window_size/golden/test.lognew file mode 100644index 000000000..2f89c3da7--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/golden/test.log@@ -0,0 +1,108 @@+[36m(01) :[0m [34mtest conflict window size[0m+++[36m(02) :[0m [34mtest initial bisync[0m+[36m(03) :[0m [34mbisync resync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Copying Path2 files to Path1+INFO : - [34mPath2[0m [35mResync is copying files to[0m - [36mPath1[0m+INFO : There was nothing to transfer+INFO : - [36mPath1[0m [35mResync is copying files to[0m - [36mPath2[0m+INFO : There was nothing to transfer+INFO : Resync updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(04) :[0m [34mtest new on both paths, same size, different content - file1 and file2 (fileA, fileB)[0m+[36m(05) :[0m [34mcopy-as {datadir/}fileA.txt {path1/} file1.txt[0m+[36m(06) :[0m [34mcopy-as {datadir/}fileB.txt {path2/} file1.txt[0m+[36m(07) :[0m [34mcopy-as {datadir/}fileA.txt {path1/} file2.txt[0m+[36m(08) :[0m [34mcopy-as {datadir/}fileB.txt {path2/} file2.txt[0m++[36m(09) :[0m [34mtest bisync with both paths changing file1 and file2 to fileC before the check[0m+[36m(10) :[0m [34mhook before-check copy-as {datadir/}fileC.txt {path1/} file1.txt[0m+[36m(11) :[0m [34mhook before-check copy-as {datadir/}fileC.txt {path2/} file1.txt[0m+[36m(12) :[0m [34mhook before-check copy-as {datadir/}fileC.txt {path1/} file2.txt[0m+[36m(13) :[0m [34mhook before-check copy-as {datadir/}fileC.txt {path2/} file2.txt[0m+[36m(14) :[0m [34mbisync size-only[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": false,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m[0m[0m - [36mfile1.txt[0m+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m[0m[0m - [36mfile2.txt[0m+INFO : Path1: 2 changes: [32m 0 new[0m, [33m 2 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 2 larger[0m, [34m 0 smaller[0m)+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m[0m[0m - [36mfile1.txt[0m+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m[0m[0m - [36mfile2.txt[0m+INFO : Path2: 2 changes: [32m 0 new[0m, [33m 2 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 2 larger[0m, [34m 0 smaller[0m)+INFO : Applying changes+NOTICE: [36mhook before-check:[0m [34mcopy-as {datadir/}fileC.txt {path1/} file1.txt[0m+NOTICE: [36mhook before-check:[0m [34mcopy-as {datadir/}fileC.txt {path2/} file1.txt[0m+NOTICE: [36mhook before-check:[0m [34mcopy-as {datadir/}fileC.txt {path1/} file2.txt[0m+NOTICE: [36mhook before-check:[0m [34mcopy-as {datadir/}fileC.txt {path2/} file2.txt[0m+INFO : Not checking potential conflicts, as only their sizes could be compared, and those already match.+NOTICE: - [34mWARNING[0m [35mNew or changed in both paths[0m - [36mfile1.txt[0m+INFO : Files are equal! Skipping: file1.txt+NOTICE: - [34mWARNING[0m [35mNew or changed in both paths[0m - [36mfile2.txt[0m+INFO : Files are equal! Skipping: file2.txt+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(15) :[0m [34mtest file1 changes to size 6 on Path1 and size 7 on Path2, and file2 changes to size 6 on Path2 (fileD, fileE)[0m+[36m(16) :[0m [34mcopy-as {datadir/}fileD.txt {path1/} file1.txt[0m+[36m(17) :[0m [34mcopy-as {datadir/}fileE.txt {path2/} file1.txt[0m+[36m(18) :[0m [34mcopy-as {datadir/}fileD.txt {path2/} file2.txt[0m++[36m(19) :[0m [34mtest bisync after the changes[0m+[36m(20) :[0m [34mbisync size-only[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": false,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m[0m[0m - [36mfile2.txt[0m+INFO : Path1: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m[0m[0m - [36mfile1.txt[0m+INFO : Path2: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Applying changes+INFO : - [36mPath1[0m [35m[32mQueue copy to[0m Path2[0m - [36m{path2/}file2.txt[0m+INFO : - [34mPath2[0m [35m[32mQueue copy to[0m Path1[0m - [36m{path1/}file1.txt[0m+INFO : - [34mPath2[0m [35mDo queued copies to[0m - [36mPath1[0m+INFO : - [36mPath1[0m [35mDo queued copies to[0m - [36mPath2[0m+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0mdiff --git a/cmd/bisync/testdata/test_conflict_window_size/initial/RCLONE_TEST b/cmd/bisync/testdata/test_conflict_window_size/initial/RCLONE_TESTnew file mode 100644index 000000000..d8ca97c2a--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/initial/RCLONE_TEST@@ -0,0 +1 @@+This file is used for testing the health of rclone accesses to the local/remote file system. Do not delete.diff --git a/cmd/bisync/testdata/test_conflict_window_size/initial/file1.txt b/cmd/bisync/testdata/test_conflict_window_size/initial/file1.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window_size/initial/file2.txt b/cmd/bisync/testdata/test_conflict_window_size/initial/file2.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window_size/initial/file3.txt b/cmd/bisync/testdata/test_conflict_window_size/initial/file3.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window_size/initial/file4.txt b/cmd/bisync/testdata/test_conflict_window_size/initial/file4.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window_size/initial/file5.txt b/cmd/bisync/testdata/test_conflict_window_size/initial/file5.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window_size/initial/file6.txt b/cmd/bisync/testdata/test_conflict_window_size/initial/file6.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window_size/initial/file7.txt b/cmd/bisync/testdata/test_conflict_window_size/initial/file7.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window_size/initial/file8.txt b/cmd/bisync/testdata/test_conflict_window_size/initial/file8.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileA.txt b/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileA.txtnew file mode 100644index 000000000..c46ec7965--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileA.txt@@ -0,0 +1 @@+AAAAAdiff --git a/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileB.txt b/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileB.txtnew file mode 100644index 000000000..01a1e3b7d--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileB.txt@@ -0,0 +1 @@+BBBBBdiff --git a/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileC.txt b/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileC.txtnew file mode 100644index 000000000..fe089dbd3--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileC.txt@@ -0,0 +1 @@+CCCCCCCCCdiff --git a/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileD.txt b/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileD.txtnew file mode 100644index 000000000..cece0a580--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileD.txt@@ -0,0 +1 @@+DDDDDdiff --git a/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileE.txt b/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileE.txtnew file mode 100644index 000000000..36c81e538--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/modfiles/fileE.txt@@ -0,0 +1 @@+EEEEEEdiff --git a/cmd/bisync/testdata/test_conflict_window_size/scenario.txt b/cmd/bisync/testdata/test_conflict_window_size/scenario.txtnew file mode 100644index 000000000..d5797e06a--- /dev/null+++ b/cmd/bisync/testdata/test_conflict_window_size/scenario.txt@@ -0,0 +1,30 @@+test conflict window size+# Check identical files with --size-only when both paths change between the listing snapshot and the+# check for identical files, and then change again before the next run+# - New on both paths (size 6, different content), both change to fileC (size 10) before the check,+# then Path1 changes back to size 6 and Path2 to size 7 file1 (fileA-E)+# - Same, then only Path2 changes back to size 6 file2 (fileA-D)++test initial bisync+bisync resync++test new on both paths, same size, different content - file1 and file2 (fileA, fileB)+copy-as {datadir/}fileA.txt {path1/} file1.txt+copy-as {datadir/}fileB.txt {path2/} file1.txt+copy-as {datadir/}fileA.txt {path1/} file2.txt+copy-as {datadir/}fileB.txt {path2/} file2.txt++test bisync with both paths changing file1 and file2 to fileC before the check+hook before-check copy-as {datadir/}fileC.txt {path1/} file1.txt+hook before-check copy-as {datadir/}fileC.txt {path2/} file1.txt+hook before-check copy-as {datadir/}fileC.txt {path1/} file2.txt+hook before-check copy-as {datadir/}fileC.txt {path2/} file2.txt+bisync size-only++test file1 changes to size 6 on Path1 and size 7 on Path2, and file2 changes to size 6 on Path2 (fileD, fileE)+copy-as {datadir/}fileD.txt {path1/} file1.txt+copy-as {datadir/}fileE.txt {path2/} file1.txt+copy-as {datadir/}fileD.txt {path2/} file2.txt++test bisync after the changes+bisync size-onlydiff --git a/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.copy1to2.que b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.copy1to2.quenew file mode 100644index 000000000..ce7f0ba5c--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.copy1to2.que@@ -0,0 +1 @@+"file10.txt"diff --git a/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.copy2to1.que b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.copy2to1.quenew file mode 100644index 000000000..029f3e190--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.copy2to1.que@@ -0,0 +1 @@+"file1.txt"diff --git a/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.delete2.que b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.delete2.quenew file mode 100644index 000000000..ce7f0ba5c--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.delete2.que@@ -0,0 +1 @@+"file10.txt"diff --git a/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path1.lst b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path1.lstnew file mode 100644index 000000000..99e1afa3b--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path1.lst@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 19 - - 2023-08-26T00:00:00.000000000+0000 "file1.txt"+- 13 - - 2001-01-02T00:00:00.000000000+0000 "file2.txt"+- 13 - - 2002-02-02T00:00:00.000000000+0000 "file3.txt"+- 13 - - 2001-01-02T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path1.lst-new b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path1.lst-newnew file mode 100644index 000000000..6717df151--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path1.lst-new@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 0001-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 19 - - 0001-01-01T00:00:00.000000000+0000 "file1.txt"+- 13 - - 0001-01-01T00:00:00.000000000+0000 "file2.txt"+- 13 - - 0001-01-01T00:00:00.000000000+0000 "file3.txt"+- 13 - - 0001-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path1.lst-old b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path1.lst-oldnew file mode 100644index 000000000..7e03bad99--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path1.lst-old@@ -0,0 +1,11 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 19 - - 2023-08-26T00:00:00.000000000+0000 "file1.txt"+- 14 - - 0001-01-01T00:00:00.000000000+0000 "file10.txt"+- 13 - - 2001-01-02T00:00:00.000000000+0000 "file2.txt"+- 13 - - 2002-02-02T00:00:00.000000000+0000 "file3.txt"+- 13 - - 2001-01-02T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path2.lst b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path2.lstnew file mode 100644index 000000000..99e1afa3b--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path2.lst@@ -0,0 +1,10 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 19 - - 2023-08-26T00:00:00.000000000+0000 "file1.txt"+- 13 - - 2001-01-02T00:00:00.000000000+0000 "file2.txt"+- 13 - - 2002-02-02T00:00:00.000000000+0000 "file3.txt"+- 13 - - 2001-01-02T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path2.lst-new b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path2.lst-newnew file mode 100644index 000000000..33eaa6d6d--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path2.lst-new@@ -0,0 +1,11 @@+# bisync listing v1 from test+- 109 - - 0001-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 19 - - 0001-01-01T00:00:00.000000000+0000 "file1.txt"+- 14 - - 0001-01-01T00:00:00.000000000+0000 "file10.txt"+- 13 - - 0001-01-01T00:00:00.000000000+0000 "file2.txt"+- 13 - - 0001-01-01T00:00:00.000000000+0000 "file3.txt"+- 13 - - 0001-01-01T00:00:00.000000000+0000 "file4.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 0001-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path2.lst-old b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path2.lst-oldnew file mode 100644index 000000000..7e03bad99--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/golden/_testdir_path1.._testdir_path2.path2.lst-old@@ -0,0 +1,11 @@+# bisync listing v1 from test+- 109 - - 2000-01-01T00:00:00.000000000+0000 "RCLONE_TEST"+- 19 - - 2023-08-26T00:00:00.000000000+0000 "file1.txt"+- 14 - - 0001-01-01T00:00:00.000000000+0000 "file10.txt"+- 13 - - 2001-01-02T00:00:00.000000000+0000 "file2.txt"+- 13 - - 2002-02-02T00:00:00.000000000+0000 "file3.txt"+- 13 - - 2001-01-02T00:00:00.000000000+0000 "file4.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file5.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file6.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file7.txt"+- 0 - - 2000-01-01T00:00:00.000000000+0000 "file8.txt"diff --git a/cmd/bisync/testdata/test_equal_skipped/golden/test.log b/cmd/bisync/testdata/test_equal_skipped/golden/test.lognew file mode 100644index 000000000..ab1af3fa5--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/golden/test.log@@ -0,0 +1,226 @@+[36m(01) :[0m [34mtest equal skipped[0m+++[36m(02) :[0m [34mtest initial bisync[0m+[36m(03) :[0m [34mbisync resync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Copying Path2 files to Path1+INFO : - [34mPath2[0m [35mResync is copying files to[0m - [36mPath1[0m+INFO : There was nothing to transfer+INFO : - [36mPath1[0m [35mResync is copying files to[0m - [36mPath2[0m+INFO : There was nothing to transfer+INFO : Resync updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(04) :[0m [34mtest changed on both paths and identical - file1[0m+[36m(05) :[0m [34mtouch-glob 2001-01-02 {datadir/} file1.txt[0m+[36m(06) :[0m [34mcopy-as {datadir/}file1.txt {path1/} file1.txt[0m+[36m(07) :[0m [34mcopy-as {datadir/}file1.txt {path2/} file1.txt[0m++[36m(08) :[0m [34mtest changed on Path1 - file2[0m+[36m(09) :[0m [34mtouch-glob 2001-01-02 {datadir/} file2.txt[0m+[36m(10) :[0m [34mcopy-as {datadir/}file2.txt {path1/} file2.txt[0m++[36m(11) :[0m [34mtest bisync with file1 changed on Path2 during the sync[0m+[36m(12) :[0m [34mtouch-glob 2023-08-26 {datadir/} file7.txt[0m+[36m(13) :[0m [34mhook during-sync copy-as {datadir/}file7.txt {path2/} file1.txt[0m+[36m(14) :[0m [34mbisync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile1.txt[0m+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile2.txt[0m+INFO : Path1: 2 changes: [32m 0 new[0m, [33m 2 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 2 newer[0m, [34m 0 older[0m, [36m 2 larger[0m, [34m 0 smaller[0m)+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile1.txt[0m+INFO : Path2: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Applying changes+INFO : Checking potential conflicts...+NOTICE: {path2String}: 0 differences found+NOTICE: {path2String}: 1 matching files+INFO : Finished checking the potential conflicts. %!s(<nil>)+NOTICE: - [34mWARNING[0m [35mNew or changed in both paths[0m - [36mfile1.txt[0m+INFO : Files are equal! Skipping: file1.txt+INFO : - [36mPath1[0m [35m[32mQueue copy to[0m Path2[0m - [36m{path2/}file2.txt[0m+INFO : - [36mPath1[0m [35mDo queued copies to[0m - [36mPath2[0m+NOTICE: [36mhook during-sync:[0m [34mcopy-as {datadir/}file7.txt {path2/} file1.txt[0m+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(15) :[0m [34mtest bisync after file1 changed on Path2 during the sync[0m+[36m(16) :[0m [34mbisync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile1.txt[0m+INFO : Path2: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Applying changes+INFO : - [34mPath2[0m [35m[32mQueue copy to[0m Path1[0m - [36m{path1/}file1.txt[0m+INFO : - [34mPath2[0m [35mDo queued copies to[0m - [36mPath1[0m+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(17) :[0m [34mtest changed on both paths and identical - file3[0m+[36m(18) :[0m [34mtouch-glob 2002-02-02 {datadir/} file3*.txt[0m+[36m(19) :[0m [34mcopy-as {datadir/}file3.txt {path1/} file3.txt[0m+[36m(20) :[0m [34mcopy-as {datadir/}file3.txt {path2/} file3.txt[0m++[36m(21) :[0m [34mtest changed on Path1 - file4[0m+[36m(22) :[0m [34mcopy-as {datadir/}file2.txt {path1/} file4.txt[0m++[36m(23) :[0m [34mtest bisync with file3 changed on Path2 during the sync, keeping its size and modtime[0m+[36m(24) :[0m [34mhook during-sync delete-file {path2/}file3.txt[0m+[36m(25) :[0m [34mhook during-sync copy-as {datadir/}file3B.txt {path2/} file3.txt[0m+[36m(26) :[0m [34mbisync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile3.txt[0m+INFO : - [36mPath1[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile4.txt[0m+INFO : Path1: 2 changes: [32m 0 new[0m, [33m 2 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 2 newer[0m, [34m 0 older[0m, [36m 2 larger[0m, [34m 0 smaller[0m)+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[33mFile changed: [35msize (larger)[0m, [35mtime (newer)[0m[0m[0m - [36mfile3.txt[0m+INFO : Path2: 1 changes: [32m 0 new[0m, [33m 1 modified[0m, [31m 0 deleted[0m+INFO : ([33mModified[0m: [36m 1 newer[0m, [34m 0 older[0m, [36m 1 larger[0m, [34m 0 smaller[0m)+INFO : Applying changes+INFO : Checking potential conflicts...+NOTICE: {path2String}: 0 differences found+NOTICE: {path2String}: 1 matching files+INFO : Finished checking the potential conflicts. %!s(<nil>)+NOTICE: - [34mWARNING[0m [35mNew or changed in both paths[0m - [36mfile3.txt[0m+INFO : Files are equal! Skipping: file3.txt+INFO : - [36mPath1[0m [35m[32mQueue copy to[0m Path2[0m - [36m{path2/}file4.txt[0m+INFO : - [36mPath1[0m [35mDo queued copies to[0m - [36mPath2[0m+NOTICE: [36mhook during-sync:[0m [34mdelete-file {path2/}file3.txt[0m+NOTICE: [36mhook during-sync:[0m [34mcopy-as {datadir/}file3B.txt {path2/} file3.txt[0m+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(27) :[0m [34mtest bisync after file3 changed on Path2 during the sync[0m+[36m(28) :[0m [34mbisync[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": true,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : Path2 checking for diffs+INFO : No changes found+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(29) :[0m [34mtest new on both paths with --size-only, same size and different content - file10 (file10L, file10R)[0m+[36m(30) :[0m [34mtouch-glob 2001-01-02 {datadir/} file10L.txt[0m+[36m(31) :[0m [34mtouch-glob 2001-03-04 {datadir/} file10R.txt[0m+[36m(32) :[0m [34mcopy-as {datadir/}file10L.txt {path1/} file10.txt[0m+[36m(33) :[0m [34mcopy-as {datadir/}file10R.txt {path2/} file10.txt[0m+[36m(34) :[0m [34mbisync size-only[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": false,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[32mFile is new[0m[0m - [36mfile10.txt[0m+INFO : Path1: 1 changes: [32m 1 new[0m, [33m 0 modified[0m, [31m 0 deleted[0m+INFO : Path2 checking for diffs+INFO : - [34mPath2[0m [35m[32mFile is new[0m[0m - [36mfile10.txt[0m+INFO : Path2: 1 changes: [32m 1 new[0m, [33m 0 modified[0m, [31m 0 deleted[0m+INFO : Applying changes+INFO : Not checking potential conflicts, as only their sizes could be compared, and those already match.+NOTICE: - [34mWARNING[0m [35mNew or changed in both paths[0m - [36mfile10.txt[0m+INFO : Files are equal! Skipping: file10.txt+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0m++[36m(35) :[0m [34mtest delete file10 on Path1[0m+[36m(36) :[0m [34mdelete-file {path1/}file10.txt[0m+[36m(37) :[0m [34mbisync size-only[0m+INFO : [2mSetting --ignore-listing-checksum as neither --checksum nor --compare checksum are set.[0m+INFO : Bisyncing with Comparison Settings:+{+"Modtime": false,+"Size": true,+"Checksum": false,+"NoSlowHash": false,+"SlowHashSyncOnly": false,+"DownloadHash": false+}+INFO : Synching Path1 "{path1/}" with Path2 "{path2/}"+INFO : Building Path1 and Path2 listings+INFO : Path1 checking for diffs+INFO : - [36mPath1[0m [35m[31mFile was deleted[0m[0m - [36mfile10.txt[0m+INFO : Path1: 1 changes: [32m 0 new[0m, [33m 0 modified[0m, [31m 1 deleted[0m+INFO : Path2 checking for diffs+INFO : Applying changes+INFO : - [34mPath2[0m [35m[31mQueue delete[0m[0m - [36m{path2/}file10.txt[0m+INFO : - [36mPath1[0m [35mDo queued copies to[0m - [36mPath2[0m+INFO : There was nothing to transfer+INFO : Updating listings+INFO : Validating listings for Path1 "{path1/}" vs Path2 "{path2/}"+INFO : [32mBisync successful[0mdiff --git a/cmd/bisync/testdata/test_equal_skipped/initial/RCLONE_TEST b/cmd/bisync/testdata/test_equal_skipped/initial/RCLONE_TESTnew file mode 100644index 000000000..d8ca97c2a--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/initial/RCLONE_TEST@@ -0,0 +1 @@+This file is used for testing the health of rclone accesses to the local/remote file system. Do not delete.diff --git a/cmd/bisync/testdata/test_equal_skipped/initial/file1.txt b/cmd/bisync/testdata/test_equal_skipped/initial/file1.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_equal_skipped/initial/file2.txt b/cmd/bisync/testdata/test_equal_skipped/initial/file2.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_equal_skipped/initial/file3.txt b/cmd/bisync/testdata/test_equal_skipped/initial/file3.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_equal_skipped/initial/file4.txt b/cmd/bisync/testdata/test_equal_skipped/initial/file4.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_equal_skipped/initial/file5.txt b/cmd/bisync/testdata/test_equal_skipped/initial/file5.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_equal_skipped/initial/file6.txt b/cmd/bisync/testdata/test_equal_skipped/initial/file6.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_equal_skipped/initial/file7.txt b/cmd/bisync/testdata/test_equal_skipped/initial/file7.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_equal_skipped/initial/file8.txt b/cmd/bisync/testdata/test_equal_skipped/initial/file8.txtnew file mode 100644index 000000000..e69de29bbdiff --git a/cmd/bisync/testdata/test_equal_skipped/modfiles/file1.txt b/cmd/bisync/testdata/test_equal_skipped/modfiles/file1.txtnew file mode 100644index 000000000..f0176ce26--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/modfiles/file1.txt@@ -0,0 +1 @@+Same on bothdiff --git a/cmd/bisync/testdata/test_equal_skipped/modfiles/file10L.txt b/cmd/bisync/testdata/test_equal_skipped/modfiles/file10L.txtnew file mode 100644index 000000000..79de42721--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/modfiles/file10L.txt@@ -0,0 +1 @@+Path1 versiondiff --git a/cmd/bisync/testdata/test_equal_skipped/modfiles/file10R.txt b/cmd/bisync/testdata/test_equal_skipped/modfiles/file10R.txtnew file mode 100644index 000000000..8b94fd38c--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/modfiles/file10R.txt@@ -0,0 +1 @@+Path2 versiondiff --git a/cmd/bisync/testdata/test_equal_skipped/modfiles/file2.txt b/cmd/bisync/testdata/test_equal_skipped/modfiles/file2.txtnew file mode 100644index 000000000..0fd70321a--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/modfiles/file2.txt@@ -0,0 +1 @@+Newer version\ No newline at end of filediff --git a/cmd/bisync/testdata/test_equal_skipped/modfiles/file3.txt b/cmd/bisync/testdata/test_equal_skipped/modfiles/file3.txtnew file mode 100644index 000000000..8463ac05a--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/modfiles/file3.txt@@ -0,0 +1 @@+Same contentdiff --git a/cmd/bisync/testdata/test_equal_skipped/modfiles/file3B.txt b/cmd/bisync/testdata/test_equal_skipped/modfiles/file3B.txtnew file mode 100644index 000000000..97ba449be--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/modfiles/file3B.txt@@ -0,0 +1 @@+Changed textdiff --git a/cmd/bisync/testdata/test_equal_skipped/modfiles/file7.txt b/cmd/bisync/testdata/test_equal_skipped/modfiles/file7.txtnew file mode 100644index 000000000..464147f09--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/modfiles/file7.txt@@ -0,0 +1 @@+This file is newerdiff --git a/cmd/bisync/testdata/test_equal_skipped/scenario.txt b/cmd/bisync/testdata/test_equal_skipped/scenario.txtnew file mode 100644index 000000000..321469848--- /dev/null+++ b/cmd/bisync/testdata/test_equal_skipped/scenario.txt@@ -0,0 +1,53 @@+test equal skipped+# Check how identical files that are skipped instead of renamed are recorded in the listings+# - Changed on both paths and identical, then changed on Path2 during the sync file1+# - Changed on both paths and identical, then changed on Path2 during the sync,+# keeping the same size and modtime file3 (file3B)+# - New on both paths with --size-only, same size and different content file10 (file10L, file10R)++test initial bisync+bisync resync++test changed on both paths and identical - file1+touch-glob 2001-01-02 {datadir/} file1.txt+copy-as {datadir/}file1.txt {path1/} file1.txt+copy-as {datadir/}file1.txt {path2/} file1.txt++test changed on Path1 - file2+touch-glob 2001-01-02 {datadir/} file2.txt+copy-as {datadir/}file2.txt {path1/} file2.txt++test bisync with file1 changed on Path2 during the sync+touch-glob 2023-08-26 {datadir/} file7.txt+hook during-sync copy-as {datadir/}file7.txt {path2/} file1.txt+bisync++test bisync after file1 changed on Path2 during the sync+bisync++test changed on both paths and identical - file3+touch-glob 2002-02-02 {datadir/} file3*.txt+copy-as {datadir/}file3.txt {path1/} file3.txt+copy-as {datadir/}file3.txt {path2/} file3.txt++test changed on Path1 - file4+copy-as {datadir/}file2.txt {path1/} file4.txt++test bisync with file3 changed on Path2 during the sync, keeping its size and modtime+hook during-sync delete-file {path2/}file3.txt+hook during-sync copy-as {datadir/}file3B.txt {path2/} file3.txt+bisync++test bisync after file3 changed on Path2 during the sync+bisync++test new on both paths with --size-only, same size and different content - file10 (file10L, file10R)+touch-glob 2001-01-02 {datadir/} file10L.txt+touch-glob 2001-03-04 {datadir/} file10R.txt+copy-as {datadir/}file10L.txt {path1/} file10.txt+copy-as {datadir/}file10R.txt {path2/} file10.txt+bisync size-only++test delete file10 on Path1+delete-file {path1/}file10.txt+bisync size-onlydiff --git a/docs/content/bisync.md b/docs/content/bisync.mdindex c73ab3e3f..1e4475a0d 100644--- a/docs/content/bisync.md+++ b/docs/content/bisync.md@@ -1940,6 +1940,7 @@ the `--max-delete` safety check when used with `--track-renames`.- Fixed an issue causing the conflict winner to be missing from listings whenPath2 won.- Fixed an issue causing `--conflict-resolve` to compare a zero size or modtime.+- Fixed an issue causing an endless retry loop for certain skipped files.### `v1.74.2`