git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Fix merge parent checking with svn.pushmergeinfo.

From
Jason Merrill <jason@redhat.com>
Date
Sep 16, 2017, 03:29 UTC
Message-ID
<CADzB+2mT=Ht5AQybp+44+PMbRrWXB4dPyTmsEgfVkOOujZYQxQ@mail.gmail.com>
In-Reply-To
<20170915215303.GV27425@aiede.mtv.corp.google.com>
On Fri, Sep 15, 2017 at 5:53 PM, Jonathan Nieder <jrnieder@gmail.com> wrote:
Show 30 quoted lines
> Jason Merrill wrote:
>> On Fri, Sep 15, 2017 at 1:52 PM, Jonathan Nieder <jrnieder@gmail.com> wrote:
>> > Jason Merrill wrote:
>
>>>> Subject: Fix merge parent checking with svn.pushmergeinfo.
>>>>
>>>> Without this fix, svn dcommit of a merge with svn.pushmergeinfo set would
>>>> get error messages like "merge parent <X> for <Y> is on branch
>>>> svn+ssh://gcc.gnu.org/svn/gcc/trunk, which is not under the git-svn root
>>>> svn+ssh://jason@gcc.gnu.org/svn/gcc!"
>>>>
>>>> * git-svn.perl: Remove username from rooturl before comparing to branchurl.
>>>>
>>>> Signed-off-by: Jason Merrill <jason@redhat.com>
>>>
>>> Interesting.  Thanks for writing it.
>>
>> Thanks for the review.
>>
>>> Could there be a test for this to make sure this doesn't regress in
>>> the future?  See t/t9151-svn-mergeinfo.sh for some examples.
>>
>> Hmm, I'm afraid figuring out how to write such a test would take
>> longer than I can really spare for this issue.  There don't seem to be
>> any svn+ssh tests currently.
>
> Well, could you give manual commands to allow me to reproduce the
> problem?
>
> Then I'll translate them into a test. :)
Something like this:

git svn clone -s svn+ssh://user@host/repo git config svn.pushmergeinfo yes git checkout -b branch origin/branch git merge origin/trunk git svn dcommit

Thanks!
Show 5 quoted lines
> FWIW remove_username seems to be able to cope fine with an http://
> URL.  t/lib-httpd.sh starts an http server with Subversion enabled,
> as long as the envvar GIT_SVN_TEST_HTTPD is set to true.  Its address
> is $svnrepo, which is an http URL (but I don't see a username in the
> URL).  Does that help?
I think the http transport handles the username separately, not in the URL.

I would expect that a dummy ssh wrapper like some of the tests use would be sufficient, no need for an actual network connection.

> Alternatively, does using rewrite-root as in t9151-svn-mergeinfo.sh
> help?

Hmm, I'm not sure how rewriteRoot would interact with this issue, whether it would be useful as a workaround or another problematic case.

Jason
Previous: Jonathan Nieder
Message 7 of 7 in “Fix merge parent checking with svn.pushmergeinfo.”
  1. Fix merge parent checking with svn.pushmergeinfo.Jason Merrill, Sep 15, 2017
  2. Jonathan NiederSep 15, 2017
  3. Jason MerrillSep 15, 2017
  4. git-svn: Fix svn.pushmergeinfo handling of svn+ssh usernames.Jason Merrill, Sep 15, 2017
  5. Jonathan NiederSep 15, 2017
  6. Jonathan NiederSep 15, 2017
  7. Jason MerrillSep 16, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.