]> dgit.raspbian.org Git - git-annex.git/commitdiff
fixed --rebalance stability on drop
authorJoey Hess <joeyh@joeyh.name>
Tue, 13 Aug 2024 17:32:11 +0000 (13:32 -0400)
committerJoey Hess <joeyh@joeyh.name>
Tue, 13 Aug 2024 17:32:11 +0000 (13:32 -0400)
Was checking the wrong uuid, oops

Limit.hs
doc/todo/git-annex_proxies.mdwn

index 81e0d91f47ed178bb87fc4abf4cf6c8e0da9175e..3e0bd8065423e221c5e73a5ca2f5463331f2e910 100644 (file)
--- a/Limit.hs
+++ b/Limit.hs
@@ -603,7 +603,7 @@ limitFullyBalanced mu getgroupmap groupname = Right $ MatchFiles
                let keysize = fromMaybe 0 (fromKey keySize key)
                let hasspace u = case (M.lookup u maxsizes, M.lookup u sizemap) of
                        (Just (MaxSize maxsize), Just (RepoSize reposize)) ->
-                               if maybe False (`S.member` notpresent) mu
+                               if u `S.member` notpresent
                                        then reposize <= maxsize
                                        else reposize + keysize <= maxsize
                        _ -> True
index 1b9607c713e929b819f01159e26e0f02cad89af3..00b7c4030bc5f9ace02ba41febe5b7f4ba384a3b 100644 (file)
@@ -51,10 +51,6 @@ Planned schedule of work:
 
 * `git-annex info` can use maxsize to display how full repositories are
 
-* --rebalance is not stable. It will drop a key that was just stored in a
-  repo. Seems that limitFullyBalanced needs to take AssumeNotPresent
-  into account to handle dropping correctly.
-
 * Implement [[track_free_space_in_repos_via_git-annex_branch]]:
 
   * Load Annex.reposizes from Database.RepoSizes on startup.