Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Jesus loving asschrist, that is bad.

Adbot
ADBOT LOVES YOU

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Carthag posted:

Was feeling nostalgic for the late nineties and decided to look up the clusterfuck that was Hotline (basically Mac BBS software) back in the day. Most of it is management fuckups (terrible oversight) and hinks being horrible at dealing with people, but this stood out:


I know Subversion & git etc are all newer than this, but CVS was hardly unknown at the time. Uploading a compressed archive of the source tree each month... :psyduck:

We can just put "CVS :psypop:" as the response to that.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

HardDisk posted:

Why's this so awful?

It means lotso nested ifs and loops.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
I can't legally post the code, but I just saw a "Rails application" that had the entire application sans the bare minimum implimented in ERB. All the Controller logic and and and and :cry:

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
The assbreather that made this wonderful masterpiece didn't even use ActiveRecord. Motherfucking SQL (using unescaped string interpolation, of course) straight into the loving Ruby. I now need to maintain this, and I am not allowed to un:cry: anything, only add new useless features on top.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

tef posted:

the database api at work is a restful wrapper around stored procs :gay:

I thought I had it bad. Well, I do, but gently caress that.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
I'm going to pour a Mtn Dew on the curb for my dead hero. :cry:

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

OriginalPseudonym posted:

I would say "Use \r so that it's non-obvious (depending on their text editor) that there's newlines", but it doesn't appear that PHP recognizes those as newlines unless it's explicitly enabled. Oh well.

:allears: Oh PHP...

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
newlib is Satan's own library. I present as evidence that while sin() is in math.h, it is not in libm.a. :commissar:

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

dwazegek posted:

code:
semaphore = new System.Threading.Semaphore(0, 32000);
:stare:

That hurts to see. :suicide:

I bet most of it would be of a similar... quality/:wtc: level.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

PalmTreeFun posted:

For a script designed to make web design easier, CSS sure doesn't seem to do a lot to make web design easier.

CSS makes the trivial easy, and the complex achievable. :downsrim:

EDIT: That was sarcastic.

Sinestro fucked around with this message at 21:34 on Dec 8, 2011

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
I have a doozy of a database horror. Instead of using roles, there is a bunch of Perl scripts that listen on a certain port and parse in the SQL, check if it is allowed, and if it is, relay it to the real database. :psyduck: It is not because the DB didn't support roles when they were created, this was created in 2010.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Plorkyeran posted:

http://codepad.org/mQ1GHYeS

php:
<?php

if (true) { function foo() { echo "php"; } }
else { function foo() { echo " sucks"; } }

foo();

if (true) {
    function bar() { echo "php"; }
} else {
    function bar() { echo " sucks"; }
}

bar();
Output:
php sucks

Apparently it's fixed in 5.3.

The Something Awful Forums > Discussion > Serious Hardware / Software Crap > The Cavern of COBOL > Coding horrors: show me where on this anatomically correct doll where PHP touched you

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

sXe.spengler posted:

an unholy mess of Drupal with Django piled on top of it.

What? How is that even possible?

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Broken Knees Club posted:

Serious question, what was Stallman's last major contribution to Open Source, Computer Science or anything else? He obviously had an impact on the field, but he feels like a net negative these days.

The GPL.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Lonely Wolf posted:

gah just make a thread about licenses already.

A licensing thread

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
What precisely is wrong with rand()?

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Wow, that is impressively awful format. It isn't spectacular like some of the PHP stuff, but it is still an everyday horror.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

KARMA! posted:

Hello breadcums my old friend.

Okay so it's a non-english shop but really? Everywhere?

Maybe someone has a bread fetish? v:shobon:v

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Chopper posted:

I've only ever used MySQL for projects (webdev is a hobby), please could someone explain why it is so bad? What is the 'best' database to use?

I am not sure what the current list of MySQL's awfulness is, but here is a few: there is no checking on specialized fields, they are just special names for the base primitives (except when there is, and it sets it to zero!); it uses around 4 times the full size of the whole database in RAM sitting still; it doesn't really error check anything, it just does something stupid and unwanted if there is an error; and anything related to foreign keys beyond the most basic case is horrible, and as a bonus ALTER doesn't update anything FK related.

PostgreSQL is the best option I can think of for a RDBMS off the top of my head.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Zombywuf posted:

The hard part is what format do you save it as?

It doesn't matter, as long as it's readable from cat. v :) v

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Jonny 290 posted:

Not even Peter Norton can undo deletion this strong.

code:
if (($report{$var{'unit1'}}{'unit_dn'} eq 'DN') && ($report{$var{'unit2'}}{'unit_dn'} eq 'DN'))
{
	delete ($report{$var{'unit2'}}{'unit_dn'}); 
}
else 
{
	delete ($report{$var{'unit2'}}{'unit_dn'}); 
}

There is non-PHP syntax highlighting now.

