TotoiseHG: existing connection was forcibly closed by the remote host

I wanted to push a project from TortoiseHg to GitHub . I know that TortoiseHg is the interface for the Mercurial distributed version control system; where github works with git. But I like to use TortoiseHg (instead of TortoiseGit or GitGui) and want to save my project in GitHub.

So, I set up TortoiseHg (File> Settings> Extensions> hggit) and was able to push the test project to GitHub (after this wonderful blog). But later, when I tried to shift the C # MVC project with him, the situation changed. It starts pushing nicely, then asks for authentication, and then shows this error -

An existing connection was forcibly closed by the remote host.

Here is what the magazine shows -

% hg push git+https://github.com/MinhasKamal/MVCPracticeWork pushing to git+https://github.com/MinhasKamal/MVCPracticeWork http authorization required for https://github.com/MinhasKamal/MVCPracticeWork/info/refs realm: GitHub searching for changes adding objects URLError: [Errno 10054] An existing connection was forcibly closed by the remote host [command returned code 255 Thu Feb 04 16:17:02 2016] 

I do not understand why this error occurs. Is this a GitHub or TortoiseHG issue, or did I do something wrong? How can this be solved?


Edit 1: I can click on the repository, but only by โ€œnot addingโ€ some specific directories to my repository . Is this any type of file or name that makes this error?


Edit 2: The problem happened to me again, this time with a Java project. Everything was fine until I added the * .jar file to the repository. I made a commit, but when I tried to push it on GitHub, TortoiseHg showed me the same message. I deleted * .jar, did and tried to click again, but could not.

Now I did it again (Edit 1) - I pulled the entire repository from GitHub to another folder, replaced the changed files from the current repository on my PC (did not add * .jar), committed, and pushed; This time I was successful. So this time, the * jar file was not added to the version control database, so it worked.

+5
source share
4 answers

So far, after many comments, it seems that some types of binary files (e.g. * .jar, * .mp3, etc., but not * .png) are problematic:

  • Not the file size (although the file is really large , this will also be a problem, but it is not here)
  • not its extension (adds OP "I had a photo and I renamed it *.jar and it worked")

To preserve similar end-user experience, the test should be to install TortoiseGit and see if pressing git will work in the classic git cloning repository.

+2
source
  • I do not see any clicks on MinhasKamal/MVCPracticeWork : This repository is empty.
  • You can automate the pushing process (without manual labor, without timeouts, without input errors) using the [auth] section in the .hgrc of this repo (define the username and password in it)
  • At least some initial test clicks will perform better in a pure CLI (more informative and readable output).
+2
source

There is a problem with Github if you are trying to add a super large file to any repo. Although I do not know if this was a problem.

I had a change to commit with both HG and Git on my Mac and try to push it on github. Git showed me that the file was too large when I ran git push , but HG only showed that the click failed.

If your .jar or any file you added caused a problem, you can check if the file size exceeds the limit (from github) and this

+2
source

This problem only occurs when using the HTTPS protocol. If you use SSH instead (which is inconvenient, but nevertheless possible on Windows), then the click will succeed.

See https://www.mercurial-scm.org/pipermail/mercurial/2017-March/050304.html for more details. I suggest reading the entire stream, only six posts.

+1
source

Source: https://habr.com/ru/post/1242285/


All Articles