Running multiple commands on commandserver interface

Idan Kamara idankk86 at gmail.com
Thu Apr 12 10:49:21 UTC 2012


On Thu, Apr 12, 2012 at 10:00 AM, Ton Plomp <tcplomp at gmail.com> wrote:

> Hello All,
>
> I have some issues (mainly speed) with the command line interface of
> mercurial, so I changed to the commandserver interface via pipes.
>
> I thought it was possible to keep one server active per repository and
> communicate continuously via stdin, however if I want to run a second
> command on the same pipe the process is closed by the server.
>
> Here's a traceback from the error output:
>
> Traceback (most recent call last):
> File "mercurial\dispatch.pyo", line 87, in _runcatch
> File "mercurial\dispatch.pyo", line 683, in _dispatch
> File "mercurial\dispatch.pyo", line 465, in runcommand
> File "mercurial\dispatch.pyo", line 737, in _runcommand
> File "mercurial\dispatch.pyo", line 691, in checkargs
> File "mercurial\dispatch.pyo", line 680, in <lambda>
> File "mercurial\util.pyo", line 456, in check
> File "mercurial\extensions.pyo", line 139, in wrap
> File "mercurial\util.pyo", line 456, in check
> File "hgext\mq.pyo", line 3337, in mqcommand
> File "mercurial\util.pyo", line 456, in check
> File "mercurial\commands.pyo", line 5053, in serve
> File "mercurial\commandserver.pyo", line 231, in serve
> File "mercurial\commandserver.pyo", line 215, in serveone
> Abort: unknown command\00runcommand
> abort: unknown command\00runcommand
>
>
> I write the same command twice to the pipe:
> runcommand\n\00\00\00\03log\00
>

If you have one argument it doesn't need to include the delimiter
so the last \0 after 'log' is what's causing the problem.


>
> As soon as the second command is run the server is closed
>
> Does anybody know if it's possible to use the same pipe for multiple
> commands?
>
> Ton
>
>
> _______________________________________________
> Mercurial mailing list
> Mercurial at selenic.com
> http://selenic.com/mailman/listinfo/mercurial
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20120412/609778cf/attachment-0002.html>


More information about the Mercurial mailing list