Live data from Hacker News

StackOverflow Importer – Import code from Stack Overflow as Python modules

github.com

61–70 of 87 posts

Re: StackOverflow Importer – Import code from Stack Overflow as Python modules

#61
post #39

This might be a joke but everybody does it manually for real. Whenever I copy-paste some tricky function from SO I like to add a code comment with the url pointing to the stackoverflow.com answer. This allows future maintainers to refer back to SO and see if a better answer has surfaced or read comments about any issues.

I never, ever copy paste code, unless it's really long. I always end up rewriting everything myself, so I have the time to think about what's happening.

Re: StackOverflow Importer – Import code from Stack Overflow as Python modules

#63
post #49
post #28

Earlier quoted context omitted.

Edits get reviewed before being published.

No they don't. From http://stackoverflow.com/help/privileges/edit > We believe in the power of community editing. That means once you've generated enough reputation, we trust you to edit anything in the system without it going through peer review. Not just your posts—anyone's posts!

If you've been on Stack Overflow enough, you might have noticed that crap is sometimes approved even after peer-review. Many doing the review do it like robots (to earn internet reputation and badges).

Re: StackOverflow Importer – Import code from Stack Overflow as Python modules

#64

This is a really stupid idea, even as a joke to play with. Someone can just edit the top answer to make it malicious and steal your personal or work data from your workstation.

Someone stupid enough to actually use this in a serious environment arguably deserves it.

Re: StackOverflow Importer – Import code from Stack Overflow as Python modules

#66

It's interesting to imagine adding something like this to an editors auto complete or as some kind of search function to automate functions you've coded a million times. I.e. maybe you type: "repeat a function over a list python" in a special format and your editor pastes in the accepted answer from stackoverflow for you to choose whether that's acceptable / whether you want to use it as a template. Then maybe you co…

There is something like that for JavaScript https://emilschutte.com/stackoverflow-autocomplete/

Re: StackOverflow Importer – Import code from Stack Overflow as Python modules

#70

This is a really stupid idea, even as a joke to play with. Someone can just edit the top answer to make it malicious and steal your personal or work data from your workstation.

and then own your network, your DVR, your toaster, your cat.

Please leave the cat!
Post reply on HN