)]}' { "commit": "0e776a5837d08d58cedd1d9e4288ed7db349749c", "tree": "28c7c3898923413f0ca6b141671ee811303cfbc5", "parents": [ "1da6f30579ca6aa698becc0daaf71eaa86237fc8" ], "author": { "name": "Xin Li", "email": "delphij@google.com", "time": "Tue Jun 29 21:42:34 2021 +0000" }, "committer": { "name": "Xin Li", "email": "delphij@google.com", "time": "Wed Jun 30 15:31:15 2021 +0000" }, "message": "Fix an issue when syncing with --use-superproject and clone bundles.\n\nIt is possible that a clone bundle contained the object referenced by\nthe branch in the manifest and in the superproject, but not the branch\nitself (for example, the branch may be newly created from an existing\nbranch, or is not vislble to the user downloading the clone bundle).\n\nWhen --use-superproject is enabled, because we are overriding\nrevisionExpr with the SHA1 revision provided by the superproject, the\nverification step would succeed, but because the expected branch do not\nexist, it would confuse git-repo at a later time, as it is expecting the\nremote branch to exist in the local clone.\n\nIn project.py, fix this by making SetRevisionId() to always remember\nthe actual branch name and verify it in _CheckForImmutableRevision()\nso that we only skip the fetch step when both objects exists locally.\n\nBug: [google internal] b/191974277\nChange-Id: I49d3ca0667f524c8c45f416492faf95b1dd822fb\nReviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/310802\nReviewed-by: Raman Tenneti \u003crtenneti@google.com\u003e\nReviewed-by: Mike Frysinger \u003cvapier@google.com\u003e\nTested-by: Xin Li \u003cdelphij@google.com\u003e\n", "tree_diff": [ { "type": "modify", "old_id": "2ab0b389ded78ec84068137c0f0faaf04361a600", "old_mode": 33188, "old_path": "project.py", "new_id": "e777dbd2bd2c4119cf754552e413023e53ac9545", "new_mode": 33188, "new_path": "project.py" }, { "type": "modify", "old_id": "c3f885319f65008c495036d31113735dd4a6125d", "old_mode": 33188, "old_path": "tests/test_git_superproject.py", "new_id": "6ff81843237bb2d3964fee70542cdc99c57b1bc4", "new_mode": 33188, "new_path": "tests/test_git_superproject.py" }, { "type": "modify", "old_id": "2a16900afabf53df8e2100ca6fc9d541f3678c09", "old_mode": 33188, "old_path": "tests/test_manifest_xml.py", "new_id": "55468b51b53383ba20a427b0fa79c97f6c005e64", "new_mode": 33188, "new_path": "tests/test_manifest_xml.py" } ] }