1
votes

My question's pretty much in the title. Again, when trying to issue a clone, pull, or incoming command using mercurial from any repository on an HgLab server (whether that repository was already created from scratch on the server, or whether that repository was already pushed to the server, in both cases prior to issuing a supposedly erroneous command), I get a mismatch error. Here's the log:

hg --verbose --debug --traceback incoming http://user@server:81/hg/project/repository

  • using http://server:81/hg/project/repository
  • http auth: user user, password not set sending capabilities command
  • [HgKeyring] Keyring URL: http://server:81/hg/project/repository
  • [HgKeyring] Looking for password for user user and url http://server:81/hg/project/ repository
  • [HgKeyring] Keyring password found. Url: http://server:81/hg/project/ repository, user: user, passwd: *****
  • comparing with http://user@server:81/hg/project/ repository
    query 1; heads
  • sending batch command
  • searching for changes
  • all local heads known remotely
  • sending getbundle command
  • Traceback (most recent call last):
    • File "mercurial\dispatch.pyo", line 204, in _runcatch
    • File "mercurial\dispatch.pyo", line 887, in _dispatch
    • File "mercurial\dispatch.pyo", line 632, in runcommand
    • File "mercurial\dispatch.pyo", line 1017, in _runcommand
    • File "mercurial\dispatch.pyo", line 978, in checkargs
    • File "mercurial\dispatch.pyo", line 884, in
    • File "mercurial\util.pyo", line 1005, in check
    • File "mercurial\commands.pyo", line 5067, in incoming
    • File "mercurial\hg.pyo", line 820, in incoming
    • File "mercurial\hg.pyo", line 783, in _incoming
    • File "mercurial\bundlerepo.pyo", line 509, in getremotechanges
    • File "mercurial\bundle2.pyo", line 1319, in writebundle
    • File "mercurial\changegroup.pyo", line 102, in writechunks
    • File "mercurial\bundle2.pyo", line 1312, in chunkiter
    • File "mercurial\changegroup.pyo", line 228, in getchunks
    • File "mercurial\changegroup.pyo", line 48, in getchunk
    • File "mercurial\changegroup.pyo", line 43, in readexactly
  • abort: stream ended unexpectedly (got 0 bytes, expected 4)

Before anyone is willing to provide easy solutions, it should suffice to know that I've tried the following already:

  • Look up existing solutions on stackoverflow, none of which worked. Some of them are:
    • Using an older version of Mercurial (downgrading from 3.5.1 to 3.4.2)
    • Running hg verify on both the local machine and the server to fix inconsistencies in both repositories
  • hg pull -r 0 http://user@server:81/hg/project/repository (gives the same error)
  • hg pull -f -r 0 http://user@server:81/hg/project/repository (gives the same error)
  • hg incoming -r 0 http://user@server:81/hg/project/repository (gives the same error)
  • hg incoming -f -r 0 http://user@server:81/hg/project/repository (gives the same error)

It should also be noted that hg outgoing and hg push don't give any problems whatsoever.

Please help!

Thanks guys :)

1
Any self hosting mercurial repository solutions out there that are stable and reliable?Ratnesh Chandna
I'd look into Kallithea.durin42
Kalithea's a little too expensive.Ratnesh Chandna
Kallithea is free - what do you mean?durin42

1 Answers

0
votes

There's a bug in HgLab in the component that handles bundling the response to hg incoming or hg pull. The exact details are unclear; you'll want to contact their customer support for details (they're very responsive).

If version 1.10.6 does not have the fix, versions after that should have it.