{"thread":{"id":"14782","subject":"[PATCH] git svn: should not display zombie externals","startedAt":"2008-07-31T22:33:19Z","lastAt":"2008-08-12T17:05:49Z","messageCount":3,"participants":["Eddy Petrișor"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"85842","messageId":"48923DAF.7070900@gmail.com","threadId":"14782","inReplyTo":null,"subject":"[PATCH] git svn: should not display zombie externals","fromName":"Eddy Petrișor","fromEmail":"eddy.petrisor@gmail.com","sentAt":"2008-07-31T22:33:19Z","receivedAt":"2008-07-31T22:33:19Z","isPatch":true,"sender":{"key":"eddy.petrisor@gmail.com","avatar":"https://gravatar.com/avatar/e13eef6cecbe95604b4667c7bddf5aee2bb4af684c5fdceaf9e2aebfead3e9f5?d=mp&s=160"},"body":"\nduring the history of a repo a svn:external could be added and later\nremoved; such externals shouldn't be displayed since only the current\nstate is relevant\n\nI have encountered the broken behaviour on a git-svn repo with the svn\norigin a repo served via https (git 1:1.5.6-1~bpo40+1 from Debian Etch\nbackports.) I hope this bug doesn't have to do with the svn repo being\nserved via https.\n\nSigned-off-by: Eddy Petrișor <eddy.petrisor@gmail.com>\n---\n  t/t9101-git-svn-props.sh |   23 ++++++++++++++++++++++-\n  1 files changed, 22 insertions(+), 1 deletions(-)\n\ndiff --git a/t/t9101-git-svn-props.sh b/t/t9101-git-svn-props.sh\nindex f420796..e5ab748 100755\n--- a/t/t9101-git-svn-props.sh\n+++ b/t/t9101-git-svn-props.sh\n@@ -211,7 +211,28 @@ EOF\n\n  test_expect_success 'test proplist' \"\n  \tgit-svn proplist . | cmp - prop.expect &&\n-\tgit-svn proplist nested/directory/.keep | cmp - prop2.expect\n+\tgit-svn proplist nested/directory/.keep | cmp - prop2.expect &&\n+\tcd ..\n+\t\"\n+\n+test_expect_success 'show external' \"\n+\tcd test_wc &&\n+\t\tsvn propset svn:externals 'zombie file:///fake/external' . &&\n+\t\tsvn ci -m 'added a fake svn:external' &&\n+\tcd .. &&\n+\tgit-svn fetch &&\n+\tgit-merge git-svn &&\n+\tgit-svn show-externals | grep -q 'zombie'\n+\t\"\n+\n+test_expect_success 'remove external' \"\n+\tcd test_wc &&\n+\t\tsvn propdel svn:externals . &&\n+\t\tsvn ci -m 'deleted the fake external' &&\n+\tcd .. &&\n+\tgit-svn fetch &&\n+\tgit-merge git-svn &&\n+\tgit-svn show-externals | grep -q -v 'zombie'\n  \t\"\n\n  test_done\n-- \n1.5.6.3\n"},{"id":"85845","messageId":"48923E95.2020302@gmail.com","threadId":"14782","inReplyTo":"48923DAF.7070900@gmail.com","subject":"[PATCH] git svn: should not display zombie externals","fromName":"Eddy Petrișor","fromEmail":"eddy.petrisor@gmail.com","sentAt":"2008-07-31T22:37:09Z","receivedAt":"2008-07-31T22:37:09Z","isPatch":true,"sender":{"key":"eddy.petrisor@gmail.com","avatar":"https://gravatar.com/avatar/e13eef6cecbe95604b4667c7bddf5aee2bb4af684c5fdceaf9e2aebfead3e9f5?d=mp&s=160"},"body":"\nduring the history of a repo a svn:external could be added and later\nremoved; such externals shouldn't be displayed since only the current\nstate is relevant\n\nI have encountered the broken behaviour on a git-svn repo with the svn\norigin a repo served via https (git 1:1.5.6-1~bpo40+1 from Debian Etch\nbackports.) I hope this bug doesn't have to do with the svn repo being\nserved via https.\n\nSigned-off-by: Eddy Petrișor <eddy.petrisor@gmail.com>\n---\n  t/t9101-git-svn-props.sh |   23 ++++++++++++++++++++++-\n  1 files changed, 22 insertions(+), 1 deletions(-)\n\ndiff --git a/t/t9101-git-svn-props.sh b/t/t9101-git-svn-props.sh\nindex f420796..e5ab748 100755\n--- a/t/t9101-git-svn-props.sh\n+++ b/t/t9101-git-svn-props.sh\n@@ -211,7 +211,28 @@ EOF\n\n  test_expect_success 'test proplist' \"\n  \tgit-svn proplist . | cmp - prop.expect &&\n-\tgit-svn proplist nested/directory/.keep | cmp - prop2.expect\n+\tgit-svn proplist nested/directory/.keep | cmp - prop2.expect &&\n+\tcd ..\n+\t\"\n+\n+test_expect_success 'show external' \"\n+\tcd test_wc &&\n+\t\tsvn propset svn:externals 'zombie file:///fake/external' . &&\n+\t\tsvn ci -m 'added a fake svn:external' &&\n+\tcd .. &&\n+\tgit-svn fetch &&\n+\tgit-merge git-svn &&\n+\tgit-svn show-externals | grep -q 'zombie'\n+\t\"\n+\n+test_expect_success 'remove external' \"\n+\tcd test_wc &&\n+\t\tsvn propdel svn:externals . &&\n+\t\tsvn ci -m 'deleted the fake external' &&\n+\tcd .. &&\n+\tgit-svn fetch &&\n+\tgit-merge git-svn &&\n+\tgit-svn show-externals | grep -q -v 'zombie'\n  \t\"\n\n  test_done\n-- \n1.5.6.3\n\n\nThis one is properly formated (the previous one was a copy/paste from the output of the console).\n"},{"id":"86949","messageId":"60381eeb0808121005h72ee6ef2g8a979d9f6875ee51@mail.gmail.com","threadId":"14782","inReplyTo":"48923E95.2020302@gmail.com","subject":"Re: [PATCH] git svn: should not display zombie externals","fromName":"Eddy Petrișor","fromEmail":"eddy.petrisor@gmail.com","sentAt":"2008-08-12T17:05:49Z","receivedAt":"2008-08-12T17:05:49Z","isPatch":true,"sender":{"key":"eddy.petrisor@gmail.com","avatar":"https://gravatar.com/avatar/e13eef6cecbe95604b4667c7bddf5aee2bb4af684c5fdceaf9e2aebfead3e9f5?d=mp&s=160"},"body":"2008/8/1 Eddy Petrișor <eddy.petrisor@gmail.com>:\n>\n> during the history of a repo a svn:external could be added and later\n> removed; such externals shouldn't be displayed since only the current\n> state is relevant\n>\n> I have encountered the broken behaviour on a git-svn repo with the svn\n> origin a repo served via https (git 1:1.5.6-1~bpo40+1 from Debian Etch\n> backports.) I hope this bug doesn't have to do with the svn repo being\n> served via https.\n\nI have finally found the root of this breakage. It seems that the\nolder versions of subversion allowed a svn:external property to be\nempty, thus generating the zombie externals. Newer versions of\nsubversion (I checked this with 1.4.2 (r22196) from Debian Etch) do\nnot allow such empty svn:externals.\n\n> Signed-off-by: Eddy Petrișor <eddy.petrisor@gmail.com>\n> ---\n>  t/t9101-git-svn-props.sh |   23 ++++++++++++++++++++++-\n>  1 files changed, 22 insertions(+), 1 deletions(-)\n>\n> diff --git a/t/t9101-git-svn-props.sh b/t/t9101-git-svn-props.sh\n> index f420796..e5ab748 100755\n> --- a/t/t9101-git-svn-props.sh\n> +++ b/t/t9101-git-svn-props.sh\n> @@ -211,7 +211,28 @@ EOF\n>\n>  test_expect_success 'test proplist' \"\n>        git-svn proplist . | cmp - prop.expect &&\n> -       git-svn proplist nested/directory/.keep | cmp - prop2.expect\n> +       git-svn proplist nested/directory/.keep | cmp - prop2.expect &&\n> +       cd ..\n> +       \"\n> +\n> +test_expect_success 'show external' \"\n> +       cd test_wc &&\n> +               svn propset svn:externals 'zombie file:///fake/external' .\n> &&\n> +               svn ci -m 'added a fake svn:external' &&\n> +       cd .. &&\n> +       git-svn fetch &&\n> +       git-merge git-svn &&\n> +       git-svn show-externals | grep -q 'zombie'\n> +       \"\n> +\n> +test_expect_success 'remove external' \"\n> +       cd test_wc &&\n> +               svn propdel svn:externals . &&\n> +               svn ci -m 'deleted the fake external' &&\n> +       cd .. &&\n> +       git-svn fetch &&\n> +       git-merge git-svn &&\n> +       git-svn show-externals | grep -q -v 'zombie'\n>        \"\n>\n>  test_done\n> --\n> 1.5.6.3\n>\n>\n> This one is properly formated (the previous one was a copy/paste from the\n> output of the console).\n>\n\n\n\n-- \nRegards,\nEddyP\n=============================================\n\"Imagination is more important than knowledge\" A.Einstein\n"}]}