Live data from Hacker News

GitHub Copilot available for JetBrains and Neovim

github.com

151–160 of 446 posts

Re: GitHub Copilot available for JetBrains and Neovim

#151
post #94
post #72

Earlier quoted context omitted.

The example i usually give [1] in javascript is say you have function (x,y) => x + y Orgs targeting code coverage write a test for 1,2 => 3 and get 100% coverage and then stop as there is no incentive to go further. They don't write tests for say (1,null) (null,null) ('x',1) (NaN, Infinity) and so on.. these additional tests will improve coverage of scenarios and code coverage will not move. I have seen projects wher…

So one argument against code coverage requirements is that poor engineers won't test correctly. Without the code coverage requirements you're in the same situation.

Problem is with 100% code coverage of badly guarded / implemented code you'll have a fall sense of security if you're just looking at coverage as the metric of quality. Anytime I've worked with a company who had a required code coverage percent, they never actually cared what the code being covered looked like only that it was covered in some test.

Re: GitHub Copilot available for JetBrains and Neovim

#154
post #76

Copilot is crazy. The other day, I was writing a Python function that would call a Wikipedia API. I pulled from the internet an example of a GET request, and pasted it as a comment in my code. # sample call: https://en.wikipedia.org/w/api.php?action=query&format=json&list=geosearch&gscoord=37.7891838%7C-122.4033522&gsradius=10000&gslimit=100 Then I defined a variable, base_url = "https://en.wikipedia.org/w/api.php?"…

Bit of a dodgy way to form query parameters though. Other than for a quick script.

Even for a quick script this worries me about copilot; if it suggests this, then more people use it and think this is right, commit it, and then copilot suggests this more - that’s a bad feedback loop. At least in StackOverflow you get someone commenting why it’s bad and showing how to use a dictionary instead

Re: GitHub Copilot available for JetBrains and Neovim

#155

I have a few questions about copilot. I haven’t gotten a chance to use it yet. Is it irrational that this makes me a little anxious about job security over the longterm? Idk why but this was my initial reaction when learning about this. Given the scenario where copilot and its likes becomes used in a widespread manner. Can it be argued that this might improve productivity but stifle innovation? Im pretty early in my…

You should only be worried if you just copy and paste boilerplate between files. If you're actually able to solve problems and design things there's nothing to be worried about

Re: GitHub Copilot available for JetBrains and Neovim

#156
post #29

How well can copilot write unit tests? This seems like an area where it could be really useful and actually improve software development practices.

Writing tests for the sake of coverage is already practically useless which is what a lot of orgs do, This could maybe generate such tests. However it doesn't materially impact quality now, so not much difference if automated. One of the main value props for writing meaningful unit tests, is it helps the developer think differently about the code he is writing tests for, and that improves quality of the code composit…

I've found that for large codebases of dynamic typed interpreted languages Test Coverage is very useful at preventing typos or subtle bugs that wouldn't be caught otherwise.

Re: GitHub Copilot available for JetBrains and Neovim

#157

Anyone know how long the waitlist is?

I joined the waitlist at the end of June and got an invite yesterday. So 4 months?

However, I imagine a lot of people signed up just before me, so I was probably at the end of a long list. The wait wouldn't be this long if you sign up today, I reckon. I'm just guessing though.

Re: GitHub Copilot available for JetBrains and Neovim

#158
post #130

the fact that most of Co-Pilot's usefulness comes from repeating common snippets of code makes me think there has to be a much simpler way to reduce the boilerplate of "common tasks"

In my opinion, dependent type systems are that way.

A dependent type is a type that depends on a value. What something is depends on something else; What something is is derived from something else – with computation. What dependent types are are calculations of type structure.

Unbounded, this becomes intractable like all unbounded computational expressivity. So that’s what modern dependent type systems need to solve—and they do. There exist formal results that frame the computational expressivity of dependent type systems and make perfectly feasible and tractable the task of deriving significantly complex types. Automatically.

The Idris language is a great example of where we’re heading.

The reason I’m more interested in this sort of thing rather than Copilot is that dependent type systems are based on formally rigorous methods. You end up with formally verified programs, by way of the same mechanisms that allow you to derive them automatically. They’re also easier to compose, for the same reasons.

Edwin Brady’s Idris demonstratons on Youtube show a bit of what’s possible. In one, the compiler automatically writes a formally-correct type-directed matrix multiplication function. In another, run-length encoding and decoding functions are generated from a type definition.

The book Type-Driven Development with Idris is a great read. Mind-expanding.

Programming is automation. The automation of automation is… dependent types.

Re: GitHub Copilot available for JetBrains and Neovim

#159
post #130

the fact that most of Co-Pilot's usefulness comes from repeating common snippets of code makes me think there has to be a much simpler way to reduce the boilerplate of "common tasks"

Why? I haven't used it but it seems like the only reason it is good at repeating common snippets of code is because it is so clever. I don't think a simpler solution would be possible because it isn't exactly repeating code (except in contrived examples). It's adapting it to the context.

Re: GitHub Copilot available for JetBrains and Neovim

#160

Wait, they got Tim Pope on the case for the Neovim plugin? Amazing, I'm positive it'll work beautifully. For those who don't know, he's essentially the godfather of vim plugins - I even have an entire 'tpope section' in my init.vim

Haha, I mean, tpope has been working on vim plugins since 2005/2006 from my IRC memories, but there were vim plugins before that too.
Post reply on HN