Live data from Hacker News

Software Mise En Place

buttondown.email

11–20 of 85 posts

Re: Software Mise En Place

#11
post #9

I kind of like to think code itself could use this analogy. If a piece of code combines data from three systems, then maybe first fetch it from each one (maybe in parallel), then "wash" it (check preconditions, normalize, etc.) Then you hopefully have data which is ready for doing the core work without the code being muddled with fetching missing stuff and cleaning it. I can obviously find counterexamples when it is…

I tend to prefer the approach of

  fetch A
  wash A
  fetch B
  wash B
in terms of being easier to read. Of course sometimes there are performance benefits to firing off all the requests right at the start.

Anyway I definitely agree that not separating the core logic out from the data fetching/cleaning is a bad idea.

Re: Software Mise En Place

#12
My mise en place is very similar to the authors - set up whatever I need to get fast and clear feedback before anything.

If it’s a web service, set up a hello world / health check to auto-deploy with migrations if applicable, after automatically running the build.

If it’s a library, set up a build and CI, and any version bumping and release scripts, docs autogeneration.

Basically set yourself up for success and handle a lot of the non-project related heavy lifting. That makes a great foundation off which to launch and iterate quickly.

Re: Software Mise En Place

#13

There's one place where the analogy breaks down IMO: In cooking, you usually know the recipe and have experience before preparing it for many people. In programming, you often explore and create, trying out new things that you didn't know before. Mise en place suggests that you know exactly what ingredients and tools you'll need and what to do with them. Perhaps a woodworking workshop is a better analogy for the crea…

>In cooking, you usually know the recipe and have experience before preparing it for many people. In programming, you often explore and create, trying out new things that you didn't know before.

Im pretty sure that experimentation equally well to cooking.

Re: Software Mise En Place

#14
Mise en place is a useful mental model for everyday activities, but I don't think the author gave a good example in the post.

I don't think intensity or difficulty is the key differentiator between preparation and the actual work. To me, it's mainly about separating tedious and repetitive tasks from the ones that require attention and creativity.

Prep work means that you perform something that you have done many-many times before and it feels automatic. Prep can be also harder and more intense in many ways than the actual work itself.

Re: Software Mise En Place

#15
For me, "Mise en place", has nothing to do with chopping everything beforehand and in fact that is completely different from how I cook and develop software. Chopping everything at the start seems like it takes longer.

I think Mise en place can mean different things to different people. The way I was taught it was to have everything "in place" before you start. Literally you gather all the ingredients in one place (on a metal tray) before you start cooking. This has three main benefits: 1) you make sure you have everything you need; 2) you don't forget to add anything as you go because at the end your tray should be empty; 3) you don't mess up timings by searching for something while you're cooking that you can't find; Thus I use Mise en place, but I don't chop everything at the start. I chop the onion and then start cooking it, and then chop the other ingredients. Chopping everything else upfront would make the process slower.

Similarly in software development I often save simple tasks for when I need mental relief from a hard task. Working on a simple task can often give you the space you need for your brain to solve the hard task it's working on in the background.

Doing all the simple tasks up front does not seem to me like a good approach to cooking or software development, but making sure you know what all the ingredients are and have them all ready, does.

Re: Software Mise En Place

#16
post #13

There's one place where the analogy breaks down IMO: In cooking, you usually know the recipe and have experience before preparing it for many people. In programming, you often explore and create, trying out new things that you didn't know before. Mise en place suggests that you know exactly what ingredients and tools you'll need and what to do with them. Perhaps a woodworking workshop is a better analogy for the crea…

>In cooking, you usually know the recipe and have experience before preparing it for many people. In programming, you often explore and create, trying out new things that you didn't know before. Im pretty sure that experimentation equally well to cooking.

Sure, but the ratio is way different. I frequently cook the exact recipe the exact same way as I've done before, but I'd struggle to think of a reason to rewrite the exact same implementation of the same program.

Re: Software Mise En Place

#17

> You don’t start prepping one vegetable while another is already cooking. I actually do that all the time - different ingredients have different densities and different cooking times, so it makes total sense to start cooking the harder ones while cutting the softer ones (e.g. when making a Minestrone soup). Or you want an onion/garlic/tomato base to break down before inserting other ingredients that should only cook…

The thing with that is you need to know what takes longer, and how long that longer is, beforehand. That comes from experience mostly. You will certainly screw it up several times before you get a feel for it.

You will also screw it up if you don't do it like this, because if you cook the soft things first, they will mush while the other parts are still hard. Cooking is always experience and tasting while doing it. And it can vary a lot based on ingredients of the day.

It's not really that hard to get it right though, just by touching it it's easy to see that a zucchini will cook faster than fennel.

Re: Software Mise En Place

#19

Isn't this just waterfall? Prep the shit outa everything requirement and design wise, then make it in sequential fashion?

> Isn't this just waterfall?

I don't think so, because the article is talking about prepping up the tools and infrastructure needed for the project, not the requirements and design needed for the program's business logic.

Re: Software Mise En Place

#20

For me, "Mise en place", has nothing to do with chopping everything beforehand and in fact that is completely different from how I cook and develop software. Chopping everything at the start seems like it takes longer. I think Mise en place can mean different things to different people. The way I was taught it was to have everything "in place" before you start. Literally you gather all the ingredients in one place (o…

I do tend to cook like this, but that's because I'm an inexperienced cook :-) I don't trust my ability to complete a prep task in the bounded amount of time you have once you've actually started cooking, so unless the time available is clearly long and the prep task trivial I tend to do most to all of the prep in advance. You're absolutely right that it takes longer in wall clock time but I find it less stressful, and that's valuable to me.
Post reply on HN