Github - Mercurial Mirror

As you know MonetDB is developed using mercurial. You can find the official repository here. We use git-remote-hg, a local git repository and some scripts to mirror MonetDB’s source code on github. ​ The github mirror stopped updating on June 12. This is something that has happened in the past, when people by mistake made or pushed commits directly on github. In these cases the fix was usually simple: merge the commits from github into the local repository and push them back to mercurial. ​ This time the issue was more serious. The first clue was that there were no extra commits in github. The second and much more serious clue was that mercurial was crashing when it was trying to get new commits from upstream. ​ We tried running git gc and git hg gc <remote> as per the instructions in git-remote-hg’s readme, because MonetDB’s mercurial history is pretty large (about 75K commits in the default branch since July 2000). This did help but we ended up with different SHA-1 hashes for many commits in the last two years. In fact the first commit that was different was one that was done on github and was back-ported to mercurial. ​ We spent a lot of effort trying to reconcile the two histories but ultimately we were not willing to push about 9K duplicate commits on the default branch in the mercurial repository. The final fix is that we force pushed the “correct” history to gitub. All the branches that existed before this change are saved using the prefix old-history. ​ We are making some changes in order to avoid having the same problem in the future. The most important is a policy change: commits directly to github are no longer acceptable. This means that in case a commit like that happens in the future and we are unable to update the mirror, they will be discarded by force pushing the history from mercurial.