Simple rules for keeping dev teams out of trouble

I’ve been leading small software development teams on big projects since 2004. Painful experiences taught me some simples rules to make it less painful. Here they are, presented in order of discovery:

      1. If it can be null, it will be null
      2. The clipboard is a cruel mistress
      3. Size really does matter
      4. Inside every small problem is a larger one, struggling to get free
      5. Every bug you fix creates 2 more
      6. The law of the motorcycle shop is non-negotiable
      7. Cleverness is the mother of regret
      8. Just in time requirements are neither
      9. Don’t solve problems you don’t have yet, Nostradamus
      10. Later == never, temporary == forever, shipped > not shipped
      11. Only change 1 thing at a time
      12. Always redo, never fix
      13. Finish the most important feature first
      14. Tomorrow you hates the code you write today, so don’t plan too far ahead
      15. Character data is nvarchar(max) until you can prove otherwise (see rule 2)
      16. Schrodinger’s Spec – you can know what the client wants, or what will be best for them, just not at the same time
      17. Solve the toughest problem first
      18. Legacy == proven. Try out the newest thing on your own time and dime.
      19. Naming stuff is hard
      20. You’re not going to reuse that
      21. Process: never fix, always redo. Code: never rewrite, always fix
      22. Fix problems upstream
      23. Never use a black box when a text file will do
      24. I will put my strongly typed boot up your loosely coupled [redacted]
      25. The original sin of code is writing it
      26. An unbound task is the Devil’s workshop
      27. Developer time is vastly more expensive than CPU time

DLL Hell – Same as it Ever Was

Everything old is new again.

How it started (1998):

And all it takes is a single DLL, VBX or OCX to be missing, or present in an older version (or even an incompatible newer version), for an application to fail. A poorly designed installation program, user error, registration error or change in the user’s PATH environment variable are a few of the ways in which this problem can occur.

https://www.desaware.com/tech/dllhell.aspx

.Net – our savior (2001)?

.NET’s versioning features promise to do the most to eliminate the DLL Hell syndrome

https://www.techrepublic.com/article/introducing-the-assembly-a-cure-for-dll-hell/

Yeah no (2021)

DLL Hell is an old term that got a new meaning in managed runtimes like .NET. The original DLL Hell issue was that many applications shared the same DLL file dependency. Then, if one of those applications updated that DLL, it broke the API for the other applications, and caused all sorts of trouble.

In .NET we don’t have that problem. In most cases, applications don’t share DLLs, which prevents issues in the first place. When apps do share libraries, they use the Global Assembly Cache (GAC). This is a place to share libraries on the machine, but it’s only for strong-named libraries. When an application uses a library from the GAC, it requests a specific version, and the strong name guarantees it will get that exact version.

But if you think this architecture solved all our problems, you will be disappointed. We still have problems, just different ones (emphasis mine RH).

https://michaelscodingspot.com/dotnet-dll-hell/

We still have problems, just different ones…sums up a lot of “progress” in software development.

New DBAs be like

begin transaction
​
select * into dbo.TranSACTIOnAlLoGwilLNoTgrOWAlldbsAreINsImPLERECOveRy from dbo.ActivityLogs
​
while 1 = 1
begin
	insert into dbo.TranSACTIOnAlLoGwilLNoTgrOWAlldbsAreINsImPLERECOveRy
	select * from dbo.ActivityLogs
end

Time to hit F5 and go to lunch…

UI Fails #2, SSMS Dropdown Button

Using the “generate scripts” wizard in SSMS, I always have to stop and check my eyes on the last step.

Is that a button?
Surprise! It’s a dropdown.

Clicking a row in the dropdown performs the action you would expect the button to do. It’s bizarre the form doesn’t use checkboxes or option buttons for picking the output format, since both are already in use.

In the grand scheme of things, this is a minor inconsistency. But…this is from Microsoft, and a lot of developers just starting out will unconsciously emulate the look and feel of the tools they use most often. We need better examples than this to start out with.