They are doing this to make sure that any lawsuit can be easily dismissed. It has nothing to do with the legality of the action (which sounds like fair use as the parent described it), and everything to do with the expense of a potential lawsuit compared to the cost effectiveness of simply telling developers “don’t do that”.
Most people think that the law has two shades: lawful vs unlawful. But the more practical distinction is expensive lawsuit vs dismissed lawsuit. This is the lens through which corporate lawyers see copyright and it might explain why so many programmers think that copilot is “obviously” breaking the law and “stealing” their code.
Questions of derivative works and fair use come up fairly frequently even in the open source world. This isn't solely a question of corporate lawyer posturing. I don't know any copyleft authors that would be okay with someone copying & pasting their code, making trivial changes, and saying it isn't a derivative work. Of course, their understanding of the law may be flawed. You'll get to find out in court.
You're right. A lot of this boils down to how much you want to spend in court proving your usage is just under fair use. We've moved beyond the question of ethics if you're intentionally violating a project's source license and relying on fair use to do whatever you want with the code. If you want to poke someone with a stick, you can't be surprised when they hit back. I contend what the OP described isn't clearly fair use (note I'm not saying that it clearly isn't fair use either). It ultimately doesn't impact me because I'm just not going to copy & paste code from projects without attribution and following the license, but I'd be worried about anyone reading that comment as objectively true.
Courts have held that it doesn't apply to music, why do you think different rules apply to code?
Songs are different from code, in that the “hook” that makes the money may be only a few seconds long. There are many creative choices that a songwriter/producer can fit into just a few seconds: the harmony, melody, rhythm, lyrics, timbre, effects, ...
Whereas for code, the space of creativity is limited by functional considerations. A creative choice is protected by copyright but not all choices that programmers make are creative. Often the choices are limited by the API/interface or by efficiency considerations and it turns out that there’s only one good way to do something.
A function may be very intricate, yes, while still containing almost no creative value (e.g. a Vulkan setup function). Music doesn’t have an equivalent to this - the placement of every note is a creative act.
Yes, I too, and probably many people will do.
> In fact sometimes I copy and paste short passages and then rework them.
This I usually don't unless I check the license first. (Everybody ought to be allowed, but sometimes the license might not be.)
It reminds me of the Google vs Oracle case. Apparently a court found that copying even a small amount of code in breach of its licence is not permitted. [0]
[0] https://en.wikipedia.org/wiki/Google_LLC_v._Oracle_America,_.... (ctrl-f for de minimis)
On the other hand, if you copy from private repositories, it quickly gets into the territory of stealing trade secrets.
"Microsoft does it, therefore it must be right" does not a sound argument make.
No, businesses are — not business. Not necessarily...
Also, the open source community has far less leverage to apply pressure to Google than it does to GitHub. We may be able to do something about this.
The whole point of fair use is that the license doesn't matter. You can have a license that says I'm not allowed to use what you wrote for any purpose ever and I can still use it under fair use.
That said, copilot itself is not a replacement for your open source project that it was trained on. The code it generates may or may not be, but that's probably not Github's problem as far as copyright law is concerned.
I don't really think this argument passes muster.
It's just automating the copying and pasting (and slight reworking) of boilerplate code that would normally take me much longer to do, especially when I am working with a language I'm less familiar with but is necessary for my stack. I've literally never seen it suggest code that is more or less almost exactly what I would have come up with given a lot more time. In essence, it eliminates tedium- exactly the point of all of programming: Work elimination.
I have two questions:
1. Why have licenses, then?
2. What if I just use leaked sources of closed source software and call it fair use?
The default under copyright law is that any substantial copy is infringement.
A license is a legal document that grants someone permission to use a work that they otherwise would not have had.
However the law also gives its own permissions to use a work - it defines what is unlawful infringement and what is lawful fair use.
The code snippets that copilot generates look more like fair use than infringement. They are small, adapted to the destination context, and usually not direct copies of one source but more of an average of many different sources. And usually the programmer does not keep the suggestion that copilot suggests unmodified - the programmer does their own editing of the snippet afterwards to further tune it to the surrounding context.
2. What if I just use leaked sources of closed source software and call it fair use?
As pointed out upthread, if it the source code is leaked then there may be trade secret protections. The GPL specifically allows the code to be posted online, so by design it is not secret.
The reverse maybe true. I may be GPL'ing a code to prevent a useful algorithm from being buried deep inside a commercial code with an incompatible license. What makes it a "trade secret" level code? I have a 25 line algorithm which is worthy of its own paper. What if I open its reference implementation with AGPLv3+?
I have no problems with you reading the paper, and implementing it. I don't obfuscate my papers, but I put the implementation out with AGPLv3+. You can't use that in a codebase with an incompatible license. I expect and want you respect the license of my implementation.
> The code snippets that copilot generates look more like fair use than infringement. They are small, adapted to the destination context, and usually not direct copies of one source but more of an average of many different sources. And usually the programmer does not keep the suggestion that copilot suggests unmodified - the programmer does their own editing of the snippet afterwards to further tune it to the surrounding context.
Emphasis mine. First, there's no consensus on fair use, yet. Second they may be direct copies of the code. Third, they're remixed with other code pieces, which makes it a derivative work of many code pieces at once, then lastly, programmer re-derives the derived work. Which is clearly a derivative of GPL code, which brings in GPL license with itself (if what copilot derives the code from GPL licensed repositories, which it does).
I have no problem with Copilot as a technology. I have no problems with other licenses, which are not breached when used by Copilot and derived and used. The point which makes my blood boil is copilot using this GPL corpus, and don't admitting it publicly, breaching the terms of GPL en masse, and outright ignoring it. Then feeding this GPL derived code to any and all projects which pay for a copilot membership, and calling it a day.
I do think there are ethical questions around whether it's right for google to digitise physical books without the permission of the authors, and keep them on their servers and make money from them without recompensing the authors. That's something an individual would not get away with doing, so it seems wrong that it's OK for google.
The SCO vs IBM lawsuit was over only a few lines of code, after all.
I cant use a derivative of Mickey Mouse in my product, even if I change his colour and give him a hat, even if these changes were made by an AI. Why would it be different for code? I cab only use Mickey Mouse as fair use if its done for a specific barrow set of proposes (satire, news reporting etc).
There are just minor deviances, not relevant to this case, such as how long Disney bullied the countries to protect a work.
Software is usually considered a work. The AI needs to know if has permissions to copy and use the code, and then offer derived work on the proper terms and conditions. copilot doesn't do that. It might copy GPL code into non-GPL code, thus violating the GPL license, thus being an extreme risk.
In the US there have only been two extensions of copyright terms since Disney came into existence.
The first was in 1976, as part of a major overhaul of US copyright law to update the previous law (from 1909) to take into account the large changes in technology since then, and to make US law work more like the rest of the world to pave the way for the US later joining the Berne Convention. The changes for Berne compatibility included longer terms.
I assume Disney did support this, but only because as far as I can tell it had pretty widespread support. It had enough support that it would have passed even if Disney had adamantly opposed it.
The second was in 1998, and that was specifically a term expansion (as opposed to a term expansion like that of 1976 that was a side effect of harmonizing US law with the rest of the world). Europe had expanded terms a few years earlier, so the 1998 change in the US might have been motivated at least in part by harmonization, but I don't think the differences in terms between the US and the EU would have been enough to get it passed without some major interests pushing for it, so it is probably fair to give Disney a good part of the credit or blame for this one.
Here you see the countries which did not extend it the 2nd time to 70 years. https://en.wikipedia.org/wiki/List_of_countries%27_copyright...
There was of course no widespread support for these extensions, as all its arguments were flawed and not only violated logic but also several constitutions. https://de.wikipedia.org/wiki/Copyright_Term_Extension_Act#G... (the en version is mostly cleaned on these counter arguments)
Is fair use on a massive scale still fair use? Courts generally think so, otherwise Google would have been out of business a long time ago.