Skip to content

dvc push doesn't update cloud info with cloud versioned remotes #9947

Closed as not planned
@shcheklein

Description

@shcheklein

Context: #9907 (reply in thread)

Let's say we have two remotes:

['remote "dev"']
    url = s3://yury-cloud-versioning-test/test-dev
    version_aware=true
['remote "prod"']
    url = s3://yury-cloud-versioning-test/test-prod
    version_aware=true

Let's say we need to migrate data from one to another.

I would expect commands like this:

dvc pull -r dev
dvc push -r prod

to work and update .dvc \ dvc.lock files with an appropriate info, in reality I'm getting:

(.venv) √ Projects/test-cloud-versioned % git diff
diff --git a/test.txt.dvc b/test.txt.dvc
index d5fbaa9..03f455c 100644
--- a/test.txt.dvc
+++ b/test.txt.dvc
@@ -4,6 +4,6 @@ outs:
   hash: md5
   path: test.txt
   cloud:
-    dev:
+    prod:
       etag: d8e8fca2dc0f896fd7cb4cb0031ba249
       version_id: UK3s0VcueuAIttMw7FROG8pRospYWNQI

(only remote name is updated, info stays the same, which is wrong for that remote).

In the original issue, even the object is not pushed to the new remote.

Also, in case of cloud versioning I think prod / dev don't make much sense in .dvc \ dvc.lock. Version_id is unique (I assume) and can't repeat in a different location. I guess we need to use some hash, or location itself in this case. How do we use these names at all? do we expect that specific remote name to exist in a config?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugDid we break something?

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions