|
Well for a start there's using a class as though it were a namespace.
|
# ? Mar 23, 2013 08:02 |
|
|
# ? May 17, 2024 17:35 |
|
Ithaqua posted:What are the horrors? All of the compiler errors, to start
|
# ? Mar 23, 2013 10:40 |
|
code:
|
# ? Mar 23, 2013 17:53 |
|
MrBadidea posted:
"Ace can be one *and* 11? What kind of God would allow that!"
|
# ? Mar 23, 2013 21:01 |
|
I'm also not quite understanding where the horrors are. "Bad" and "wrong," no question, but horrific?
|
# ? Mar 23, 2013 22:13 |
|
At my work, one of the projects I'm on is a J2EE web application where a large portion of the dev team outsourced through an Indian consulting firm. Insofar as I can tell, the servlets they pump out work fine, but I keep running across weird code in the JSPs that makes me think they don't understand how Javascript works:code:
O Tempora! O Mores! fucked around with this message at 22:34 on Mar 23, 2013 |
# ? Mar 23, 2013 22:23 |
|
GrumpyDoctor posted:I'm also not quite understanding where the horrors are. "Bad" and "wrong," no question, but horrific? Writing C in C++ is a horror.
|
# ? Mar 23, 2013 22:54 |
|
And bothering to make an enum and then having single letter names. Revolting. However I will defend the 'using a class as a namespace'. I nest enums inside classes all the time and I'm not sorry.
|
# ? Mar 23, 2013 23:41 |
|
Rottbott posted:And bothering to make an enum and then having single letter names. Revolting. In C++11, you can use enum class to force people to qualify your enumerators with the name of the enum. (It also removes the implicit conversion to the underlying integral type.)
|
# ? Mar 24, 2013 00:32 |
|
O Tempora! O Mores! posted:At my work, one of the projects I'm on is a J2EE web application where a large portion of the dev team outsourced through an Indian consulting firm. Insofar as I can tell, the servlets they pump out work fine, but I keep running across weird code in the JSPs that makes me think they don't understand how Javascript works: I'd be charitable and assume that they just made a mental error. The first time.
|
# ? Mar 24, 2013 03:08 |
|
Lumpy posted:"Ace can be one *and* 11? What kind of God would allow that!" But you'd have no way of knowing that given the way in which this was coded. Each suit in this class has 14 cards, including a 1 and an A. It really is as though the coder had never seen a deck of cards before
|
# ? Mar 24, 2013 03:44 |
|
Maybe they're just not into cards, or it's a cultural thing. Why is there no one card? It's just some weird tradition from 300 years ago. I mean you probably don't know offhand how many pits there on a mancala board either.
|
# ? Mar 24, 2013 04:14 |
|
O Tempora! O Mores! posted:At my work, one of the projects I'm on is a J2EE web application where a large portion of the dev team outsourced through an Indian consulting firm. Insofar as I can tell, the servlets they pump out work fine, but I keep running across weird code in the JSPs that makes me think they don't understand how Javascript works: Stuff like this and inescapable cargo cult programming/engineering is why I currently dread going to work every day
|
# ? Mar 24, 2013 04:34 |
|
lancemantis posted:Stuff like this and inescapable cargo cult programming/engineering is why I currently dread going to work every day Cargo cult? I've never heard that term before. Edit: I should drink less O Tempora! O Mores! fucked around with this message at 14:01 on Mar 24, 2013 |
# ? Mar 24, 2013 06:36 |
|
O Tempora! O Mores! posted:Cargo cult? I've never heard that term before. It always seems that I'm the only one who understands what's going on. Is that how it always feels in software development, or should I be tearing my coworkers apart in code reviews? "Cargo cult" is not a programming term.
|
# ? Mar 24, 2013 06:41 |
|
Hammerite posted:"Cargo cult" is not a programming term. Not originally, but it gets used a lot in programming discussions.
|
# ? Mar 24, 2013 08:06 |
|
Generally goes hand-in-hand with the Tim Buckley anti-pattern.
|
# ? Mar 24, 2013 08:40 |
|
It amusing works misinterpreted as cargo-pant cult programming. All the neo-hipsters want to wear cargo pants to be hip, and fail miserably.
|
# ? Mar 24, 2013 16:45 |
|
Just a few hours ago I heard the weirdest use. I asked about some custom logging library and got "Oh yeah, Peter cargo culted that around to all his projects". I didn't know it meant "copy/pasted".
|
# ? Mar 24, 2013 16:46 |
|
Suspicious Dish posted:Just a few hours ago I heard the weirdest use. I asked about some custom logging library and got "Oh yeah, Peter cargo culted that around to all his projects". It's more than just "copy/pasted". It's when you do something in order to fix things without actually knowing what it does. "This piece of code is a magic talisman that fixes problems and I don't know why."
|
# ? Mar 24, 2013 16:48 |
|
prefect posted:It's more than just "copy/pasted". It's when you do something in order to fix things without actually knowing what it does. "This piece of code is a magic talisman that fixes problems and I don't know why." I always use the term 'Gully Dwarf' for that from the retarded inbred fantasy race in the Dragonlance Chronicles. When the brain drain of a long running project has been so bad that not only are there no more original implementers left on the team, but those that are left for maintenance have no idea why anything does what it does, they instead wave the dead rat at the wall and push the button that opens the secret door. For me cargo cult programming is more of adapting the latest hot technology because twitter is a successful company and they use Rails, so rails makes them successful so we should use rails! (I believe this is how I wound up seeing a heterogeneous tech stack involving, netty, jetty, java, scala, nodejs, wicket, express, coffeescript, ruby, python, javascript, C, C++, Objective-C, apache, PHP, and I'm sure others that I'm just blocking now. And yes I realize I'm mixing languages, frameworks, and platforms but there's at least 2 if not 3 of each at different points in the chain.)
|
# ? Mar 24, 2013 17:10 |
|
MrMoo posted:It amusing works misinterpreted as cargo-pant cult programming. Cargo pants give you a place to put all of your things and there is nothing wrong with that
|
# ? Mar 24, 2013 17:29 |
|
prefect posted:It's more than just "copy/pasted". It's when you do something in order to fix things without actually knowing what it does. "This piece of code is a magic talisman that fixes problems and I don't know why." OK, then this guy was using it wrong, maybe? He just meant some standard logging code that Peter copy/pasted from project to project. Peter fully wrote it, so he fully understood how it works.
|
# ? Mar 24, 2013 17:32 |
|
"Cargo cult" means to confuse the outwards manifestations of something with its essence. The original cargo cults copied the outward manifestations of military supply networks (landing strips, aircraft, radios) not recognizing that those things don't work without an actual network to produce and deliver the cargo. Creationist science is cargo cult science because it copies the outward manifestations of scientific research (papers, journals, conferences, "universities") with the actual essence of what makes up science. In programming, cargo culting is using some technique, design pattern or style where it's inappropriate because one doesn't understand the motivation for its use in the first place. Like creating an unnecessary inheritance hierarchy because in school they told you that's how you do OOP. Or when I see a class where every private member has been exposed through getters and setters.
|
# ? Mar 24, 2013 19:16 |
|
Or not taking the time to understand how a framework/library works and just copy/pasting something else that is using it as part of an implementation and tweaking stuff to try to make it 'work'. Then when it doesn't work asking questions that make the person on the receiving end of the questions feel like they're on a bad mailing list. It gets even worse when they copy some messy hack or some rushed, unclean section and when they're informed that they can implement their particular item in a much simpler way they continue with the hack to 'see if they can just get it working this way.' I think 'J2EE' just aggravated this problem by sometimes requiring a good chunk of boilerplate so a bunch of guys now think this is what writing software is.
|
# ? Mar 24, 2013 19:34 |
|
HappyHippo posted:Creationist science is cargo cult science because it copies the outward manifestations of scientific research (papers, journals, conferences, "universities") with the actual essence of what makes up science. Creationist "science" isn't really cargo cult science, because the goal isn't to try to duplicate scientific study and discourse; the goal is to create a thin veneer of credibility which they can lay on top of the Bible to say "there is controversy about evolution and the origins of the universe, therefore we should not teach evolution in schools." Cargo cults are fundamentally about not understanding how something works, and trying to reproduce behaviors by rote ritual. Creationist "science" is fundamentally about lying to people, a lot, for political gain.
|
# ? Mar 24, 2013 19:40 |
|
Coding horrors: post the code that makes you laugh (or cry)
|
# ? Mar 24, 2013 19:41 |
|
Volmarias posted:Creationist "science" isn't really cargo cult science, because the goal isn't to try to duplicate scientific study and discourse; the goal is to create a thin veneer of credibility which they can lay on top of the Bible to say "there is controversy about evolution and the origins of the universe, therefore we should not teach evolution in schools." Yeah fair enough. I still think it's a cargo cult because what they seek is the credibility of science and if you read the wedge document you can tell they somehow feel it comes from the papers and conferences.
|
# ? Mar 24, 2013 20:11 |
|
HappyHippo posted:Yeah fair enough. I still think it's a cargo cult because what they seek is the credibility of science and if you read the wedge document you can tell they somehow feel it comes from the papers and conferences. But that's not what cargo cult is at all. Cargo cult is seeing X cause Y, and then trying to do X a lot hoping it will do Y, such as Pacific island tribes making dirt airfields because they think it will make aircraft come without understanding or knowing WHY aircraft come. Creation science is trying to dress up the Bible in trappings of scientific rigor and calling it science. It's taking creationist texts and performing ctrl-H to replace "creator" with "intelligent designer." At the levels of people who can critically think, no one is fooling anyone. This is being done because it's hoped that pseudo scientific things can be used to confuse enough naive, credulous people into saying "but isn't this science too?", not because creation scientists are actually looking for a credible reason to discount evolution. It's people who don't understand cause and effect, vs literal scam artists who want to keep us at a middle ages level of science. Volmarias fucked around with this message at 21:30 on Mar 24, 2013 |
# ? Mar 24, 2013 21:24 |
|
And I'm proven once again wrong about whatever stupid argument we had last week being the dumbest one. I didn't think we'd reach D&D poo poo in here.
|
# ? Mar 24, 2013 21:49 |
|
I guess I should have stuck to programming examples
|
# ? Mar 24, 2013 22:18 |
|
Suspicious Dish posted:And I'm proven once again wrong about whatever stupid argument we had last week being the dumbest one. I didn't think we'd reach D&D poo poo in here. I thought the lesson of this thread is that we are the horrors.
|
# ? Mar 24, 2013 22:24 |
|
HappyHippo posted:I guess I should have stuck to programming examples People who try to make things objectively worse for everyone just for personal gain get me riled up like nothing else. Sorry for the awful digression, let's get back to talking about horrible beep boop button press things
|
# ? Mar 24, 2013 22:36 |
|
pokeyman posted:I thought the lesson of this thread is that we are the horrors. But it was all right, everything was all right, the struggle was finished. He had won the victory over himself. He loved Big Brother.
|
# ? Mar 24, 2013 22:53 |
|
Suspicious Dish posted:And I'm proven once again wrong about whatever stupid argument we had last week being the dumbest one. I didn't think we'd reach D&D poo poo in here. We've at least not reached as low as GBS yet
|
# ? Mar 25, 2013 00:48 |
|
lancemantis posted:I think 'J2EE' just aggravated this problem by sometimes requiring a good chunk of boilerplate so a bunch of guys now think this is what writing software is. Dear god, this. Maybe it's just the (godawful) framework we're using that's left a bad flavor in my mouth, but my God, every drat JSP is in excess of 1,000 lines long, even just the ones which spit out a handful of lines of HTML. Freakin' nightmare.
|
# ? Mar 25, 2013 03:54 |
|
I once patched an output encoding bug that I had no way to reproduce, by copying and pasting the offending library routines into the app, 3 calls deep, then modifying the innermost function to discard the problem characters. And I'd do it again. That ticket was OLD. Gazpacho fucked around with this message at 07:25 on Mar 25, 2013 |
# ? Mar 25, 2013 07:12 |
|
http://jefferai.org/2013/03/24/too-perfect-a-mirror/ The KDE project very nearly managed to lose all 1500 of their git repositories, if not for one of their servers getting lucky on timing so the sync timed out. The other four servers saw that the main server had been corrupted, so they faithfully deleted their copies. There were no backups.
|
# ? Mar 25, 2013 09:12 |
|
Aleksei Vasiliev posted:http://jefferai.org/2013/03/24/too-perfect-a-mirror/ Well, doesn't every developer have a full copy of the repository they're working on?
|
# ? Mar 25, 2013 10:21 |
|
|
# ? May 17, 2024 17:35 |
|
Athas posted:Well, doesn't every developer have a full copy of the repository they're working on? In KDE's case everything would be recoverable no matter how broken things were (as you said, each developer has a copy), the horror is mostly that a project that large considered Git a key part of their backup plan.
|
# ? Mar 25, 2013 12:20 |