Live data from Hacker News

GitHub Copilot

copilot.github.com

241–250 of 1001 posts

Re: GitHub Copilot

#241
I don't understand fascination with bullshit machines.

While they may be useful in propaganda, state or commercial, I'm not sure why Microsoft GitHub would find it useful to generate volumes of bullshit source code.

Re: GitHub Copilot

#242
post #88

Calling it now, there will be a "Copilot considered harmful" post. If you need to go through the suggested code to ensure it's correct, you may as well write it yourself? If you glance at it and it looks about right, you can potentially overlook bugs or edge cases, you'll lose confidence in your own code since you didn't properly conceptualise it yourself. Potentially for newer developers it robs them of active exper…

> If you need to go through the suggested code to ensure it's correct, you may as well write it yourself? Not really. People are generally far faster at reading something and evaluating whether it's correct, than at writing something. In the same way it's faster to read a book than to write one. Not to mention the time it takes typing, fixing typos, etc. So this could genuinely be a huge timesaver if it helpful enoug…

I’m going to pile on the disagree train. My experience is that developers find (other people’s) code much harder to read. I suspect this tool will lead to code with subtle problems because people will skim it, shrug “eh, looks about right,” and move on.

Edit: In fact, people in this thread are finding exactly those problems in the example code, which you would assume had been checked fairly carefully.

Re: GitHub Copilot

#243

I've been using the alpha for the past 2 weeks, and I'm blown away. Copilot guesses the exact code I want to write about one in ten times, and the rest of the time it suggests something rather good, or completely off. But when it guesses right, it feels like it's reading my mind. It's really like pair programming, even though I'm coding alone. I have a better understanding of my own code, and I tend to give better na…

What's your estimate of the productivity boost expressed as a percentage? I.e. if it takes you 100 hours to complete a project without Copilot, how many hours will it be with Copilot?

Re: GitHub Copilot

#244
Plenty of discussion about the IP issues. It makes me want to start adding a section in my LICENSE.txt that says it's not eligible for use training commercial models. We'll likely end up with a whole set of license choices for that.

Although if a license can permit or prohibit use in training commercial models, does that mean that the lack of permission implies a prohibition on it?

Re: GitHub Copilot

#245

Earlier quoted context omitted.

This is obviously controversial, since we are thinking about how this could displace a large portion of developers. How do you see Copilot being more augmentative than disruptive to the developer ecosystem? Also, how you see it different from regular code completion tools like tabnine.

How many jobs have developers helped displace in business and industry? I don't think it's controversial that we become fair game for that same automation process we've been leading.

Nothing is inevitable. Doctors and lawyers have protected their professions successfully for centuries.

Only some software developers seem interested in replacing themselves in order to enrich their corporate masters (mains?) even further.

Just don't use this tool!

Re: GitHub Copilot

#246
One of the examples they provide on copilot.github.com shows a unit test for strip_suffix function. It does not test for a file name without a suffix, which the function would fail (it removes the last character instead):

    def strip_suffix(filename):
        """
        Removes the suffix from a filename
        """
        return filename[:filename.rfind('.')]

    import unittest

    def test_strip_suffix():
        """
        Tests for the strip_suffix function
        """
        assert strip_suffix('notes.txt') == 'notes'
        assert strip_suffix('notes.txt.gz') == 'notes.txt'

Re: GitHub Copilot

#247
post #211

Earlier quoted context omitted.

What do you think about this being overall detrimental to code quality as it allows people to just blindly accept completions without really understanding the generated code. Similar to copy-and-paste coding. The first example parse_expenses.py uses a float for currency - that seems to be a pretty big error that's being overlooked along with other minor issues around no error handling. I would say the quality of the…

Why would you say it's an error to use a float for currency? I would imagine it's better to use a float for calculations then round when you need to report a value rather than accumulate a bunch of rounding errors while doing computations.

micro-dollars are a better way of representing it (multiply by 10e6); store as bigint.

See: https://stackoverflow.com/a/51238749

Re: GitHub Copilot

#248
post #211

Earlier quoted context omitted.

What do you think about this being overall detrimental to code quality as it allows people to just blindly accept completions without really understanding the generated code. Similar to copy-and-paste coding. The first example parse_expenses.py uses a float for currency - that seems to be a pretty big error that's being overlooked along with other minor issues around no error handling. I would say the quality of the…

Why would you say it's an error to use a float for currency? I would imagine it's better to use a float for calculations then round when you need to report a value rather than accumulate a bunch of rounding errors while doing computations.

Standard floats cannot represent very common numbers such as 0.1 exactly so they are generally disfavored for financial calculations where an approximated result is often unacceptable.

> For example, the non-representability of 0.1 and 0.01 (in binary) means that the result of attempting to square 0.1 is neither 0.01 nor the representable number closest to it.

https://en.wikipedia.org/wiki/Floating-point_arithmetic#Accu...

Re: GitHub Copilot

#249
Brilliant.

I remember over a decade ago seeing a grad student project with a very straightforward and very clever idea: extending JavaDocs based on code snippets of actual use (to address the common pattern problem in Java code that you often get an instance of an object not by direct construction, but by calling a factory function or singleton getter somewhere). Kicking myself that I didn't see this day coming.

Re: GitHub Copilot

#250
post #167

Earlier quoted context omitted.

We think that software development is entering its third wave of productivity change. The first was the creation of tools like compilers, debuggers, garbage collectors, and languages that made developers more productive. The second was open source where a global community of developers came together to build on each other's work. The third revolution will be the use of AI in coding. The problems we spend our days sol…

Let's solve the problem of replacing CEOs next. The above paragraph could have been written by GPT-3 already.

LOL. But you actually make a good point here. GPT-3 can replace most comms / PR type jobs since they all sound like Exec-speak.
Post reply on HN