You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Alexander Sinyushkin <Al...@svnkit.com> on 2008/05/29 08:13:42 UTC

[PATCH] 1.5.x branch: python/cmdline

Hello!

Attached is a patch that fixes number of minor issues in Subversion
python tests suite. Patch is against 1.5.x branch.

Explanation:

main.py patch

Recently we started to use client/server approach for running Subversion
python tests suite against SVNKit Subversion library. We use server that
accepts Subversion commands through the TCP/IP socket and client which
is a bash script - it reads parameters, stdin, certain environment
variables and then sends everything to the server.

To send data to the server we use netcat or, alternatively, bash
/dev/tcp/host/port device. In both case complete stdin have to be read
before sending data to the server. However, main.py doesn't close stdin
of the launched process before launching another process (in particular
when running svnadmin dump repos1 | svnadmin load repos2 commands). As a
result our tests were entering a deadlock. Suggested patch doesn't
change anything in tests behavior with native Subversion - it just
closes stdin of the launched process as soon as no more data is about to
be sent to the process stdin.

Another modification included into this patch is setting
SVN_CURRENT_TEST environment variable before running certain test. This
allows us to track what test is currently running when the whole test
suite is launched (i.e. "./copy.py" without specifying exact test number
to run).

And at last, made svndumpfilter_binary point to a jsvndumpfilter binary 
if --use-jsvn is specified.

You will make our life much easier if you include this contribution to 
your repository :) Thank you in advance!

----
Alexander Sinyushkin,
TMate Software,
http://svnkit.com/ - Java [Sub]Versioning Library!

Re: [PATCH] 1.5.x branch: python/cmdline

Posted by Alexander Sinyushkin <Al...@svnkit.com>.
I think this patch applies correctly only to a branch version. But we 
can make a patch for the trunk version and send you as well :)
It would be great if you commit it.
----
Alexander Sinyushkin,
TMate Software,
http://svnkit.com/ - Java [Sub]Versioning Library!

Daniel Shahaf wrote:
> Alexander Sinyushkin wrote on Thu, 29 May 2008 at 15:13 +0700:
>> Hello!
>>
>> Attached is a patch that fixes number of minor issues in Subversion
>> python tests suite. Patch is against 1.5.x branch.
>>
> 
> Thanks for the patch.  Does it apply to trunk?  Could you also attach a 
> log message?  (http://subversion.tigris.org/hacking.html#log-messages)
> 
> Daniel
> 
>> Explanation:
>>
>> main.py patch
>>
>> Recently we started to use client/server approach for running Subversion
>> python tests suite against SVNKit Subversion library. We use server that
>> accepts Subversion commands through the TCP/IP socket and client which
>> is a bash script - it reads parameters, stdin, certain environment
>> variables and then sends everything to the server.
>>
>> To send data to the server we use netcat or, alternatively, bash
>> /dev/tcp/host/port device. In both case complete stdin have to be read
>> before sending data to the server. However, main.py doesn't close stdin
>> of the launched process before launching another process (in particular
>> when running svnadmin dump repos1 | svnadmin load repos2 commands). As a
>> result our tests were entering a deadlock. Suggested patch doesn't
>> change anything in tests behavior with native Subversion - it just
>> closes stdin of the launched process as soon as no more data is about to
>> be sent to the process stdin.
>>
>> Another modification included into this patch is setting
>> SVN_CURRENT_TEST environment variable before running certain test. This
>> allows us to track what test is currently running when the whole test
>> suite is launched (i.e. "./copy.py" without specifying exact test number
>> to run).
>>
>> And at last, made svndumpfilter_binary point to a jsvndumpfilter binary if
>> --use-jsvn is specified.
>>
>> You will make our life much easier if you include this contribution to your
>> repository :) Thank you in advance!
>>
>> ----
>> Alexander Sinyushkin,
>> TMate Software,
>> http://svnkit.com/ - Java [Sub]Versioning Library!
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org
> 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: [PATCH] 1.5.x branch: python/cmdline

Posted by Karl Fogel <kf...@red-bean.com>.
Stefan Sperling <st...@elego.de> writes:
> On Thu, May 29, 2008 at 05:20:31PM +0700, Alexander Sinyushkin wrote:
>> Or maybe you can merge these changes back to trunk after you apply the 
>> patch to the branch?
>
> Changes made to Subversion should, in general, enter our code
> base through trunk. This ensures developer sanity.

Nothing ensures developer sanity around here.  But having changes enter
on trunk at least makes developer sanity *slightly* more likely :-).

-Karl

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: [PATCH] 1.5.x branch: python/cmdline

