Hg4J: Mercurial pure Java library

Matt Mackall mpm at selenic.com
Thu Mar 17 14:54:26 CDT 2011


On Thu, 2011-03-17 at 18:55 +0100, Martin Geisler wrote:
> Adrian Buehlmann <adrian at cadifra.com> writes:
> 
> > There are basically two camps of people. People like Martin, who think
> > they can circumvent the GPL by looking at the original Python code to
> > see how Mercurial works and then write a new Mercurial (or parts of
> > it) in a different programming language, claiming it can then be under
> > a different license of their choice, in particular a license which
> > lifts all those ugly constraints they don't like.
> 
> Googling a little suggests that algorithms (the idea) are not
> copyrightable in their own right -- the implementation is. So I do
> actually believe, that if people start from scratch and reimplement
> Mercurial without reusing your creative variable and class names, then
> they have the copyright over the reimplementation.
> 
> > And there are others (like myself) who think such a thing might be a
> > derived work.
> >
> > Ultimately, this can only be decided in court.
> 
> Nonsense -- you can decide it right here by saying "hey, cool that you
> took the time to reimplement our tool in Java!" and acknowledging that
> you welcome the port and wont try to battle this out in court.

Let's look at a few hypotheticals:

---

#1:
If someone showed up tomorrow with something called UltraHg that was
proprietary and advertised as faster and perfectly compatible, you can
expect I'd be more than a little annoyed.

Such a project has more than likely taken great advantage of the
openness of our project to make something intended to eclipse it.

If it's a Python app that borrows code directly (and just scratches our
names off), it's pretty cut and dry: they've violated our license and
I'm going to ask them very nicely to change their license to the GPL
(and ask them to correct their plagiarism too).

If it's, for instance, a C app that's clearly been 'transliterated' from
Python, then there's very good reason to think it's in violation still,
just as translations of books are obviously 'derived works'. I'd
probably ask the folks at the Software Freedom Law Center to have a
conversation with the UltraHg folks if they insisted this wasn't
copying.

There are a lot of shades of gray beyond that, but the ONLY iron-clad
defense against a derived work claim that I know of is a clean-room
reverse-engineering approach.

#2:
Someone shows up tomorrow with something called SuperHg that's just like
UltraHg but released under a BSD-like license.

Despite being free software, this is actually exactly as problematic to
me as the UltraHg scenario, as the UltraHg people can come along the
very next day and package up SuperHg as UltraHg. This is why I've
explicitly chosen a license for Mercurial that ensures that all
derivatives of Mercurial would _always_ be free software.

#3:
Someone shows up tomorrow with something called BetterHg that's just
like SuperHg, but released under a GPL license.

No problem, right? Well, actually no. This is what's known as a 'fork',
and the very last person you can expect to be happy about it is the
creator of the original project. To the extent that they both develop in
parallel, users and developers of both are likely to suffer
incompatibility headaches. It also threatens to split developer
resources between the two projects, etc. And brokenness in BetterHg
might reflect very badly on Mercurial, for instance by corrupting shared
repos.

---

Now back in the real world:

A project shows up that claims to duplicate a lot of Mercurial's
functionality.

It's released under a GPLv2 license. Ok, fine, but I can't say I'm
excited about it, as it reminds me of all the problems of scenario #3. 

But it's also reportedly available under a commercial license. That's
beginning to look a bit like scenario #1, which I really don't like.

I don't really have an opinion on Hg4J in particular, but I think it's
only fair to warn anyone that is doing anything that looks like scenario
#1 or #2 (and anyone who might imitate them!) that they may be on thin
ice legally AND they may not be making fans, which is not a good
combination.

-- 
Mathematics is the supreme nostalgia of our time.




More information about the Mercurial mailing list