Perl code:
if (($report{$var{'unit1'}}{'unit_dn'} eq 'DN') && ($report{$var{'unit2'}}{'unit_dn'} eq 'DN'))
{
	delete ($report{$var{'unit2'}}{'unit_dn'}); 
}
else 
{
	delete ($report{$var{'unit2'}}{'unit_dn'}); 
}

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
I saw a stoned dwarf in a barrel. v:v:v

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Bohemian Cowabunga posted:

So can we bitch about lovely teachers here?..
I am currently studying to become a network engineer and have taken an introductory course in C# on the side. The entire course has pretty much turned into a self-study. We have had zero theory and not turned in a single assignment, but merely worked on whatever we wanted during the classes.

Now we have never actually seen any of this guys own code until now, when he gave us the code our oral exam is based upon.

http://pastebin.com/RYHrAfRb

This guy is being paid to teach programming.

Rubbing a hard drive with a magnet would make better C#. Kill him and burn the corpse.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

nielsm posted:

So did it use Polish notation?
What happens when a Hungarian is taught to program like that?
:haw:

szNév

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
I have had things like that in my code. It just looks a little cleaner.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

sniperchance posted:

On average, what are the odds that any given "PHP Developer" opening is to fix a production application with all VARCHAR columns in an unindexed MySQL table, queries written with no concept of table joins, and tons of coded-by-exception if statements?

103%, because there will be many other horrors as well.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
Do not pick Python for web development. It is a pretty great language, but Django is a enormous piece of poo poo that breaks if you cough on it too hard. Pick Ruby, which is a great language with great support for all sorts of expressive new ways to write code, and gives you Rails, which makes web development so much nicer.

Edit:

Golbez posted:

I have experience only in relational DBs. Is there a link that explains the second half of your sentence to me like I'm a 5 year old?

http://en.wikipedia.org/wiki/MongoDB#Data_manipulation:_collections_and_documents seems pretty good at explaining things.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

KaneTW posted:

I've been using Django and it didn't seem like a piece of poo poo at all.

Eevee posted:

Django is a massive beast designed for CMS-likes and other content-rich sites. It has a large ecosystem of pluggable components, built-in everythings from templates to an ORM, and piles of documentation and community resources. Django is generally cited as the Python equivalent to Ruby on Rails. The downside is that convincing it to do things it doesn’t want to do can be… awkward. (Many of the more obtuse questions in #python are caused by attempts to tinker with Django.)

This is pretty much the best description of Django I have read. (Source: here)

He compares to Ruby on Rails, but Rails makes up for it's large size by actually making things easier than working with a barebones framework. To put it another way, Django has all of Rails' complexity, but lacks any of its helpers or most of its utility.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

bobthecheese posted:

php:
<?
foreach ( $_POST as $k1 => $v1 )
   $$k1 = $v1;
foreach ( $_GET as $k1 => $v1 )
   $$k1 = $v1;
?>
"Oh," says some developer, "You disabled register_globals because it was a massive security flaw? Ok, well I enabled it again for you! In a way that you can't disable with the php.ini! Aren't I great?"



This gif from the Political Cartoons thread sumarized my feelings towards that festering shitnugget. The best way to deal with this sort of thing is to help them figure out why it is wrong, instead of attempting to correct them based on authority alone.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
Angry. Feel angry.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
This is what happens if you let a front-end guy write your Django app.

Python code:
from django.db import models

class Data(models.Model):
    key = models.TextField()
    value = models.TextField()
You are looking at the entire models.py. :suicide:

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

dwazegek posted:

code:
url = "PhoneNumbers/phonenumberoverview/PhonenUmberSomething"
Inconsistent casing :argh:

and yes is really is PhonenUmber

What if you want an obscure Blemmye king's color of brown?

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Volte posted:

my mental picture of YOSPOS posters is slightly chubby teens wearing cardigans and shades while sneering

Nice!

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
I once physically dropped the production database. On the floor.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

horse mans posted:

Are you stupid? It's a Greek letter. Why wouldn't a five-thousand year old language have capital letters?

There is U+003BC, which is the letter. The question is why does U+00B5, which is just as a symbol for micro and micro alone, uppercase.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
But if it doesn't check out, it could be helpful to see if it was an error in the code versus a statistical anomaly or malfeasance.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
What would you want? The naďve solution?

C++ code:
template <typename T>
void swap(T &x, T &y)
{
    T swap;
    swap = x;
    x = y;
    y = swap;
}

Sinestro fucked around with this message at 01:59 on May 7, 2013

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
I haven't written C++ in forever. Let's just imagine those ampersands have always been there.

Adbot
ADBOT LOVES YOU

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
Objective-C code:
                                                                                // Hi! I'm an ugly hack!
                                                                                // For some reason, NSXMLDocument makes goddamn *Tidy warnings
                                                                                // NSErrors without anything other than the word warning in their
                                                                                // localized description to tell you that this isn't a real parse
if ([err.localizedDescription rangeOfString:@"Warning"].location != NSNotFound) // error! More proof of my "Principle of Most Surprise" theory....
I'm honestly not sure what the worst part of this is, the problem or the solution.

Sinestro fucked around with this message at 11:18 on Jun 8, 2013

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply