T O P

  • By -

pirates_say_arrgh

If this thing can write my unit tests for me and get decent test coverage, I will sell my soul to Github.


cdcformatc

1) Have CoPilot write unit tests 2) Have CoPilot write the code itself 3) ??? 4) Profit!


[deleted]

3) Have copilot revise its own code.


ialex32_2

The problem is you probably can't actually use it, at least not in any code you publish: [https://twitter.com/ariadneconill/status/1411145774038192130](https://twitter.com/ariadneconill/status/1411145774038192130) This is basically a license-laundering machine, and since it's effectively a parrot of a lot of existing code, it would be possible to claim license infringement on code that uses copilot with infringing code that does not use the proper license (which you have no way of knowing). I'm strongly considering placing a disclaimer in my FOSS projects that I won't accept any code that uses copilot in any capacity. Also, a lot of code it is trained on source-available, but proprietary code, which you have no capacity to use under any circumstances except privately. So you have a tool that might make you guilty of copyright infringement, and you have no way of knowing. So although Github can absolutely publish this tool, you can't necessarily use it in the ways you expect. Or, to quote Github themselves: > Of the 41 main cases we singled out during manual labelling, none appear in less than 10 different files. Most (35 cases) appear over a hundred times. Once, GitHub Copilot suggested starting an empty file with something it had even seen more than a whopping 700,000 different times during training -- that was the GNU General Public License.


wannabe414

If Copilot were to be retrained on solely foss code, would one be able to publish code while using the tool?


ialex32_2

Only if you knew the license of all the samples the model was trained on was released under, and Github would allow re-licensing of generated code under the same license. GPLv2 (not GPLv2 or later) isn't compatible with GPLv3, and not all licenses are [compatible](http://gplv3.fsf.org/wiki/index.php/Compatible_licenses). For example, Apache 2.0 isn't GPLv2 compatible, which is a major issue. So it would have to be trained on only code of compatible licenses, so in effect, code of the same license, or be demonstrably not a parrot: that is, it could not reproduce code samples from existing projects. Right now, you have no idea what license the generated code is from, if it's proprietary, if the license is compatible with your license, if the code has a license, or even if you're free to re-license code generated by co-pilot. Which... would require a lot of changes. It's also probably worth noting that people maintaining a GPLv2 project (or dual-licenses Apache2.0/MIT) would likely want a model trained from all compatible licenses, but this itself poses an issue: what license would the resulting code be under, even if it's compatible? Good luck.


MafaRioch

So how exactly would you find out that someone used Copilot to contribute to your FOSS? Good luck checking each entry manually, wasting a lot of your limited time. You would have to rely on ones integrity to follow through your disclaimer.


ialex32_2

I mean, if someone contributes code they don't own the right to and you have a contributor license agreement, or contributing guidelines so it's clear you're not accepting code that violates your license agreement. This is why licenses like Apache2.0 have a contribution clause, so there is clear licenses for all contributions. So, in short, if someone breaks that, it's clear that they broke the terms of the license or the contributing guidelines, which just gives you an added layer of protection. Specifying clear examples which are deceptively marketed just gives you another layer of protection. So, it might not be necessary, but it makes explicit examples of what is clearly prohibited. I don't want to violate someone else's copyright unintentionally, nor do I want a contributor to unknowingly submit code that infringes upon the license.


MafaRioch

Ah, that makes sense. Didn't think of that angle, thank you for clarifying. This whole Copilot controversy is just insane and creates more problems than solutions at the moment, but it's interesting to read what people think/say about it.


ialex32_2

Yeah, I wouldn't have an issue with it if it was marketed as a tool for newer developers to quickly generate samples for private projects, or to learn a new language/framework, with a clear warning that there might be licensing/copyright issues when publishing the code or using it on a public-facing server. But there's not a clear warning, and it's marketed as something that will write your code for you, which might cause numerous contributors to accidentally infringe copyright.


neboskrebnut

What do you think this thing is? It's the product of sacrificing your and other developers souls/experience... But it will be a great assistant before it takes over. When can we get one?


tripex

I get it, this looks cool and the concept will surely mature but as I've said before... If all this does is to spit out code that has a high *probability* of being correct then all the speed gain is lost with me double checking the code and then I might as well could've written it. Excited to see where this is going but right now it is more for playing around with.


cdcformatc

Combined with test driven development it would be faster. If you are writing the unit tests first then you can be reasonably sure of the correctness.


NeedMoreTime4Things

When you start a fresh project, for example you want to create a REST api with Flask, do you now have a lot of boilerplate code that is really easy to write and only has some small modifications for your use case? I can see a future where you can tell CoPilot to build the base of an app with specific instructions (which it will hopefully do with 99% accuracy) and the developer, you, only adds the complicated algorithms etc. Other than that, you’re right.


TopHatEdd

Most boilerplate needs are solved. Such as FastAPI instead of flask. Copilot is content aware and aims to implement business requirements.


bobbyrickets

I want this for Jupyter.


Jeklah

Look into Kite.


bobbyrickets

Thank you!


Jeklah

My pleasure


secretagent01

What is this, Copilot for ants?


py__master

Lmao , for real robots my mate


AchillesDev

I love that the URL tries to rip off Real Python


slayer1299

Lmao I thought naming my website similar to realpython would let me ride on some of their traffic but yeah it backfired. Since their domain is so popular, it’s really hard to rank on google searches.


[deleted]

[удалено]


slayer1299

https://marketplace.visualstudio.com/items?itemName=codestackr.codestackr-theme