"stream ended unexpectedly" on clone

bitbucket, mercurial

Solution

Your TCP connection to bitbucket is dying before the whole repo is downloaded -- probably a flaky net connection or a full disk. If it's the former you can do it in small chunks using `-r` like this:

hg init montao
cd montao
hg pull -r 50 https://niklasr@bitbucket.org/niklasr/montao  # get the first 50 changesets
hg pull -r 100 https://niklasr@bitbucket.org/niklasr/montao  # get the next 50 changesets
...

That should only be necessary if something's wrong with your network route to bitbucket or the repository is incredibly huge.

Problem

I try to clone but I get a rollback. I could clone at another computer previously but now I get a rollback and I don't know why: ``` C:\Users\Niklas\montao>hg clone https://niklasr@bitbucket.org/niklasr/montao http authorization required realm: Bitbucket.org HTTP user: niklasr password: destination directory: montao requesting all changes adding changesets adding manifests adding file changes transaction abort! rollback completed abort: connection ended unexpectedly C:\Users\Niklas\montao> ``` Currently I'm just trying to do it over again but I suspect that it wil ltime out, can you tell me how to debug more what's happening and possibly resolve the issue? I ran it in debug mode and this is what happens. ``` adding google_appengine/lib/django_1_3/django/contrib/localflavor/locale/mn/LC_M ESSAGES/django.mo revisions files: 10223/50722 chunks (20.15%) transaction abort! ```

Original source