Live data from Hacker News

Challenge to scientists: does your ten-year-old code still run?

nature.com

401–410 of 487 posts

Re: Challenge to scientists: does your ten-year-old code still run?

#401
post #202

I think it's unfair to expect from anyone to maintain code forever when the code rot is completely beyond your control, let alone to expect this from scientists who have better things to do. Anything with a GUI is bound to self-destruct, for example, and it's not the programmer's fault. Blame the OS makers and framework/3rd party library suppliers. The damage can be limited by choosing a programming language that pro…

> CommonLisp Common Lisp has fantastic long-term stability. I think that deserves more recognition, as Common Lisp is often almost as fast as C, but is (by default) not riddled with undefined behavior. It would be superb if Rust could take C's space in computational science and libraries.

[deleted]

Re: Challenge to scientists: does your ten-year-old code still run?

#402
post #98

This article brings up scientific code from 10 years ago, but how about code from .. right now? Scientists really need to publish their code artifacts, and we can no longer just say "Well they're scientists or mathematicians" and allow that as an excuse for terrible code with no testing specs. Take this for example: https://github.com/mrc-ide/covid-sim/blob/e8f7864ad150f40022... This was used by the Imperial College…

I am all for open science, but you understand that the links in your post are the exact worry people have when it comes to releasing code: people claiming that their non-software engineering grade code invalidates the results of their study. I'm an accelerator physicist and I wouldn't want my code to end up on acceleratorskeptics.com with people that don't understand the material making low effort critiques of minor…

What I'm saying is that scientific code doesn't need to handle every special case or be easily usable by non-experts.

Sounds like I should just become a scientist then.

Do you guys write unit tests or is that beneath you too?

Re: Challenge to scientists: does your ten-year-old code still run?

#403

Earlier quoted context omitted.

That's not how the game is played. If you cannot the release the code because the code is too ugly or untested or has bugs, how do you expect anyone with the right expertise to assess your findings? It reminds me of Kerckhoffs's principle in cryptography, which states: A cryptosystem should be secure even if everything about the system, except the key, is public knowledge.

In GIS, there's a saying "the map is not the terrain". It seems like HN is in a little SWE bubble, and needs to understand "the code is not the science". In science, code is not an end in-and-of-itself. It is a tool for simulation, data reduction, calculation, etc. It is a way to test scientific ideas. > how do you expect anyone with the right expertise to assess your findings I would expect other experts in the fiel…

If you’re saying you produced certain results with code, then the code is indeed the science. Not being able to vouch for the code is like believing a mathematical theorem without seeing the proof.

Re: Challenge to scientists: does your ten-year-old code still run?

#404

Earlier quoted context omitted.

Don't you think docker, dependencies, unit test frameworks, etc actually increase the need for ongoing maintenance as opposed to spitting out some C files or python scripts which last "forever"?

No. Python/C files didn't work in a vacuum. They need dependencies, that is the point of Docker after all. Capture all necessary dependencies into a single image.

> Python/C files didn't work in a vacuum

They do if you use the standard library (which for python is quite extensive), and copy any dependencies into your own source, as if they are your own. By "in a vaccum" we can mean if python o is installed, it will work.

> Capture all necessary dependencies

Docker doesn't capture any dependencies. They still exist on the internet. It just captures a list of which ones to download when you build the image.

Do you think software we write now has more longevity than older software that uses make or a shell script?

Re: Challenge to scientists: does your ten-year-old code still run?

#405

This article brings up scientific code from 10 years ago, but how about code from .. right now? Scientists really need to publish their code artifacts, and we can no longer just say "Well they're scientists or mathematicians" and allow that as an excuse for terrible code with no testing specs. Take this for example: https://github.com/mrc-ide/covid-sim/blob/e8f7864ad150f40022... This was used by the Imperial College…

You can blame all the scientists, but shouldn't we blame the CS folks for not coming up with suitable languages and software engineering methods that will prevent software from rotting in the first place?

Why isn't there a common language that all other languages compile to, and that will be supported on all possible platforms, for the rest of time?

(Perhaps WASM could be such a language, but the point is that this would be just coincidental and not a planned effort to conservate software)

And why aren't package managers structured such that packages will live forever (e.g. in IPFS) regardless of whether the package management system is online? Why is Github still a single point of failure in many cases?

Re: Challenge to scientists: does your ten-year-old code still run?

#406
post #283

Earlier quoted context omitted.

> Does scientific-grade code need to be reproducible? Yes. Fundamentally yes. I agree that this is a good property for scientific code to have, but I think we need to be careful not to treat re-running of existing code the same way we treat genuinely independent replication. Traditionally, people freshly constructed any necessary apparatus, and people walked through the steps of the procedures. This is an interaction…

This! I struggled with this topic in university. I was studying pulsar astronomy, and there was only one or two common tools used at the lower levels of data processing, and had been the same tools used for a couple of decades. The software was "reproducible" in that the same starting conditions produced the same output, but that didn't mean the _science_ was reproducible, as every study used the same software. I rep…

Should this be surprising? I'm not saying it is correct, but it is similar to the response many managers give concerning a badly needed rewrite of business software. Doing so is very risky and the benefits aren't always easy to quantify. Also, nobody wants to pay you to do that. Research is highly competitive, so no researcher is going to want to spend valuable time making a new tool that already exists even if needed if no other researchers are doing that.

Re: Challenge to scientists: does your ten-year-old code still run?

#407

Earlier quoted context omitted.

> Does scientific-grade code need to be reproducible? Yes. Fundamentally yes. I agree that this is a good property for scientific code to have, but I think we need to be careful not to treat re-running of existing code the same way we treat genuinely independent replication. Traditionally, people freshly constructed any necessary apparatus, and people walked through the steps of the procedures. This is an interaction…

But "rerunning reproducability" is mostly a neccessary requirement for independent reproducability. If you can't even run the original calculations against the original data again how can you be sure that you are not comparing apples to oranges?

This is not clear at all. It depends on the "result" in question. If I wrote a paper describing a super numerical algorithm for inverting matrices, and no one is able to replicate the superior performance of my algorithm despite following the recipe in my paper, then whether they can run my code or not doesn't seem to be of the highest priority.

Edit: more careful phrasing.

Re: Challenge to scientists: does your ten-year-old code still run?

#408
Snark: No, I wrote it in Python 2.7, because Python 3 was still wearing very smelly diapers in 2010. Ask me in another 10 years and I'll tell you the same, because Python doesn't care about backwards compatibility. Hopefully I'll have moved on to a more stable language by then. Maybe fortran?

Re: Challenge to scientists: does your ten-year-old code still run?

#410
To throw in one more data point: several years ago I wrote a simulator for a paper, it involves tracking large numbers of particles bouncing through a 2D space with different geometries. There's a front end, in PLT Scheme, and a backend in C. I'm pretty sure that today

- the C code would still compile and run

- the Scheme code would not without some effort, because PLT Scheme 372 is no longer supported, Racket made a number of breaking changes, so one would either have to rewrite the Scheme code for Racket or rewrite it for another Scheme implementation.

Post reply on HN