Everything these worthless fuckers do:http://www.qs1.com/
5/3/2012 2:01:16 AM
5/3/2012 9:45:23 AM
Dilbert Principlehttp://en.wikipedia.org/wiki/The_Dilbert_principle
5/3/2012 10:58:45 AM
5/4/2012 12:19:57 AM
Also consider that unless you're at a pretty decent company, management tends to be COMPLETELY FUCKING RETARDED
5/4/2012 1:07:01 AM
That makes no sense jaZonUpper management usually suck ass at big corporate offices.
5/4/2012 1:14:11 AM
The art of management is blaming your subordinates for your own incompetence.
5/4/2012 7:54:11 AM
Windows Phone 7
5/4/2012 9:20:11 AM
Really? I thought it had pretty decent reviews. I even know an apple fan boy (literally buys every iteration of every apple product) who was impressed.
5/4/2012 9:40:11 AM
EMR vendor for some doctor has Surescripts integration for refill transactions. The transaction requires the requester (us) to send a unique (to the requester) identifier for the requests, to prevent duplicate requests. EMR vendor's software has a unique constraint on ALL transaction request ids they receive. So if we use an ID number that some other pharmacy already used, they won't process our request. This still passes surescripts certification because they only need to demonstrate that they reject refill requests from the same requester with the same ID. To process requests with this vendor, we would basically have to guess at IDs until we find one that hasn't been used.
5/4/2012 1:00:17 PM
Back to the talk of automated testing ^*? , I know its en vogue with managers to try and automate all testing so they can remove resources from running tests but that only works for the most simple dumb sort of stuff. Testing actual user functions still needs actual human beings.
5/4/2012 1:09:28 PM
^It's funny, because that's exactly what happened at large software dev houses 5-7 years ago, and 3-4 years ago started seeing the ramifications of that approach so most of the industry has now moved back to a balanced (and much healthier) approach of mixed testing environments.TFS (that I work on) is really stressing that testing range with the version in beta right now. TLM (Test and Lab Management) handles all of the full test automation, test suites, coded UI testing, scripted manual testing and now exploratory (black box) testing, etc. VS handles unit testing, load testing, code contracts, code clones, etc. and TFS now has a Feedback client (for stakeholders and customers) to be able to give feedback and find problems that get back to the team with incredibly rich detail (we capture symbol data, reverse engineer screen elements down to ids/tags, video and audio recordings, time-stamped text comments, screenshots + annotations).Yeah, test is probably the widest gamut of tools and services to do a really good job, and still by far the least mature in terms of industry practices and standards it seems.
5/4/2012 1:46:26 PM
^ Yeah I work in manufacturing so we're always 5-10 years behind the curve
5/4/2012 8:18:09 PM
5/4/2012 9:16:31 PM
Legacy design: Putting a VPN tunnel (B) inside of a VPN tunnel (A). App Client --> B client --> A client --> Special Hardware --> Internet --> A server --> B client --> App ServerProblems (to name a few):- Having VPN client A randomly intercept and drop VPN client B's traffic because B's uses a virtual network adapter that A doesn't recognize. - OS is Windows 2000 - A/B/App are using software equally old (circa 2003/2004).- Packet size drops significantly because of "special hardware", couple that with the overhead required by the VPN solutions, you lose half of your effective MTU for the data payload per packet.- Routing tables are completely controlled by proprietary software (provided by special hardware manufacturer). There is no default route, and anytime you need to update either VPN routes, you need to update the proprietary software.Back in 2003/2004 the design was the only feasible option available for this customer. Fast-forward to the present, they decide to upgrade one item in the chain, and the entire thing breaks down. I won't name the end customer behind this, but as a consumer you have probably had direct interaction with them at some point. To top this all off, their CEO was talking to our executives on a daily basis to get all of this "working". Finally got something to work at the end of the day, but it was ugly.[Edited on May 9, 2012 at 7:28 AM. Reason : .]
5/9/2012 7:22:16 AM
public void SomeMethod(object sender, EventArgs ev){ this.AnotherMethod(ev);}// this method is only called by SomeMethodprivate void AnotherMethod(object args){ EventArgs e = args as EventArgs; var something = ((CustomEventArgs)e).SomeProperty; var somethingElse = ((CustomeEventArgs)e).SomeOtherProperty; // do nothing else with e}
foreach (var item in SomeLongListOfReflectedProperties){ var stupidShallowCopy = item; otherInternalList.SomeLinqMethodThatTakesALambda(() => (new ClassWhichHasNoStateInformation()).SomeMethodThatShouldReallyBeStatic(stupidShallowCopy.Property1, stupidShallowCopy.Property2, someotherInput));}
6/16/2012 2:52:28 PM
in performance critical code:
if (Double.Convert(x) == 0){ y = Double.Convert(x); ... }else if (Double.Convert(x) == 1) { y = Double.Convert(x) + 1; ... }else if (Double.Convert(x) == 2) { y = Double.Convert(x)*Double.Convert(x); ... }else if (Double.Convert(x) == 3) { foo3(); }else if (...) ...else{ for (int i = 0; i < somethingThatMightBeLarge; i++) { if (somethingThatDoesntChangeInTheForLoop) y = Double.Convert(x); else y = x; }}
8/22/2012 10:56:48 PM
That c#? They copied java and made nothing better[Edited on August 23, 2012 at 9:15 AM. Reason : .]
8/23/2012 9:14:49 AM
The developers for our standard product created a unit test that creates 1111111 new rows in a table every time its run. Of course there is not cleanup step to remove at the completion of the unit test. Massive tables ensue.
8/23/2012 1:49:00 PM
^^^ to be fair, wouldn't a decent compiler fix that? but that's some stupid shit
8/23/2012 6:00:15 PM
^^^ read on a little further, you'll see at least one nice addition: MOTHER FREAKIN PROPERTIES. I seriously hate a crap ton of GetFoo() and SetFoo(foo) methods.^ with the level of stupid in this code-base, the compiler probably just passes over that stuff and shakes its figurative head.here's another one from today...
public object Foo1{get { return _foo1; }set { value = _foo1; }}public object Foo2{get { return _foo2; }set { value = _foo2; }}public object Foo3{get { return _foo3; }set { value = _foo3; }}
8/23/2012 6:43:18 PM
that's... i don't even...
8/24/2012 9:37:15 PM
8/24/2012 10:41:50 PM
8/24/2012 10:43:29 PM
8/27/2012 1:08:40 PM
I love that HP's QA tool, Quality Center, is a buggy piece of crap. I just crashed the entire program by entering a column filter that has spaces in it but didn't have quotes around it. And now I can't log back into it
8/28/2012 3:53:34 PM
^^We connect with SAP but only in a few situations.I was specifically referring to writing Java interfaces. You want to declare a class of functions for high level concepts that are implemented a bunch of different ways. You shouldn't really be defining interfaces past a certain point in the hierarchy just from a practicality standpoint.IE you might write a public interface Car{..} and you might also have a public interface Sedan{...} extends Car but then you write an interfacepublic interface FordSedan{...} extends Sedan which might be a bit much but is still okay but then..public interface FordTaurus{...} extends FordeSedanpublic interface FordTaurus1995{...} extends FordTauruspublic interface FordTaurus1995FrontWheelDrive{...} extends FordTaurus1995And each of these interfaces may or may not have corresponding Impl files. And to cap off all that suck sauce virtually all of these interfaces are ever only implemented by one object completely negating the need for defining an interface.This creates a super bloated implementation and a lot of extra work that I can't just ignore and do the right way because its on the peer review checklist before the code can meet release.
9/2/2012 1:24:55 PM
yeah, our codebase has some of that stupidity, too. It makes you have to wade through so much bullshit whenever you try to find the implementation of something. Definitely an anti-pattern. It's not very helpful when all you ever do is cast your passed around interfaces to one fucking business object type anyway every fucking time you reference that interface
9/2/2012 2:21:24 PM
this one hurts in so many ways it's not even funny. It's a simple comparison function.
// Get the type of the objects being comparedvar valueType = value1.GetType().ToString();// If it's a numeric type, then do a numeric comparison instead of a string comparisonif ( (valueType == "System.Int16") || (valueType == "System.Int32") || (valueType == "System.Int64") || (valueType == "System.Double") || (valueType == "System.Single") ){ switch (valueType) { case "System.Int16": { short tmpValue1 = (short)value1; short tmpValue2 = (short)value2; if (tmpValue1 == tmpValue2) return 0; if (tmpValue1 < tmpValue2) return flipResult(-1); return flipResult(1); } case "System.Int32": { int tmpValue1 = (int)value1; int tmpValue2 = (int)value2; if (tmpValue1 == tmpValue2) return 0; if (tmpValue1 < tmpValue2) return flipResult(-1); return flipResult(1); } case "System.Int64": { System.Int64 tmpValue1 = (System.Int64)value1; System.Int64 tmpValue2 = (System.Int64)value2; if (tmpValue1 == tmpValue2) return 0; if (tmpValue1 < tmpValue2) return flipResult(-1); return flipResult(1); } case "System.Double": { System.Double tmpValue1 = (System.Double)value1; System.Double tmpValue2 = (System.Double)value2; if (tmpValue1 == tmpValue2) return 0; if (tmpValue1 < tmpValue2) return flipResult(-1); return flipResult(1); } case "System.Single": { System.Single tmpValue1 = (System.Single)value1; System.Single tmpValue2 = (System.Single)value2; if (tmpValue1 == tmpValue2) return 0; if (tmpValue1 < tmpValue2) return flipResult(-1); return flipResult(1); } }}else{ IComparable comparer = (IComparable)value1; if (comparer != null) { return flipResult(comparer.CompareTo(value2)); } else return 0;}
9/20/2012 11:36:15 AM
the entirety of that code there could be written in one line of code. one line. Whenever I do an in-person screening, I will use that code as an interview question. here's another one. I had to be nice about this one at work today, because apparently the person who wrote it is still on our team.
if (A) return foo1;else if (A && B) return foo2;else if (...)
9/20/2012 11:52:03 PM
9/21/2012 11:46:37 AM
Come on now. His comments here a on track for Tech Talk and he does contribute. Until he aaronburro's it up on this sub-board like he has in Soap Box (and the occasional Sports Talk), lets keep it civil.
9/21/2012 2:03:34 PM
for those times where you just can't quite trust a newly instantiated HashTable to be empty...
if (reload) { newHash = new Hashtable(); if (!newHash.ContainsKey("Action")) newHash.Add("Action", "Reload"); if (!newHash.ContainsKey("clearKey")) newHash.Add("clearKey", "Y"); }
10/4/2012 10:09:58 AM
non-aaronburro posts in this thread are interesting, aaronburro posts are a little too "look at how important i am, i have a job were i review code"
10/4/2012 11:44:19 AM
public bool IsDate(ref string inValue){ // Variable to collect the Return value of the TryParse method. bool result; try { IFormatProvider format = new System.Globalization.CultureInfo("en-US",false); //"en-US" DateTime myDT = DateTime.Parse(inValue,format,System.Globalization.DateTimeStyles.AdjustToUniversal ); inValue = myDT.ToShortDateString(); result = true; } catch (System.FormatException) { try { IFormatProvider format = new System.Globalization.CultureInfo("es-ES",false); //"es-ES" international DateTime myDT = DateTime.Parse(inValue,format,System.Globalization.DateTimeStyles.AdjustToUniversal ); inValue = myDT.ToShortDateString(); result = true; } catch { result = false; } } return result; }
10/19/2012 1:00:45 PM
^^ of course we all enjoy seeing colossal-scale fuckups more, but to be fair i think burro's posts are pretty classic examples of wtf code. i don't want this to become just a What is wrong with burro's codebase today thread, but i don't think he's trying to puff himself up here
10/19/2012 5:41:11 PM
^AgreedThese are examples that should never even make it to a code review. This is stuff that if you thought about it for 10 seconds as you wrote it, you'd be like "hey, this doesn't make any sense".Also, qtmfred: don't you have something to be doing right now with some code?
10/19/2012 6:07:56 PM
10/19/2012 8:52:38 PM
I can't even post the most WTF examples of code, because every last one of them is essentially a massive race condition between three or four threads. This codebase is heavily multi-threaded, and yet there is hardly any synchronization code in most of it. It's like the people who originally wrote it only knew about Thread.Run() and that's it. It is a wonder than anything works, and most of us at this point have just decided that it's the crushing inefficiency of a few sections of code that keep the program afloat. Any time we do any performance work on those sections, all kinds of hell breaks loose. They use DataSets to store damned near everything internally, even though we don't send anything directly to a database and a simple generic list would do for most things. Reflection is used to populate almost every business object, which is usually then converted to another business object. After DataSets (with one table and two columns), ArrayList is their favourite data structure, followed closely by a Hashtable (and not a generic one), and there's hardly any use of generic collections whatsoever. The other day, I actually saw a do-while loop used to implement if-else functionality. I mean, wtf, folks?]
10/21/2012 8:34:41 PM
10/22/2012 12:31:44 PM
performance critical code here, folks...
if(value.Split('-').Length > 1){ if((value.Split('-').GetValue(1).ToString().Equals(string.Empty)) || (value.Split('-').GetValue(1) == null)) { valid = false; return valid; } else { ... }}
10/31/2012 11:22:32 AM
^No. Just ... no.
10/31/2012 12:55:19 PM
A "strongly typed collection" from the pre-generic .NET 1.1 days. Well, an attempt at it. This pattern is re-used liberally throughout the application.
public class ConvertibleCollection : ArrayList{ #region Constructor public ConvertibleCollection() { } #endregion #region Public Methods public void InitializeFrom(object value) { } public override void CopyTo(Array array) { base.CopyTo (array); } public override void CopyTo(Array array, int index) { base.CopyTo (array, index); } public int Add(IConvertibleDetails ConvertibleObject) { return base.Add(ConvertibleObject); } public void Remove(IConvertibleDetails ConvertibleObject) { base.Remove(ConvertibleObject); } public bool Contains(IConvertibleDetails ConvertibleObject) { return base.Contains(ConvertibleObject); } public override void InsertRange(int index, ICollection c) { base.InsertRange (index, c); } public override void Insert(int index, object value) { base.Insert (index, value); } #endregion}
11/2/2012 4:53:28 PM
You get the job you deserve
11/3/2012 1:58:28 AM
The more and more I see and use code generators the more I hate the entire approach. If you have something that's generic enough to generate code for then you shouldn't be generating separate code for each instance. You should design a generic handler for these items and pass the items along and only augment or supersede when necessary. This is a generalization and I'm not opposed to skeleton generators and getter/setter etc but generating whole files and functions to do the same damn thing is starting to drive me crazy.
11/14/2012 2:45:51 PM
A theme for a site I'm working on used this code to figure out whether the user was running a version of Internet Explorer lower than 7, in case the developer didn't want to send some fancy styles over to the old browsers:
return isset($_SERVER['HTTP_USER_AGENT']) && preg_match('/\bmsie [1-6]/i', $_SERVER['HTTP_USER_AGENT']);
11/20/2012 6:37:27 PM
it doesn't block bustygirl comics?
11/20/2012 11:23:09 PM
stfu troll
11/22/2012 2:45:31 PM
I'm gonna go ahead and put the Apple "blow away your device simply for plugging it into a different computer" programming in here. That is literally the single dumbest and most user-unfriendly design decision in the history of mankind. It's such a stupid design that Apple doesn't even need to patent it, because no one else in their right mind would copy such a boneheaded idea.]
11/23/2012 11:42:06 PM
Omg fuck yes that's awful, not to mention the entire rest of iTunes
11/23/2012 11:43:58 PM