1. 5

    If spending some money on hardware will make your data fit into RAM, that is often the cheapest solution: your time is pretty expensive, after all. Sometimes, however, it’s insufficient.

    Really appreciate they putting this right in the beginning. Sometimes, specially nowadays, with per minute pricing on AWS, it’s cheaper to keep it simple.

    1. 23

      Oh dang another essay on empirical software engineering! I wonder if they read the same sources I did

      Reads blog

      You watched the conference talk “What We Know We Don’t Know”, by Hillel Wayne, who, also disturbed by software’s apparent lack of scientific foundation, found and read as many scholarly papers as he could find. His conclusions are grim.

      I think I’m now officially internet famous. I feel like I crossed a threshold or something :D

      So I’m not sure how much of this is frustration with ESE in general or with me in particular, but a lot of quotes are about my talk, and so I’m not sure if I should be defending myself? I’m gonna err on the side of defending myself, mostly because it’s an excuse to excitedly talk about why I’m so fascinated by empirical engineering.

      One thing I want to open with. I’ve mentioned a couple of times on Lobsters that I’m working on a long term journalism project. I’m interviewing people who worked as “traditional” engineers, then switched to software, and what they see as the similarities and differences. I’ve learned a lot from this project, but one thing in particular stands out: we are not special. Almost everything we think is unique about software, from the rapid iteration to clients changing the requirements after we’ve released, happens all the time in other fields.

      So, if we can’t empirically study software engineering, it would follow that we can’t empirically study any kind of engineering. If “you can’t study it” only applied to software, that would make software Special. And everything else people say about how software is Special turns out to be wrong, so I think it’s the case here.

      I haven’t interviewed people outside of engineering, but I believe it goes even further: engineering isn’t special. If we can’t study engineers, then we can’t study lawyers or nurses or teachers or librarians. Human endeavor is incredibly complex, and every argument we can make about why studying software is impossible extends to any other job. I fundamentally reject that. I think we can usefully study people, and so we can usefully study software engineers.

      Okay so now for individual points. There’s some jank here, because I didn’t edit this a whole lot and didn’t polish it at all.

      You were disappointed with Accelerate: The Science of Lean Software and DevOps. You agreed with most of its prescriptions. It made liberal use of descriptive statistics.

      Accelerate’s research is exclusively done by surveying people. This doesn’t mean it’s not empirical- as I say in the talk, qualitative information is really helpful. And one of my favorite examples of qualitative research, the Gamasutra Study on Crunch Mode, uses a similar method. But it’s far from being settled, and it bothers me that people use Accelerate as “scientifically proven!!!

      1. Controlled experiments are typically nothing like professional programming environments […] So far as I know, no researcher has ever gathered treatment and control groups of ten five-developer teams each, put them to work M-F, 9-5, for even a single month, in order to realistically simulate the conditions of a stable, familiar team and codebase.

      You’d be surprised. “Two comparisons of programming languages”, in “making software”, does this with nine teams (but only for one day). Some labs specialize in this, like SIMULA lab. Companies do internal investigations on this- Microsoft and IBM especially has a lot of great work in this style.

      But regardless of that, controlled experiments aren’t supposed to be holistic. They test what we can, in a small context, to get solid data on a specific thing. Like VM Warmup Blows Hot and Cold: in a controlled environment, how consistent are VM benchmarks? Turns out, not very! This goes against all of our logic and intuition, and shows the power of controlled studies. Ultimately, though, controlled studies are a relatively small portion of the field, just as they’re a small portion of most social sciences.

      For that matter, using students is great for studies on how students learn. There’s a ton of amazing research on what makes CS concepts easier to learn, and you have to use students for that.

      1. The unpredictable dynamics of human decision-making obscure the effects of software practices in field data. […] This doesn’t hold for field data, because real-life software teams don’t adopt software practices in a random manner, independent from all other factors that might potentially affect outcomes.

      This is true for every form of human undertaking, not just software. Can we study teachers? Can we study doctors and nurses? Their world is just as chaotic and dependent as ours is. Yet we have tons of research on how educators and healthcare professionals do their jobs, because we collectively agree that it’s important to understand those jobs better.

      One technique we can use cross-correlating among many different studies on many different groups. Take the question “does Continuous Delivery help”. Okay, we see that companies that practice it have better outcomes, for whatever definiton of “outcomes” we’re using. Is that correlation or causation? Next we can look at “interventions” where a company moved to CD and see how it changed their outcomes. We can see what practices all of the companies share and what things they have different, to see what cluster of other explanations we have. We can examine companies where some teams use CD and some teams do not, and correlate their performance. We can look at what happens when people move between the different teams. We can look at companies that moved away from CD.

      We’re not basing our worldview off a single study. We’re doing many of them, in many different contexts, to get different facets of what the answer might actually be. This isn’t easy! But it’s worth doing.

      1. The outcomes that can be measured aren’t always the outcomes that matter. […] So in order to effectively inform practice, research needs to ask a slightly different, more sophisticated question – not e.g. “what is the effect software practice X has on ‘defect rate’”, but “what is the effect software practice X has on ‘defect rate per unit effort’”. While it might be feasible to ask this question in the controlled experiment setting, it is difficult or impossible to ask of field data.

      Pretty much all studies take this as a given. When we study things like “defect rate”, we’re always studying it in the context of unit time or unit cost. Otherwise we’d obviously just use formal verification for everything. And it’s totally feasible to ask this of field data. In some cases, companies are willing to instrument themselves- see TSP or the NASA data sets. In other cases, the data is computable- see research on defect rates due to organizational structure and code churn. Finally, we can cross-correlate between different projects, as is often done with repo mining.

      These are hard problems, certaintly. But lots of things are “hard problems”. It’s literally scientists’ jobs to figure out how to solve these problems. Just because we, as layfolk, can’t figure out how to solve these problems doesn’t they’re impossible to solve.

      1. Software practices and the conditions which modify them are varied, which limits the generality and authority of any tested hypothesis

      This is why we do a lot of different studies and test a lot of different hypothesis. Again, this is an accepted fact in empiricial research. We know it’s hard. We do it anyway.

      But if you’re holding your breath for the day when empirical science will produce a comprehensive framework for software development – like it does for, say, medicine – you will die of hypoxia.

      A better analogue is healthcare, the actual system of how we run hospitals and such. Thats in the same boat as software development: there’s a lot we don’t know, but we’re trying to learn more. The difference is that most people believe studying healthcare is important, but that studying software is not.

      Is this cause for despair? If science-based software development is off the table, what remains? Is it really true as Hillel suggests, that in the absence of science “we just don’t know” anything, and we are doomed to an era of “charisma-driven development” where the loudest opinion wins, and where superstition, ideology, and dogmatism reign supreme?

      The lack of empirical evidence for most things doesn’t mean we’re “doomed to charisma-driven development.” Rather it’s the opposite: I find the lack of evidence immensely freeing. When someone says “you are unprofessional if you don’t use TDD” or “Dynamic types are immoral”, I know, with scientific certainty, that they don’t actually know. They just believe it. And maybe it’s true! But if they want to be honest with themselves, they have to accept that doubt. Nobody has the secret knowledge. Nobody actually knows, and we all gotta be humble and honest about how little we know.

      Of course not. Scientific knowledge is not the only kind of knowledge, and scientific arguments are not the only type of arguments. Disciplines like history and philosophy, for instance, seem to do rather well, despite seldom subjecting their hypotheses to statistical tests.

      Of course science isn’t the only kind of knowledge! I just gave a talk at Deconstruct on the importance of studying software history. My favorite software book is Data and Reality, which is a philosophical investigation into the nature of information representation. My claim is that science is a very powerful form of knowledge that we as software folk not only neglect, but take pride in our neglecting. It’s like, yes, we don’t just have science, we have history and philosophy. But why not use all three?

      Your decision to accept or reject the argument might be mistaken – you might overlook some major inconsistency, or your judgement might be skewed by your own personal biases, or you might be fooled by some clever rhetorical trick. But all in all, your judgement will be based in part on the objective merit of the argument

      Of course we can do that. Most of our knowledge will be accumulated this way, and that’s fine. But I think it’s a mistake to be satisfied with that. For any argument in software, I can find two experts, giants in their fields, who have rigorous arguments and beautiful narratives… that contradict each other. Science is about admitting that we are going to make mistakes, that we’re going to naturally believe things that aren’t true, no matter how mentally rigorous we try to be. That’s what makes it so important and so valuable. It gives us a way to say “well you believe X and I believe not X, so which is it?”

      Science – or at least a mysticized version of it – can be a threat to this sort of inquiry. Lazy thinkers and ideologues don’t use science merely as a tool for critical thinking and reasoned argument, but as a substitute. Science appears to offer easy answers. Code review works. Continuous delivery works. TDD probably doesn’t. Why bother sifting through your experiences and piecing together your own narrative about these matters, when you can just read studies – outsource the reasoning to the researchers? […] We can simply dismiss them as “anti-science” and compare them to anti-vaxxers. […] I witnessed it play out among industry leaders in my Twitter feed, the day after I started drafting this post.

      I think I know what you’re referencing here, and if it’s what I think it is, yeah that got ugly fast.

      Regardless of how Thought Leaders use science, my experience has been the opposite of this. Being empirical is the opposite of easy. If I wanted to not think, I’d say “LOGICALLY I’m right” or something. But I’m an idiot and want to be empirical, which means reading dozens of papers that are all maddeningly contradictory. It means going through papers agonizingly carefully because the entire thing might be invalidated by an offhand remark.[1] It means reading paper’s references, and the references’ references, and trawling for followup papers, and reading the followup paper’s other references. It means spending hours hunting down preprints and emailing authors because most of the good stuff is locked away by the academic paper hoarders.

      Being empirical means being painfully aware of the cognitive dissonance in your head. I love TDD. I recommend it to beginners all the time. I think it makes me a better programmer. At the same time, I know the evidence for it is… iffy. I have to accept that something I believe is mostly unfounded, and yet I still believe in it. That’s not the easy way out, that’s for sure!

      And even when the evidence is in your favor, the final claim is infuriatingly nuanced. Take code review! “Code Review works”. By works, I mean “in most controlled studies and field studies, code review finds a large portion of the extant bugs in reviewed code in a reasonable timeframe. But most of the comments in code review are not bug-finding, but code quality things, about 3 code improvements per 1 bug usually. Certain things make CR better, and certain things make it a lot worse, and developers often complain that most of the code review comments are nitpicks. Often CRs are assigned to people who don’t actually know that area of the codebase well, which is a waste of time for everyone. There’s a limit to how much people can CR at a time, meaning it can easily become a bottleneck if you opt for 100% review coverage.”

      That’s a way more nuanced claim than just “code review works!” And it’s way, way more nuanced than about 99% of the Code Review takes I see online that don’t talk about the evidence. Empiricism means being more diligent and putting in more work to understand, not less.

      So one last thought to close this out. Studying software is hard. People bring up how expensive it is. And it is expensive, just as it’s expensive to study people in general. But here’s the thing. We are one of the richest industries in the history of the world. Apple’s revenue last year was a quarter trillion dollars. That’s not something we should leave to folklore and feelings. We’re worth studying.

      [1]: I recently read one paper that looked solid and had some really good results… and one sentence in the methodology was “oh yeah and we didn’t bother normalizing it”

      1. 3

        Hi Hillel! I’m glad you found this, and thank you for taking the time to respond.

        I’m not sure you necessarily need to mount a defense, either. I didn’t consciously intend to set your talk up as the antagonist in my post, but I realize this is sort of what I did. The attitude I’m trying to refute (that empirical science is the only source of objective knowledge about software) is somewhat more extreme than the position you advocate. And the attitude you object to (that software “can’t be studied” empirically, and nothing can be learned this way) is certainly more extreme than the position I hoped to express. I think in the grand scheme of things we largely share the same values, and our difference of opinion is rather esoteric and mostly superficial. That doesn’t mean it’s not interesting to debate, though.

        Re: Omitted variable bias

        You seemed to suggest that research could account for omitted variable bias by “cross-correlating” studies

        • across different companies
        • within one same company before and after adopting/disadopting the practice
        • across different teams within the same company.

        I submit to you this is not the case. Continuing with the CD example, suppose CD doesn’t improve outcomes but the “trendiness” that leads to it does. It is completely plausible for

        • trendy companies to be more likely to adopt CD than non-trendy companies
        • trendy teams within a company to be more likely to adopt CD than non-trendy teams
        • a company that is becoming more trendy is more likely to adopt CD and be trendier before the adoption than after adoption
        • a company that is becoming less trendy is more likely to disadopt CD and be trendier before the disadoption than after

        If these hold, then all of the studies in the “cross-correlation” you describe will still misattribute an effect to CD.

        You can’t escape omitted variable bias just by collecting more data from more types of studies. In order to legitimately address it, you need to do one of:

        • Find some sort of data that captures “trendiness” and include it as a statistical control.
        • Find an instrumental variable
        • Find data on teams within a company that were randomly assigned to CD (so that trendiness no longer correlates with the decision to adopt).

        If you don’t address a plausible omitted variable bias in one of these ways, then basically you have no guarantee that the effect (or lack of effect) you measured was actually the effect of the practice and not the effect of whatever social conditions or ideology led to the adoption of your practice (or something else that those social conditions caused). This is a huge threat to validity, especially to “code mining” studies whose only dataset is a git log and therefore have no possible hope of capturing or controlling the social or human drivers behind the practice. To be totally honest, I assign basically zero credibility to the empirical argument of any “code mining” study for this reason.

        Re: The analogy to medicine

        As @notriddle seemed to be hinting at, professions comprehensively guided by science are the exception, not the rule. Science-based lawyering seems… unlikely. Science-based education is not widely practiced, and is controversial in any case. Medicine seems to be the major exception. It’s worth exploring the analogy/disanalogy between software and medicine in greater detail. Is software somehow inherently more difficult to study than medicine?

        Maybe not. You brought up two good points about avenues of software research.

        Companies do internal investigations on this- Microsoft and IBM especially has a lot of great work in this style.


        In some cases, companies are willing to instrument themselves- see TSP or the NASA data sets.

        I think analysis of this form is miles more persuasive than computer lab studies or code mining. If a company randomly selects certain teams to adopt a certain practice and certain teams not to, this solves the realism problem because they are, in fact, real software teams. And it solves the omitted variable bias problem because the practice was guaranteed to have been adopted randomly. I think much of the reason medicine has been able to incorporate empirical studies so successfully is because hospitals are so heavily “instrumented” (as you put it) and willing to conduct “clinical trials” where the treatment is randomly assigned. I’m quite willing to admit that we could learn a lot from empirical research if software shops were willing to instrument themselves as heavily as hospitals, and begin randomly designating teams to adopt practices they want to study. I think it’s quite reasonable to advocate for a movement in that direction.

        But whether or not we should advocate for more better data/more research is orthogonal to the main concern of my post: in the meantime, while we are clamoring for better data, how ought we evaluate software practices? Do we surrender to nihilism because the data doesn’t (yet) paint a complete picture? Do we make wild extrapolations from the faint picture the data does paint? Or should we explore and improve the body of “philosophical” ideas about programming, developed by programmers through storytelling and reflection on experience?

        It is very important to do that last thing. I wrote my post because, for a time, my own preoccupation with the idea that only scientific inquiry had an admissible claim to objective truth prevented me from enjoying and taking e.g. “A Philosophy of Software Design” seriously (because it was not empirical), and realizing what a mistake this was was somewhat of a personal revelation.

        Re: Epistemology

        Science is about admitting that we are going to make mistakes, that we’re going to naturally believe things that aren’t true, no matter how mentally rigorous we try to be. That’s what makes it so important and so valuable. It gives us a way to say “well you believe X and I believe not X, so which is it?”

        Science won’t rescue you from the fact that you’re going to believe things that aren’t true, no matter how mentally rigorous you try to be. Science is part of the attempt to be mentally rigorous. If you aren’t mentally rigorous and you do science, your statistical model will probably be wrong, and omitted variable bias will lead you to conclude something that isn’t true.

        Science, to me, is merely a toolbox for generating persuasive empirical arguments based on data. It can help settle the debate between “X” and “not X” if there are persuasive scientific arguments to be found for X, and there are not persuasive scientific arguments to be found for “not X” – but just as frequently, there turn out to be persuasive scientific arguments for both “X” and “not X” that cannot be resolved empirically must be resolved theoretically/philosophically. (Or – as I think describes the state of software research so far – there turn out to be persuasive scientific arguments for neither “X” nor “not X”, and again, the difference must be resolved theoretically/philosophically).

        [Being empirical]… means reading dozens of papers that are all maddeningly contradictory. It means going through papers agonizingly carefully because the entire thing might be invalidated by an offhand remark.[1] It means reading paper’s references, and the references’ references, and trawling for followup papers, and reading the followup paper’s other references.

        That’s a way more nuanced claim than just “code review works!” And it’s way, way more nuanced than about 99% of the Code Review takes I see online that don’t talk about the evidence. Empiricism means being more diligent and putting in more work to understand, not less.

        I value this sort of disciplined thinking – but I think it’s a mistake to brand this as “science” or “being empirical”. After all, historians and philosophers also agonize through papers, crawling the reference tree, and develop highly nuanced, qualified claims. There’s nothing unique to science about this.

        I think we should call for something broader than merely disciplined empirical thinking. We want disciplined empirical and philosophical/anecdotal thinking.

        My ideal is that software developers accept or reject ideas based on the strength or weakness of the argument behind them, rather than whims, popularity of the idea, or the perceived authority or “charisma” of their advocates. For empirical arguments, this means doing what you described – reading a bunch of studies, paying attention to the methodology and the data description, following the reference trail when warranted. For philosophical/anecdotal arguments, this means doing what I described – mentally searching for inconsistencies, evaluating the argument against your own experiences and other evidence you are aware of.

        Occasionally, this means the strength of a scientific argument must be weighed against a philosophical/anecdotal argument. The essence of my thesis is that, sometimes, a thoughtful, well-explained story by a practitioner can be a stronger argument than an empirical study (or more than one) with limited data and generality. “X worked for us at Dropbox and here is my analysis of why” can be more persuasive to a practitioner than “X didn’t appear to work for undergrad projects at 12 institutions, and there is not a correlation between X and good outcome Y in a sampling of Github Repos”.

        1. 2

          Hi, thanks for responding! I think we’re mostly on the same page, too, and have the same values. We’re mostly debating the degrees and methods of here. I also agree that the issues you raise make things much more difficult. My stance is just that while they do make things more difficult, they don’t make it impossible, nor do they make it not worth doing.

          Ultimately, while scientific research is really important, it’s only one means of getting knowledge about something. I personally believe it’s an incredibly strong form- if philosophy makes one objective claim and science makes another, then we should be inclined to look for flaws in the philosophy before looking for flaws in the science. But more than anything else, I want defence in depth. I want people to learn the science, and the history, and the philosophy, and the anthropology, and the economics, and the sociology, and the ethics. It seems to me that most engineers either ignore them all, or care about only one or two of these.

          (Anthro/econ/soc are also sciences, but I’m leaving them separate because they usually make different claims and use different ((scientific!)) than what we think of as “scientific research” on software.)

          One thing neither of us have brought up, that is also important here: we should know the failure modes of all our knowledge. The failure modes of science are really well known: we covered them in the article and our two responses. If we want to more heavily lean on history/philosophy/anthropology, we need to know the problems with using those, too. And I honestly don’t know them as well as I do the problems with scientific knowledge, which is one reason I don’t push it as hard- I can’t tell as easily when I should be suspicious.

        2. 3

          What a fantastic response.

          When doctors get involved in fields such as medical education or quality improvement and patient safety, they often have a similar reaction to Richard’s. The problem is in thinking that the only valid way to understand a complex system is to study each of its parts in isolation, and if you can’t isolate them, then should just give up.

          As Hillel illustrated nicely here, you can in fact draw valid conclusions from studying “complex systems in the wild”. While this is a “messier” problem, it is much more interesting. It requires a lot of creativity but also more rigor in justifying and selecting the methodology, conducting the study, and interpreting the results. It is very easy to do a subpar study in those fields, which confounds the perception about the fields being “unscientific”.

          A paper titled Research in the Hard Sciences, and in Very Hard “Softer” Domains by Phillips, D. C. discusses this issue. Unfortunately, it’s behind a paywall.

          1. 3

            Can we study teachers? Can we study doctors and nurses?

            The answer to that question might be “no”.

            When you’re replying to an article that’s titled “The False Promise of Science”, with a bunch of arguments against empirical software engineering that seem applicable to other fields as well, and your whole argument is basically an analogy, you should probably consider the possibility that Science is Just Wrong and we should all go back to praying to the sun.

            The education field is at least as fad- and ideology-driven as software, and the medical field has cultural problems and studies that don’t reproduce. Many of the arguments given in this essay are clearly applicable to education and medicine (though not all of them obviously are, I can easily come up with new arguments for both fields). The fundamental problem with applying science to any field of endeavor is that it’s anti-situational at the core. The whole point of The Scientific Method is to average over all but a few variables, but people operating in the real world aren’t working with averages, they’re working with specifics.

            The argument that software isn’t special cuts both ways, after all.

            I’m not sure if I actually believe that, though.

            The annoying part about this is that, as reasonably compelling as it’s possible to make the “science sucks” argument sound, it’s not very conducive to software engineering, where the whole point of the practice is to write generalized algorithms that deal with many slight variants of the same problem, so that humans don’t have to be involved in every little decision. Full-blown primativism, where you reject Scalable Solutions(R) entirely, has well-established downsides like heightened individual risk; one of the defining characteristics of modernism is risk diffusion, after all.

            Adopting hard-and-fast rules is just a trade-off. You make the common case simpler, and you lose out in the special cases. This is true both within the software itself (it’s way easier to write elegant code if you don’t have weird edge cases) and with the practice. The alternative, where you allow for exceptions to the rules, is decried as bad for different reasons.

            1. 6

              That is absolutely a valid counterargument! In response, I’d like to point out that we have learned a lot about those fields! Just a few examples:

              I’m don’t know very much about classroom teaching or nursing, so I can’t deep-dive into that research as easily as I can software… but there are many widespread and important studies in both fields that give us actionable results. If we can do that with nursing, why not software?

              1. 1

                To be honest, I think you’re overselling what empirical science tells us in some of these domains, too. Take the flipped classroom one, since it’s an example I’ve seen discussed elsewhere. The state of the literature summarized in that post is closer to: there is some evidence that this might be promising, but confidence is not that high, particularly in how broadly this can be interpreted. Taking that post on its own terms (I have not read the studies it cites independently), it suggests not much more than that overall reported studies are mainly either positive or inconclusive. But it doesn’t say anything about these studies’ generalizability (e.g. whether outcomes are mediated by subject matter, socioeconomic status, country, type of institution, etc.), suggests they’re smallish in number, suggests they’ve not had many replication attempts, and pretty much outright says that many studies are poorly designed and not well controlled. It also mentions that the proxies for “learning” used in the studies are mostly very short-term proxies chosen for convenience, like changes in immediate test scores, rather than the actual goal of longer-term mastery of material.

                Of course that’s all understandable. Gold-standard studies like those done in medicine, with (in the ideal case) some mix of preregistration, randomized controlled trials, carefully designed placebos, and longitudinal follow-up across multi-demographic, carefully characterized populations, etc., are logistically massive undertakings, and expensive, so basically not done outside of medicine.

                Seems like a pretty thin rod on which to hang strong claims about how we ought to reform education, though. As one input to qualitative decision-making, sure, but one input given only its proper weight, in my opinion significantly less than we’d weight the much better empirical data in medicine.

            2. 2

              Dammit, man. That was a great response. I don’t think I’ll ever comment anything anywhere just so my comment won’t be compared to this.

              1. 1

                My favorite software book is Data and Reality, which is a philosophical investigation into the nature of information representation.

                A beautiful book, one of my favorites as well.

                rest of post….

                While I thought the article articulated something important which I agree with, its conclusion felt a bit lazy and too optimistic for my taste – I’m more persuaded by the POV you’ve articulated above.

                While we’re making analogies, “writing software is like writing prose” seems like a decent one to explore, despite some obvious differences. Specifically relevant is the wide variety of different and successful processes you’ll find among professional writers.

                And I think this explains why you might be completely right that something like TDD is valuable for you, even though empirical studies don’t back up that claim in general. And I don’t mean that in a soggy “everyone has their own method and they’re all equally valid” way. I mean that all of your knowledge, the way think about programming, your tastes, your knowledge of how to practice TDD in particular, and on and on, are all inputs into the value TDD provides you.

                Which is to say: I find it far more likely that TDD (or similar practices with many knowledgeable, experienced supporters) have highly context sensitive empirical value than none at all. I don’t foresee them being one day unmasked by science as the sacred cows of religious zealots (though they may be that in some specific cases too).

                For something like TDD, the “treatment” group would really need to be something like “people who have all been taught how to do it by the same expert over a long enough time frame and whose knowledge that expert has verified and signed off on.”

                I’m not shilling for TDD, btw – just using it as a convenient example.

                The broader point is that effects can be real but extremely hard to show experimentally.

                1. 1

                  “We’re not basing our worldview off a single study. We’re doing many of them, in many different contexts, to get different facets of what the answer might actually be.”

                  That’s exactly what I do for the sub-fields I study. Especially formal proof which I don’t understand at all. Just constantly looking at what specialists did… system type/size, properties, level of automation, labor required… tells me a lot about what’s achievable and allows mix n’ matching ideas for new, high-level designs. That’s without even needing to build anything which takes a lot longer. That specialists find the resulting ideas worthwhile proves the surveys and integration strategy work.

                  So, I strongly encourage people to do a variety of focused studies followed by integrated studies on them. They’ll learn plenty. We’ll also have more interesting submissions on Lobsters. :)

                  “When someone says “you are unprofessional if you don’t use TDD” or “Dynamic types are immoral”, I know, with scientific certainty, that they don’t actually know. “

                  I didn’t think about that angle. Actually, you got me thinking maybe we can all start telling that to new programmers. They get warned the field is full of hype, trends, etc that usually don’t pan out over time. We tell them there’s little data to back most practices. Then, experienced people cutting them down or getting them onto new trend might have less effect. Esp on their self-confidence. Just thinking aloud here rather than committed to idea.

                  “Science is about admitting that we are going to make mistakes”

                  I used to believe science was about finding the truth. Now I’d go further than you. Science assumes we’re wrong by default, will screw up constantly, and are too biased or dishonest to review the work alone. The scientific method basically filters bad ideas to let us arrive a beliefs that are justifiable and still might be wrong. Failure is both normal and necessary if that’s the setup.

                  The cognitive dissonance make it really hard like you said. I find it a bit easier to do development and review separately. One can be in go mode iterating stuff. At another time, in skeptical mode critiquing the stuff. The go mode also gives a mental break and/or refreshes the mind, too.

                  1. 1

                    You’d be surprised. “Two comparisons of programming languages”, in “making software”, does this with nine teams (but only for one day).

                    My reading (which is congruent with my experiences) indicates a newly-put-together team takes 3-6 months before productivity stabilizes. Some schools of management view this as ‘stability=groupthink, shuffle the teams every 6 months’ and some view it as ‘stability=predictability, keep them together’. However, IMO this indicates to me that you might not be able to infer much from one day of data.

                    1. 2

                      To clarify, that specific study was about nine existing software teams- they came to the project as a team already. It’s a very narrow study and definitely has limits, but it shows that researchers can do studies on teams of professionals.

                    2. 1

                      People bring up how expensive it is. And it is expensive, just as it’s expensive to study people in general. But here’s the thing. We are one of the richest industries in the history of the world. Apple’s revenue last year was a quarter trillion dollars. That’s not something we should leave to folklore and feelings. We’re worth studying.

                      I don’t think I understand what you’re saying. Software is expensive, and for some companies, very profitable. But would it really be more profitable if it were better studied? And what exactly does that have to do with the kinds of things that the software engineering field likes to study, such as defect rates and feature velocities? I think that in many cases, even relatively uncontroversial practices like code review are just not implemented because the people making business decisions don’t think the prospective benefit is worth the prospective cost. For many products or services, code quality (however operationalized) makes a poor experimental proxy for profitability.

                      Inasmuch as software development is a form of industrial production, there’s a huge body of “scientific management” literature that could potentially apply, from Frederick Taylor on forward. And I would argue it generally is being applied too: just in service of profit. Not for some abstract idea of “quality”, let alone the questionable ideal of pure disinterested scientific knowledge.

                      1. 1

                        Mistakes are becoming increasingly costly (e.g., commercial jets falling from the sky) so understanding the process of software-making with the goal of reducing defects could save a lot of money. If software is going to “eat the world”, then the software industry needs to grow up and become more self-aware.

                        1. 1

                          Aviation equipment and medical devices are already highly regulated, with quality control processes in place that produce defect rates orders of magnitude less than your average desktop or business software. We already know some things about how to make high-assurance systems. I think the real question is how much of that reasonably applies to the kind of software that’s actually eating the world now: near-disposable IoT devices and gimmicky ad-supported mobile apps, for example.

                    1. 15

                      I’m a bit disappointed that the interviewer didn’t mention a single question regarding addiction or any ethical dimension. It’s kind of been assumed that not liking pornography is just a conservative, right-wing thing, but I don’t think that’s correct. I personally perceive it to be pushing harmful stereotypes (both as in what women should look like, or how intimacy should look like), and then there’s the problem with trafficking, and never knowing what’s actually going on behind the scenes. Chomsky says it well.

                      Setting aside things like these, which should be enough to say something isn’t right, but knowing the digital world (where creating addictions has become a common and often even necessary business model) reading

                      you have to be clever to innovate at the bleeding edge of the web.

                      makes me somewhat uneasy. Especially a front end developer should have to think about these questions. They are the ones tasked with creating “seamless experiences”, ultimately, disregarding the influence it has on people’s daily and personal life’s. I don’t think the interviewer should have just glossed over this. YouTube has hateful or harmful videos, but their raison d’être isn’t hosting them. PornHub will have it a bit harder that hosting and spreading pornography isn’t a big part of what they are.

                      From the technical perspective it’s somewhat interesting, I guess. It’s about the problems of high-demand video streaming, probably above the level of most other video sites, but still way below sites like YouTube. That’s like having an interview with a slaveholder on what kind of whips they have found to have the best quality CIA agent on what the best strategies are to manipulate a foreign election.

                      Edit: Rewrote a few sentences to avoid confusion, and replaced my analogy with a different one.

                      1. 13

                        I’m a bit disappointed that the interviewer didn’t mention a single question regarding addiction or any ethical dimension.

                        Porn has been around a really long time. I’m pretty sure there’s nothing new to be discovered or discussed almost anywhere on earth on the topic, much less here.

                        Like, the human race has brute-forced about every part of that solution space we can. There is not a dirty thought we can have that hasn’t occurred to scores of other people at one point in history or another–of this I’m certain.

                        1. 21

                          Porn has been around a really long time.

                          Not in the way it is now, as an endless torrent on demand. Modern porn has demonstrably changed society in ways that ancient porn did not. For example, women now believe that pubic hair is unclean and as a result of excessive pubic hair removal are getting health problems that pubic hair can prevent.

                          Also, just being around forever does not categorise something as innocuous or beneficial.

                          1. 3

                            Hairstyles have been coming and going in fads ever since we left the trees and discovered hair can be cut and washed. Having this apply also to pubic hair is not exactly a huge change.

                            1. 3

                              As the article notes, gynecologists disagree, but what do they know, I guess.

                          2. 8

                            Like comparing chewing coca leaves to mainlining cocaine.

                            1. 3

                              Quantity acquires a quality of its own, you know. Not to mention that quality is altogether different as well: 4K video isn’t the same as a blurry black and white photo. There’s a strange blindness to this effect in the tech industry, whether it comes to social media, endless tsunami of content on Netflix, or indeed porn. Much like Facebook’s idea that more communication is unconditionally better has backfired spectacularly, maybe it’s the same with porn. And then of course there’s also all the engineered “engagement” in all these areas. Don’t be so quick to say it’s all totally harmless.

                              1. 0


                              2. 6

                                I’m a bit disappointed that the interviewer didn’t mention a single question regarding addiction or any ethical dimension.

                                The audience is web developers wanting to read something interesting about web development at a big company. They also want most of them to enjoy the article. Talking about the damage they might be doing doesn’t serve either purpose. Most would’ve just clicked the little X or otherwise moved on.

                                There’s been a lot of good writing on that subject for anyone looking for it. The key words are easy to guess.

                                1. 6

                                  You’re kinda circling back to the same point. Yes, talking about ethical implications of our jobs is hard, and uncomfortable, but it’s necessary. Of course nost people don’t want to do it, off course most people don’t want to read about it. But it’s our responsibility to talk and to read about those things. “I don’t like doing it” is not a valid excuse for not doing something it’s your responsibility to do.

                                  That said, the comparison with slavery is a bit out of place, imo.

                                  1. 10

                                    You’re doing that trick many people do here where it becomes all or nothing in every post, forum, etc. The stress of introspecting on these topics make many people do it at certain times and read relaxing content at other times. They’re fine splitting it up. Dare I’d say most people prefer that based on that simply being most popular way content is done online.

                                    Then, other people think they should be mentally engaged on these topics at all times in all articles, forums, etc due to their importance. They also falsely accuse people of not caring about social responsibilities if they don’t discuss them in every article where they might come into play. You must be in that group. Author of the original post and their audience is not. Hence, the separation of concerns that lets readers relax just focusing about web tech before optionally engaging with hard realities of life at another time in another article.

                                  2. 2

                                    This isn’t a “what if my open source library was used by some military”-kind of question, I think that there is a much stronger connection between the two. Front end design is related to user behaviour, and I still consider this relation to be a technical question (UI design, user protection, setting up incentives, …).

                                    If the interviewer had asked these questions, and the interviewee had chosen not to comment, that would have been something, but the article currently just brushes it away affront by saying “ Regardless of your stance on pornography, …”.

                                    1. 3

                                      I’m a bit disappointed that the interviewer didn’t mention a single question regarding addiction or any ethical dimension

                                      A tech-related, Lobsters-worthy discussion of the topic would focus on how they collected user behavior, analyzed it, measured whether they were reaching their goals, strategized for how to achieve them, and specific methods of influence with associated payoffs. It would actually be more Barnacles-like since marketing is behind a lot of that. These technical and marketing techniques are politically-neutral in that they are used by many companies to measure and advance a wide range of goals, including pornography consumption. They could be discussed free-standing with little drama if the focus was really on the technology.

                                      You were doing the opposite. That quote is an ethical question, even says so, where you have political views about pornography consumption, you wanted theirs explored, and you might have had some goal to be achieved with that. The emotional language in the rest of your post further suggested this wasn’t about rational analysis of a technology stack. You also didn’t care what the writer or any of their readers thought about that. So, I countered representing the majority of people who just wanted to read about a web stack. A mix that either doesn’t care about ethics of porn or does with it being a depressing topic they want to handle at another time.

                                      I was on 2nd cup of coffee when you wanted me to be thinking about lives being destroyed instead of reading peaceful and interesting things easier to wake up to. Woke up faster in a different way. Oh well. Now, I’m off this drama to find a Thursday submission in my pile.

                                      1. 2

                                        A tech-related, Lobsters-worthy discussion of the topic would focus on how they collected user behavior, analyzed it, measured whether they were reaching their goals, strategized for how to achieve them, and specific methods of influence with associated payoffs.

                                        I think these kinds of things were missing from the article. I know this isn’t the place to discuss pornography, and I try not to go into it in the comments. What I just brought up was a disappointment in the style and focus of the interview, and it being one-sided.

                                        The emotional language in the rest of your post further suggested this wasn’t about rational analysis of a technology stack.

                                        Well I do think it’s important, so I apologize for being a tad emotional. But other than what I wrote, I don’t have anything else to contribute. I neither run nor plan to run a streaming site, so I end up not having too strong opinions on what is being used in the backend stack ^^.

                                        A mix that either doesn’t care about ethics of porn or does with it being a depressing topic they want to handle at another time.

                                        I understand that, that’s why I prefixed my top comment with what you quoted. I furthermore feel obligated to apologise if anyone had to go through any inconvenience thinking about the “ethics of porn” because of my comment, I guess? No but seriously, bringing up a concern like this, which I explicitly tried to link back to a technical question, should be ok.

                                        1. 1

                                          “I furthermore feel obligated to apologise if anyone had to go through any inconvenience thinking about the “ethics of porn” because of my comment, I guess? No but seriously, bringing up a concern like this, which I explicitly tried to link back to a technical question, should be ok.”

                                          There’s quite a few people here that are OK with it. I’m not deciding that for anyone. I just had to remind you that caring people who want a break in some places exist and that you do more good by addressing the porn problem where it’s at. I appreciate you at least considering the effect on us.

                                          “I neither run nor plan to run a streaming site”

                                          The main problem is consumer side where there’s mass demand following by all types of supply and clever ways to keep people hooked. You can’t beat that since they straight-up want it. What you might do is work on profiles for porn sites with tools such as NoScript that make them usable without the revenue-generating ads. Then, lots of people push for their use. If there’s any uptake, they get a temporary hit in their wallet but maybe an offset with ad-free Premium. I’m not sure the effectiveness. I just know they’re an ad model with tools existing to attack that.

                                          Griping about it on technical sites won’t change anything because… most viewers aren’t on technical sites and those that are rarely changed. So, it’s just noise. Gotta work on porn laws, labor protections for those involved, ethical standards in industry itself, ad blocking, etc.

                                  3. 6

                                    If you would like to discuss the ethical aspects go to a different forum. I would rrecommend the community around Thaddeus Russell’s podcast for a critical and reasoned take from people that actually interact with sex workers https://www.thaddeusrussell.com/podcast/2

                                    1. 3

                                      I’ve mentioned it elsewhere, but I’m not here to discuss the ethical aspects, not am I in a position to be able to. My comments are related to the interviewer and his choice of questions.

                                      1. 1

                                        Your gave opinions, stated as scare-hints without support:

                                        “then there’s the problem with trafficking,”

                                        “which should be enough to say something isn’t right,”

                                        … and then based upon the now well-built pretext that porn “isn’t right” (and is therefore ethically ‘wrong’) - you commented on what the interviewer should have done - i.e. they should have had the same opinions and conceptions as yourself - and they should have turned the interview into one about ethics.

                                        The interview was interesting to read, because of the info about the tech. As bsima says, please take ethical discussion elsewhere.

                                        1. 2

                                          As you said, I prefixed the controversial parts by saying that it was my opinion. But I don’t think that the interviewer must have shared my views. The point I was raising was that I thought it wasn’t appropriate for the interview to just ignore a quite relevant topic, since this was about PornHub specifically, not their parent company.

                                          IMO, a just final question like

                                          “What are you doing to enforce age restrictions?”


                                          “Due to recent reports, do you think that doing something against pornography addiction among younger generations can be tackled technically or does it need more (social) effort?”

                                          would have been more than enough, as to just show this is being considered. I’m not a journalist, so I don’t know how these questions could be phrased better, but I hope you do get my point.

                                        2. 1

                                          I’m not here to discuss the ethical aspects

                                          …and yet, it’s the ethical aspects that you brought up.

                                          1. 3

                                            Looking at this thread, I didn’t respond to people who started talking about the harmfulness of pornography or the lack thereof. This even though I would like to – yet I understand that it is off topic. In fact most of this sub-thread has been more about the meta-discussion.

                                            All I can say is that I will be more careful not be too provoke these kinds of discussions in the future. I was thinking critically a lot about the topic the last few months, so my comment might not have been as neutral as some might have wished.

                                      2. 5

                                        That’s like asking an interview with a slaveholder on what kind of whips they have found to have the best quality.

                                        This is more than a little hyperbolic.

                                        1. 4

                                          My analogy is that the direct consequences of technical questions are being more or less ignored, which I think is fair in both questions. Of course it’s not identical, but that’s stylistic devices for you.

                                        2. 2

                                          I could come up with quite a few objections to pornography, but the chap in your video link is not only not convincing, he is also hinting that he watches porn even though he denies it. He backs up his statement “porn is degrading to women” by qualifying “just look at it” which implies that he does that enough to have an opinion.

                                        1. 1

                                          If you’re importing from shapes to register implementations of get_area, and them the maintainer of shapes decides to implement a “get_area friendly” new shape class, won’t that cause a infinite import loop? Because area_calculation imports shapes and then shapes imports area_calculation?

                                          1. 0


                                            1. 1

                                              That’s not a very helpful reply.

                                              1. 0

                                                You’re right.

                                          1. 1

                                            Wait. So, you still have no diagnosis nor treatment in the UK? Man, doctors can suck =(

                                            1. 2

                                              I quite liked this. Thinking about using it to build my own site (currently trying to use lektor, but I think it might be too complicated).

                                              Just one question: Is there any way to preview the webpage it will generate?

                                              Edit: Clarifying, can I add/edit files locally, preview the website that will be generated, and then push to github? I understand that it’s not in the scope of your project to do that, but, is there a way? Have you tried it?

                                              1. 2

                                                Since Precis is built over Github Pages which in turn is built over Jekyll, it is possible to preview it locally. Refer to this article about how to set it up.

                                              1. 14

                                                Thanks, I feel like a dick, now.

                                                On a serious note, that hit me right in the feels. I wouldn’t go as far as saying that I am overconfident, but I’m definitely a loudmouth, and tend to argue to exhaustion when I think I’m right.

                                                I’ve been working for a while in recognizing that I might be wrong and try to clearly communicate that I am open (and in fact, often hoping) to be proven wrong, but it’s a process, and I can’t help but wonder how often have I just been a massive dick and prevented other people from even throwing an idea =(

                                                1. 8

                                                  I’m almost exactly the opposite. I realize that usually my preferences boil down to: “I like this way because I’m used to it”, or “I don’t think it matters”. I used to be the most experienced C# programmer on my team. My teammates used to ask me questions like “Should I assign a type explicitly or just use ‘var’?” any I would say that that’s a personal preference and it doesn’t really matter. Another programmer with a much more pronounced opinion joined the team, and I noticed that people liked his answers a lot more. Sometimes people just like to be told what to do, especially when the consequences of the choices aren’t so clear.

                                                  1. 5

                                                    Sometimes people just like to be told what to do, especially when the consequences of the choices aren’t so clear.

                                                    This, and also cases where the consequences on either side of a tradeoff are so minor, that the energy spent deliberating them out is costlier than just making a call and moving on. I spent far longer learning this, and fixing my behavior, than I wish I had.

                                                    On so many of these low-impact-low-cost details, where I did not strongly care, where I could expect another senior to reasonably disagree (even just for reasons of “this is what I am used to instead”), I would give teammates a full-depth, longwinded explanation, only to end in an equivocation and let them decide. Maybe one out of a dozen times they learned something, but often I was wasting people’s time when they just wanted a boolean result from the ask_swifthand function.

                                                    The first step in fixing this was realizing why I always led with longwinded explanations. It turned out to be misapplied empathy (which I assume-by-default that I lack, hence it took a while to realize).

                                                    I personally value knowing the detailed ins-and-outs wherever possible, and so I saw extending a full explanation to another person as a sign of respect: share all the learning, and help them make their own decision. But when that comes by wasting their time (on a low-impact-low-cost choice), was not being perceived that way.

                                                    Change was slow. I first changed my explanations to lead with the decision before launching into the explanation, giving a TL;DR to frame their expectation. After some time doing this, I began leading with the decision and then asking “There are reasons I could dive into, but they are subtle and inconsequential. So I’ll leave it there, unless you are curious?” followed by a long, awkward pause while I wait for an answer.

                                                    Due to some personality quirks that pause is the hardest part for me, but it gets the job done. It balances respecting their time by giving them the option to walk away with my desire to extend a courtesy that I would (personally) value of learning more.

                                                    Ironically, I do not always extend this sort of preemptive empathy to the rest of my life’s conversations. The last paragraph in the article really hit home, as I know friends and family often feel my SOLH is overconfidence layered with stubbornness.

                                                    1. 3

                                                      Sometimes people just like to be told what to do, especially when the consequences of the choices aren’t so clear.

                                                      Newbies need to be fed opinions because they don’t have enough experience to have any of their own, and the ones they might have at the moment are more likely to be wrong than right. Like, yes, you can write thousand-line subroutines in Python, that’s certainly something the language allows, but more mature opinion will state that writing smaller subroutines is better for reasons of ease of modification a neophyte hasn’t run into yet.

                                                      Gnomonic pronouncements make things go faster, but once the learner has some experience of their own, pushback is to be expected and should be encouraged. Except with things like styleguides. Those are completely arbitrary and set in stone for precisely that reason.

                                                      So teachers need to have strong opinions because they can’t go over every single thing when they answer a single question, but those opinions must be held loosely enough that students can successfully challenge them as they gain enough knowledge to exercise their own agency.

                                                      1. 2

                                                        This is one thing that’s true: people like to be told what to do. People should be encouraged to think for themselves. The best of both worlds is perhaps by explaining the difference and explaining why you lean the way you do. That way you teach thought and give a straight answer.

                                                      2. 5

                                                        tend to argue to exhaustion

                                                        that doesn’t sound “loosely held” :)

                                                        1. 1

                                                          I recently had an argument that went on for an hour until I conceded from frustration. Once we switched from the what to the how they immediately took to my original argument. Loosely held seems like it can be in the eye of the beholder.

                                                          1. 1

                                                            Well, for some definition of loosely =P

                                                          2. 3

                                                            I am open (and in fact, often hoping) to be proven wrong

                                                            Say that clearly and directly. Tell the other person that you are not feeling personally attacked and hope to be proven wrong.

                                                          1. 4

                                                            On one hand, that’s kinda cool. I know vaguely that there’s precedent to running linux in user space, so ain’t exactly news, but it’s a good idea, because emulation would always be a bit behind.

                                                            On the other hand … this feels like way friendlier embrace, but still embrace-ish. Can’t help but wonder what the extinguish phase will look like.

                                                            1. 9

                                                              There is no “extinguish”, at least not in 2018’s world. The world has changed since back when Microsoft was all powerful.

                                                              Just look at the tables in this article: https://www.joelonsoftware.com/2003/08/01/rick-chapman-is-in-search-of-stupidity/

                                                              2001 annual revenue: Microsoft $23bn. Everyone else in the top 10, put together, less than $23bn (!).

                                                              2018 annual revenue: Microsoft $110bn, Apple $265bn, Alphabet (Google) $136bn, Amazon $232bn, IBM $79bn, Alibaba $39bn, Samsung $210bn, Tencent $50bn, Sony $70bn, Nintendo $10bn.

                                                              Those are their competitors, in various domains: OSes, browsers, cloud platforms, development tools, games, etc. Notice how 3 of them are 2x the size of Microsoft. Several of them are smaller but they’re market leaders in their markets. Many of those competitors have a vested interest in Linux being healthy and successful.

                                                              Microsoft could easily bully Adobe around. They can’t bully Apple or Google or Amazon or Samsung.

                                                              The world has changed.

                                                              To make things more interesting, their competitors have learned from Microsoft so Apple or Google are just as big a bullies as Microsoft was, if not more, but they do it with a “gentle touch” (better PR).

                                                              1. 1

                                                                Thanks for the numbers, that’s an interesting point =)

                                                            1. 3

                                                              Anything Gary Bernhardt says, which boils down to “practice, practice, practice” anyway.

                                                              Also, no wall of text in the slides, definitely do not read from them. Make sure the colors are legible.

                                                              If you’re sure your jokes are good, go for them, but unless you’re really funny, they probably aren’t. I rather see a clearly explained talk, with good content but potentially “boring” than someone trying to be funny and engaging but only succeeding half the time.

                                                              Also, avoid live demos like the plague. Murphy hates them.

                                                              Other than that, good luck, read the other comments, they’re way better than mine. Keep cool and it will be alright =)

                                                              1. 9

                                                                I’m doing this little project for a job application, it’s a tiny etl system to load some files with coordinates, geolocate them and save in a database.

                                                                It’s so fun, though. I’m using flask, and trying to apply some architecture ideas I’ve read about, and it’s been a blast, really. In fact, I’m probably not even taking the job, because I got another, better offer, but I’m still working on this project just cos’ now I wanna see how it ends up!

                                                                Been doing C# and Powershell at work, and they’re fine, really, but man, did I miss python, and specially flask.

                                                                1. 1

                                                                  Any support for mobile? I found that I rarely read PDFs on the desktop/laptop.

                                                                  1. 1

                                                                    It has a browser app you could try to use on mobile. I’m not sure how well it supports touch interface, as I haven’t used that one yet. When I log in with Google just now to try it it doesn’t work – it looks like the auth token isn’t properly sent back to the app, I guess.

                                                                    1. 1

                                                                      Looks like people are using it on mobile, based on what I see here: https://github.com/burtonator/polar-bookshelf/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen+mobile

                                                                      1. 1

                                                                        I tried opening the web app on my phone’s chrome browser. It looks good but the PDFs don’t open.

                                                                  1. 3

                                                                    Virtualenv is nice if you develop a server, but what would you use for some small command line tools?

                                                                    For example, I have this 200 lines script which parses some CI artefacts and generates a CSV output. This is fine with just the Python standard lib. Now I would like to generate an Excel sheet but that requires an external package. The easiest way would be copy & paste? Better options?

                                                                    1. 1

                                                                      Depends how much upfront work the users are willing to do. If you can convince/guide them to install pipsi, then you’re good: just package your utilities as python packages, and have them install it with pipsi. I think you can even send them the package as a zip, so you don’t even need PyPI.

                                                                      If that’s too much (and sometimes it is), then you’re just screwed. Either take the time to use something like PyInstaller, for Windows, and snap/flatpack/deb/rpm, for Linux, or give up.

                                                                      1. 3

                                                                        pipsi is basically unmaintained. I would suggest giving pipx a try instead.

                                                                      2. 1

                                                                        This is the use case for packaging: you have some code, it has at least one dependency that isn’t part of Python itself, and you want to distribute it for use on other computers (possibly, though not necessarily, by other people).

                                                                        The answer there is to build a package, and then install that package on each computer that needs to run the code. The standard approach to this is to use setuptools, write a setup.py file which specifies what to package and what the dependencies are, and use it to generate the package (preferably a wheel), then use pip to install that package on other machines (you do not need to upload the package to a public index; you can distribute the package any way you like, and people who have a copy of it can pip install from it). There are alternative packaging tools out there, and fans of particular ones will recommend them, but this is the standard workflow for Python.

                                                                      1. 6

                                                                        I don’t think the description for pyenv is quite correct. While you can use pyenv plugins to manage virtualenvs, the main feature is managing python versions. Having any version or implementation (pypy, jython, etc) available, and be able to set any of those as the global python is the main goal of pyenv, dealing with virtualenvs is just a nice extra, really.

                                                                        Other than that, nice write up =)

                                                                        1. 3

                                                                          FWIW I use pyenv for three things:

                                                                          1. Creating and managing virtualenvs tied to specific Python versions (so that when I’m developing something I know I’m on exactly the same Python version the production environment will use), and
                                                                          2. Providing the appropriate Python interpreter versions for tox to use in creating and managing its virtualenvs.
                                                                          3. Setting my global default python to be whatever the latest is (currently 3.7).
                                                                          1. 2

                                                                            Yeah maybe it can be further clarified. I use environments always with the same python version but different dependencies versions so the way I think about them is maybe not representative of the common use cases.

                                                                            1. 2

                                                                              Just curious why you would use pyenv for that instead of, say, virtualenv?

                                                                              1. 2

                                                                                Personally I don’t. I think that for some people it saves some clicks and mental overhead and I can see why but I personally don’t use it because I need to make lot of switches between virtualenvs during my workflow (because rebuilding the containers appropriately would take too much time) so I prefer control over automation.

                                                                            2. 1

                                                                              anyway on a comment on reddit they explained my mistake and yes, I wrote something that was plain wrong. Now it should be correct. What I described is apparently a plugin called pyenv-virtualenv

                                                                            1. 2

                                                                              This lady has some very interesting ideas about it, look her (and her company) up: https://twitter.com/mipsytipsy

                                                                              1. 32

                                                                                Each side of this debate classifies the other as zealous extremists (as only developers can!), but both of them miss the crux of the matter: Git and its accompanying ecosystem are not yet fit for the task of developing modern cloud-native applications.

                                                                                So, let me get this straight: Because your source control system doesn’t have innate knowledge of the linkages between your software components, that means it’s not up to the task of developing modern “cloud native” (God that term makes me want to cringe) applications?

                                                                                I think not. Git is an ugly duckling, its UX is horrible but the arguments the author makes are awfully weak.

                                                                                IMO expecting your VCS to manage dependencies is a recipe for disaster. Use a language that understands some kind of module and manage your dependencies there using the infrastructure that language provides.

                                                                                1. 11

                                                                                  well said. I dislike Git too but for different reason - the source code is somewhat of a mess

                                                                                  a hodgepodge of C, Python, Perl and Shell scripts

                                                                                  Git is the perfect project for a rewrite in a modern language like Go, Rust, Nim or Julia. A single Git binary similar to Fossil would make adoption and deployment much better.

                                                                                  1. 18

                                                                                    I think at this point Git demonstrates that skipping on the single binary rhetoric doesn’t actually hamper adoption at all.

                                                                                    1. 8

                                                                                      Bitkeeper was a single binary - and it had a coherent command set. I miss it.

                                                                                      1. 6

                                                                                        It still exists and is licensed under Apache 2.0: https://www.bitkeeper.org/

                                                                                        The only issue you have is no public host other than bkbits supporting bk.

                                                                                        1. 1

                                                                                          Also no support in most IDEs.

                                                                                          I know many will point to the command line but having integrated blame/praise, diff, history etc is awesome.

                                                                                          1. 2

                                                                                            Honestly, the bigger beef I have with it is how little it comes with an installer and is difficult to package.

                                                                                        2. 5

                                                                                          I think fossil has that…

                                                                                        3. 0

                                                                                          I thought you are not supposed to use python because that would mean more dependencies… :P

                                                                                        4. 3

                                                                                          Arguments are indeed weak, as what is “cloud native”? However, I think he’s onto something – maybe the problem is not just Git, but everything around it as well? I mean, one could create a big giant monorepo in Git, but the rest of the tooling (CI especially) will still do the full checkout and won’t understand that there are different components. Monorepos make a lot of sense, however, it seems to me that we’re trying to use popular tools to tackle the problem they are not meant to solve (that is, Git being a full replacement for SVN/SVK/Perforce and handling monorepos).

                                                                                          1. 3

                                                                                            I don’t personally think monorepos make a lot of sense, and I think multi-repos are the way to go. If each separate piece is its own project and you let the language’s packaging / dependency management system handle the rest, I don’t see the problem.

                                                                                            Examples I can think of where my point applies are Python, Ruby, Perl or Java. Unless maybe you’re using a language with no notion of packages and dependencies - C/C++ perhaps? I don’t see the issue.

                                                                                            1. 8

                                                                                              The friction in coordinating branches and PRs across multiple repos has been an issue on every team I’ve worked on. Converting to a monorepo has been a massive improvement every time I’ve done it. Either you’ve used hugely different processes or you’ve never tried using a monorepo.

                                                                                              1. 1

                                                                                                The friction in coordinating branches and PRs across multiple repos

                                                                                                That’s a symptom that the project is not split across the correct boundaries. This is not different from the monolith-vs-services issue.

                                                                                                Amazon is a good example of splitting a complex architecture. Each team runs one or very few services each with their repos. Services have versioned APIs and PRs across teams are not needed.

                                                                                                1. 1

                                                                                                  If you have a mature enough project such that every repo has a team and every team can stay in its own fiefdom then I imagine you don’t experience these issues as much.

                                                                                                  But even so, the task of establishing and maintaining a coherent split between repos over the lifetime of a project is non-trivial in most cases. The multi-repo paradigm increases the friction of trying new arrangements and therefore any choices will tend to calcify, regardless of how good they are.

                                                                                                  I’m speaking from the perspective of working on small to mid-sized teams, but large engineering organizations (like Amazon, although I don’t know about them specifically) are the ones who seem to gain the most benefit from monorepos. Uber’s recent SubmitQueue paper has a brief discussion of this with references.

                                                                                                2. 1

                                                                                                  That’s interesting. Every team I’ve ever worked on had its architecture segmented into services such that cross branches and PRs weren’t an issue since each service was kept separate.

                                                                                                3. 6

                                                                                                  The advantage of a monorepo is that a package can see all the packages depending on it. That means you can test with all users and even fix them in a single atomic commit.

                                                                                                  The alternative in a large organisation is that you have release versions and you have to support/maintain older versions for quite some time because someone is still using them. Users have the integration effort whenever they update. In a monorepo this integration effort can be shifted to developer who changes the interface.

                                                                                                  I don’t see how you could do continuous integration in a larger organization with multiple-repos. Continuous integration makes the company adapt faster (more agile with a lowercase a).

                                                                                                  1. 4

                                                                                                    Even if you use a language that has good (or some) package support, breaking a project into packages is not always easy. Do it too soon, and it will be at the wrong abstraction boundary and get in the way of refactoring, and to correct you’ll have to either loose historic, or deal with importing/exporting, which ain’t fun.

                                                                                                    But if all your packages/components are in a single repo, you’ll still might get the boundaries wrong, but the source control won’t get much in the way of fixing it.

                                                                                                  2. 1

                                                                                                    100% on the surrounding tooling. CI tooling being based around Git means that a lot of it is super inflexible. We’ve ended up splitting repos just to get CI to do what we need it to do, and adding friction in surrounding processes.

                                                                                                    A rethink of the ecosystem would be very interesting

                                                                                                    1. -1

                                                                                                      Came here to CTRL+F perforce, was not disappointed

                                                                                                  1. 2

                                                                                                    This post (on medium.com…..) seems to be the first post of jimjh, the author of the article, immediately after joining lobste.rs (post is 5hrs old, account is 5hrs old), and there has been no other community engagement since.

                                                                                                    Flagged as spam to alert mods.. Maybe it’s time to consider a cool-down period between joining and posting articles?

                                                                                                    1. 17

                                                                                                      On the flip side, I lurked for a year before asking a friend for an invite. They might have some understanding of the community even if they have a new account. Just a thought.

                                                                                                      1. 0

                                                                                                        Also, it’s a good post (Brent).

                                                                                                    1. 13

                                                                                                      Rust is superb for these cases, where proper memory management is important. Even preventing you from creating accidental data races, unlike runtime languages such as Java or C#.

                                                                                                      I agree that you can’t blame developers for such bugs. The best of the best developers make mistakes, as bigger applications can become super complex when talking about memory.

                                                                                                      I do blame developers for complaining about memory bugs in C(++) programs though, when choosing a language guaranteeing memory safety like Rust was/is a viable option.

                                                                                                      1. 1

                                                                                                        Was/is it, though? How often do programmers actually get to choose programming languages or tools to a project? From my (limited, sure) experience, not very often.

                                                                                                        Also, technical merit is not the only parameter in determining the best tool for a job. New languages have a adoption cost, and a maintenance cost (i.e., how hard is it gonna be to hire more people to work with it). This has to be factored in with deadlines, and since times is money, the final decision is pretty much never made by the programmers.

                                                                                                        So, no, I don’t think it’s valid to blame programmers for “choosing” c/c++ when that decision is so often not made by them. At least it’s not ok without some extra qualifiers or something.

                                                                                                      1. 1

                                                                                                        Hopefully it can be pre-hooked so that no one can commit with this statement present in the git repo ;)

                                                                                                        1. 4

                                                                                                          I don’t think this warrants such extreme measures, but: it probably has it’s own node type when parsed through ast.parse, so, it’s pretty easy to write a script and use as a hook on pre-commit. I wrote one of those to disallow importing a specific lib without aliasing and OS checking in a project, and as long as you only check for changed files, it’s pretty fast, too.

                                                                                                        1. 6

                                                                                                          Possible impossibilities aside, I enjoyed this way more than I thought I would.