Posted by Stefan Sperling <st...@elego.de>.
On Thu, May 29, 2008 at 05:20:31PM +0700, Alexander Sinyushkin wrote:
> Or maybe you can merge these changes back to trunk after you apply the 
> patch to the branch?

Changes made to Subversion should, in general, enter our code
base through trunk. This ensures developer sanity.

Stefan

Re: [PATCH] 1.5.x branch: python/cmdline

Posted by Alexander Sinyushkin <Al...@svnkit.com>.
Or maybe you can merge these changes back to trunk after you apply the 
patch to the branch?
----
Alexander Sinyushkin,
TMate Software,
http://svnkit.com/ - Java [Sub]Versioning Library!

Daniel Shahaf wrote:
> Alexander Sinyushkin wrote on Thu, 29 May 2008 at 15:13 +0700:
>> Hello!
>>
>> Attached is a patch that fixes number of minor issues in Subversion
>> python tests suite. Patch is against 1.5.x branch.
>>
> 
> Thanks for the patch.  Does it apply to trunk?  Could you also attach a 
> log message?  (http://subversion.tigris.org/hacking.html#log-messages)
> 
> Daniel
> 
>> Explanation:
>>
>> main.py patch
>>
>> Recently we started to use client/server approach for running Subversion
>> python tests suite against SVNKit Subversion library. We use server that
>> accepts Subversion commands through the TCP/IP socket and client which
>> is a bash script - it reads parameters, stdin, certain environment
>> variables and then sends everything to the server.
>>
>> To send data to the server we use netcat or, alternatively, bash
>> /dev/tcp/host/port device. In both case complete stdin have to be read
>> before sending data to the server. However, main.py doesn't close stdin
>> of the launched process before launching another process (in particular
>> when running svnadmin dump repos1 | svnadmin load repos2 commands). As a
>> result our tests were entering a deadlock. Suggested patch doesn't
>> change anything in tests behavior with native Subversion - it just
>> closes stdin of the launched process as soon as no more data is about to
>> be sent to the process stdin.
>>
>> Another modification included into this patch is setting
>> SVN_CURRENT_TEST environment variable before running certain test. This
>> allows us to track what test is currently running when the whole test
>> suite is launched (i.e. "./copy.py" without specifying exact test number
>> to run).
>>
>> And at last, made svndumpfilter_binary point to a jsvndumpfilter binary if
>> --use-jsvn is specified.
>>
>> You will make our life much easier if you include this contribution to your
>> repository :) Thank you in advance!
>>
>> ----
>> Alexander Sinyushkin,
>> TMate Software,
>> http://svnkit.com/ - Java [Sub]Versioning Library!
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org
> 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: [PATCH] 1.5.x branch: python/cmdline

Posted by Daniel Shahaf <d....@daniel.shahaf.co.il>.
Alexander Sinyushkin wrote on Thu, 29 May 2008 at 15:13 +0700:
> Hello!
> 
> Attached is a patch that fixes number of minor issues in Subversion
> python tests suite. Patch is against 1.5.x branch.
> 

Thanks for the patch.  Does it apply to trunk?  Could you also attach a 
log message?  (http://subversion.tigris.org/hacking.html#log-messages)

Daniel

> Explanation:
> 
> main.py patch
> 
> Recently we started to use client/server approach for running Subversion
> python tests suite against SVNKit Subversion library. We use server that
> accepts Subversion commands through the TCP/IP socket and client which
> is a bash script - it reads parameters, stdin, certain environment
> variables and then sends everything to the server.
> 
> To send data to the server we use netcat or, alternatively, bash
> /dev/tcp/host/port device. In both case complete stdin have to be read
> before sending data to the server. However, main.py doesn't close stdin
> of the launched process before launching another process (in particular
> when running svnadmin dump repos1 | svnadmin load repos2 commands). As a
> result our tests were entering a deadlock. Suggested patch doesn't
> change anything in tests behavior with native Subversion - it just
> closes stdin of the launched process as soon as no more data is about to
> be sent to the process stdin.
> 
> Another modification included into this patch is setting
> SVN_CURRENT_TEST environment variable before running certain test. This
> allows us to track what test is currently running when the whole test
> suite is launched (i.e. "./copy.py" without specifying exact test number
> to run).
> 
> And at last, made svndumpfilter_binary point to a jsvndumpfilter binary if
> --use-jsvn is specified.
> 
> You will make our life much easier if you include this contribution to your
> repository :) Thank you in advance!
> 
> ----
> Alexander Sinyushkin,
> TMate Software,
> http://svnkit.com/ - Java [Sub]Versioning Library!
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org