5 ms·
I've seen a lot of code coming out of academia that exhibits a similar complete lack of structure and completely ignores the most basic software development bes
by cataphract 6y ago
I've seen a lot of code coming out of academia that exhibits a similar complete lack of structure and completely ignores the most basic software development best practices (such as having tests). There are exceptions, and research software engineers are a thing, but unsurprisingly most academics focus their careers on the science rather than the code.
- mytailorisrich 6y agoSometimes those people found a startup company, come up with a 'prototype', and are lucky enough to be acquired. Then, you end up having to turn this 'style' of code into a product and to maintain it...
- heisenzombie 6y agoIt’s the same reason that if you go into a working Physics laboratory, most things will seem to be wrapped in kitchen aluminium foil. There’s better ways of making thermal insulation, EMF shielding, grounding, dust protection... but the foil is /right there/ and the experiment only really needs to work /once/
- Gibbon1 6y agoIn physics labs everything is wrapped in foil because they use heat tape to bake the shit of it.
- SiempreViernes 6y agoHey now, how could anything be better than foil? You can reliably steal enough of it from any nearby kitchen, and it does the job well enough, what's the downside? ;)
- lbeltrame 6y agoI once had to debug a crash in a very popular program used in genomics (for those in the know, it was an early version of "samtools" IIRC) and I found it really hard to read. (In the end the crash was due to corrupted input data, so I fixed the data and stopped debugging)
- masonic 6y agothe crash was due to corrupted input data Bad data shouldn't cause a crash. That's just sloppy.
- lbeltrame 6y agoIndeed: in fact someone must have found the issue eventually, as newer versions exited with an error instead of core dumping. Sadly, academic constraints (time; results required the day before) prevented me from actually filing a bug report.
- SiempreViernes 6y agoProper input validation is really hard, and a reliable crash on incorrect input is frankly much better than other alternatives such as soldiering on and output trash, or even worse seemingly fine results. Of course, it sucks if it takes a few hours before you get your crash, that usually tricks you into thinking the software did something wrong and not you. Best is if it dies immediately upon reading the input, and if it does that with an error or a crash isn't crucial, though of course getting a clear error message is always better. As a comparison, a collaboration internal tool I need to use will print a helpful usage message, and then segfault if you call it without any arguments...
- devit 6y agoJournals need to start rejecting submissions without code, or with code that doesn't pass peer review by people with a modicum of software engineering skill.