notes on ImportableContents history not being used for retrieval
authorJoey Hess <joeyh@joeyh.name>
Tue, 22 Dec 2020 15:23:00 +0000 (11:23 -0400)
committerJoey Hess <joeyh@joeyh.name>
Tue, 22 Dec 2020 15:24:11 +0000 (11:24 -0400)
Types/Import.hs
doc/design/external_special_remote_protocol/export_and_import_appendix.mdwn

index 2724ddc7ef79d21e58f46e46f3c13728f4f331a7..2013e44cdeb816b9d6c847be04077f5858b5f5ee 100644 (file)
@@ -59,6 +59,12 @@ data ImportableContents info = ImportableContents
        -- ^ Used by remotes that support importing historical versions of
        -- files that are stored in them. This is equivilant to a git
        -- commit history.
+       --
+       -- When retrieving a historical version of a file,
+       -- old ImportLocations from importableHistory are not used;
+       -- the content is no longer expected to be present at those
+       -- locations. So, if a remote does not support Key/Value access,
+       -- it should not populate the importableHistory.
        }
        deriving (Show, Generic)
 
index d1b255a8d0930b3eabd344540ab288b8a823f183..9d474dbcbf6610ff1656ab9b548b53702f8e5842 100644 (file)
@@ -167,7 +167,9 @@ support a request, it can reply with `UNSUPPORTED-REQUEST`.
     this can be used to list those versions. It opens a new
     block of responses. This can be repeated any number of times
     (indicating a branching history), and histories can also
-    be nested multiple levels deep.
+    be nested multiple levels deep.  
+    This should only be used when the remote supports using
+    "TRANSFER RECEIVE Key" to retrieve historical versions of files.
   * `END`  
     Indicates the end of a block of responses.
 * `LOCATION Name`