27

I work on a large software team and everyone says I shouldn't do "Stack Overflow driven development". I often consult this site to check on how to solve software engineering problems.

What does "Stack Overflow driven development" mean, and should I use it in my day to day programming? Is it a design pattern?

7
  • 3
    In my opinion, to a certain extent StackOverflow can be a good place to learn, but it can't replace a teacher :-)
    – user1636522
    Jan 13, 2018 at 6:51
  • 25
    I would guess it means you come to Stack Overflow for every problem you encounter, instead of doing research on your own. And then just copy-paste whatever code you get from answers or comments. And if people write comments asking for details or to improve the question, you get angry and swear at them and rage-quit (just to register a new user immediately). Jan 13, 2018 at 6:55
  • 15
    Did you do any research before asking this question? dzone.com/articles/… Jan 13, 2018 at 6:56
  • 1
    It's a term designed to allow you to shout 'SODD OFF' to your boss when s/he tells you to look something up. Jan 14, 2018 at 13:18
  • It means you solve all problems with broken recursive code. But seriously, it is a made up term that likely refers to copy/pasting from Stack Overflow without verifying anything. It is how Stack Overflow has become a threat to the world.
    – Gimby
    Jan 15, 2018 at 8:57
  • @Gimby: I would argue that in that case the tool – Stack Overflow – is not to blame, but those naively copy-pasting inexperienced developers are. Hammer factories are not a danger, people using hammers to drive in screws are.
    – Jongware
    Apr 15, 2018 at 18:45
  • @usr2564301 Of course you're right. Yet "highly decorated papers" are starting to claim otherwise.
    – Gimby
    Apr 16, 2018 at 9:52

2 Answers 2

64

Stack Overflow driven development is when you have a problem, so you look it up on Stack Overflow. Then, when you find a relevant response, you immediately copy-and-paste without bothering to thoroughly understand the solution.

Although convenient, this practice should be avoided primarily because maintainability quickly becomes a nightmare. When you inevitably need to make modifications, you or whoever else is on the team will basically just be patching/fixing code that you don't actually understand and wasn't actually written to solve your specific issue. Typically the problem snowballs, as you will habitually force patches that may or may not work for mysterious reasons.

Sometimes it is ok to copy and paste from SO, especially for one-liners, but typically you should only do it if you are 100% clear in your understanding of the code itself. Typically I try to rewrite what I find here from scratch, and use the solutions as guides rather than complete answers.

3
  • 4
    To add to this, while many code snippets answer the specific question being asked, there is a chance that unintended side effects may come out of any code on this site. For example, we cannot guarantee that any code posted is not susceptible to a security vulnerability which, if exploited, would prove very damaging (both to firm and career).
    – Joe C
    Jan 13, 2018 at 13:47
  • 5
    And then you become a full Stack Overflow developer... Jan 14, 2018 at 20:48
  • I do the rewriting thing too :) It's a great way to ensure you know what the code is doing.
    – Lauraducky
    Apr 15, 2018 at 23:07
4

I think SO driven development is when you don't have a deep knowledge in a topic, and instead of trying to learn more, you post a question here to solve your actual problem, because it is faster and requires a lot less effort from you. In this fast-moving world even knowledge became something you can consume instantly. The only problem that this is not how things really work, and on the long run outsourcing everything to SO instead of doing your job is really counter productive.

Just a small example: I struggled to learn the REST (representational state transfer) architectural style from SO answers for 3 months until an expert linked me the Fielding dissertation in a downvoted answer. After reading the dissertation in a few hours, everything became very obvious. You might ask why was that answer downvoted, and it is very simple. It was downvoted, because nobody else took the trouble to learn it from the authentic source, so they learned it from tutorials and SO answers written by people who understood the topic just a little bit more than them. Even I downvoted and started to argue with the guy in the comments, that's how I got the link...

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .