Anytime I try to do any interaction with the server, Mercurial returns "abort: HTTP Error 400: Bad Request". We are not using any authentication, so that's not an issue. We have three other developers working on the same repo with the same version of mercurial installed (2.2.3). They haven't had any issues, so it makes me think I'm corrupting something in the .hg folder or something. But I really have no clue.
I was able to clone and work from the new directory just fine. However, about 4 hours later, it started happening again in the new directory too. The only things I did in that time period were commit, pull, and push. When I committed a few hours later and tried to pull, that's when I got the error again.
Here is the debug log for incoming (hg --debug --traceback incoming):
using http://myserver/myapp
sending capabilities command
comparing with http://myserver/myapp
query 1; heads
sending batch command
searching for changes
taking initial sample
searching: 2 queries
query 2; still undecided: 208, sample size is: 200
sending known command
Traceback (most recent call last):
File "mercurial\dispatch.pyo", line 88, in _runcatch
File "mercurial\dispatch.pyo", line 740, in _dispatch
File "mercurial\dispatch.pyo", line 514, in runcommand
File "mercurial\dispatch.pyo", line 830, in _runcommand
File "mercurial\dispatch.pyo", line 801, in checkargs
File "mercurial\dispatch.pyo", line 737, in <lambda>
File "mercurial\util.pyo", line 472, in check
File "mercurial\extensions.pyo", line 144, in wrap
File "mercurial\util.pyo", line 472, in check
File "hgext\mq.pyo", line 3528, in mqcommand
File "mercurial\util.pyo", line 472, in check
File "mercurial\commands.pyo", line 3894, in incoming
File "mercurial\hg.pyo", line 513, in incoming
File "mercurial\hg.pyo", line 472, in _incoming
File "mercurial\bundlerepo.pyo", line 342, in getremotechanges
File "mercurial\discovery.pyo", line 45, in findcommonincoming
File "mercurial\setdiscovery.pyo", line 184, in findcommonheads
File "mercurial\wireproto.pyo", line 116, in plain
File "mercurial\wireproto.pyo", line 164, in _submitone
File "mercurial\httppeer.pyo", line 170, in _call
File "mercurial\httppeer.pyo", line 118, in _callstream
File "urllib2.pyo", line 406, in open
File "urllib2.pyo", line 519, in http_response
File "urllib2.pyo", line 444, in error
File "urllib2.pyo", line 378, in _call_chain
File "urllib2.pyo", line 527, in http_error_default
HTTPError: HTTP Error 400: Bad Request
abort: HTTP Error 400: Bad Request
As I said earlier, I can do a clone, but if I try to run incoming, outgoing, pull, or push, I get this error.
I was able to resolve this issue by running
hg rollback
Once I ran that, it uncommitted my files (but kept the changes, so I could see the modified files in hg status). I was then able to run incoming and pull. Then I re-committed my code and pushed it out without any problems.
So something must be getting corrupted when I commit, just not sure why.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With