11

Despite client satisfaction, I feel an ethical conflict.

Profile picture
Mid-Level Software Engineer at ddam.ai2 months ago

Balancing these two approaches is crucial depending on the project and our own values.
1. Writing completely messy code that just works. In other words, making spaghetti
2. During a development, focusing on future scaling, readability, and cleanness by spending more time on the code.

Managers often prefer quick development that works from client’s perspective, which aligns more with the first approach. It’s really difficult thing to tolerate for me, as I don’t consider it to be good programming, even if the clients are happy.

Despite client satisfaction, I feel an ethical conflict.

Should I refuse these types of projects and their financial benefits, even though my stomach is empty? 🤣

473
9

Discussion

(9 comments)
  • 9
    Profile picture
    Tech Lead/Manager at Meta, Pinterest, Kosei
    2 months ago

    If you're delivering what the client wants in terms of code quality, I don't see any ethical concern at all. What the client is paying for, and what they care most about, is business value. Good code and craftsmanship may be related to this, but are not ends in themselves.

    I think you're assuming that clean code is the right way to develop software, which is not true.

    Often times, speed and feedback is by far the most important criteria. In these scenarios, developing hacky, spaghetti code may be the exactly philosophy. Unless you have a direct conversation with the client, I would not assume that these "shortcuts" are bad.

    If there's a certain level of reliability or testing that is being promised to the client, and your manager is encouraging you to skip on that, that starts to be an ethical conflict.

    • 0
      Profile picture
      Mid-Level Software Engineer [OP]
      ddam.ai
      2 months ago

      Thanks @Rahul

      Agreed, if the "business value" brings a value to client & us, clean code doesn't matter to develop a software. Can you share your real story or your thoughts about developing a software when the given or promised time is not enough obviously, but your manager or a bridge man who connects with client already agreed on the duration of development with client and pushes a developing team rather than reporting the real situation for example lack of human resources or requesting them to extend a development time, what would you do as a software engineer?

  • 6
    Profile picture
    Engineer @ Robinhood
    2 months ago

    In the end, being a software engineer is just a job. We put in X time for Y value (usually money). Every job is like this. And the company is effectively a collection of people working for the same job, so the same equation applies at a company level.

    Good craftmanship does matter. But our time is limited & time's value changes based on the current context. Better craftmanship itself doesn't provide value: yes you could spend time to make something better, but how much time? Would the company be fine with 2 extra weeks of polish for a 1-off client if the client will likely terminate the contract if deadlines aren't met? What if that contract is the difference between 1-2 years of runaway and collapsing as a company? Does writing good code trump the importance of the company not dying? If the company collapses, you're out of a job.

    The ease of information lures developers with its high celing of craftsmanship, but often is a siren luring your career to death by drowing it in a sea of "just a little bit better". Craftmanship matters, but sometimes. Writing better code for something that is continously changed will benefit you over time, but if the code is never changed what's the point? If it works in its current state, then it requires 0 effort to be maintain (bringing it's value/time ratio to infinite since time is 0). If you start putting effort into polishing this, time is now greater than 0 and the value/time ratio is lower (so now you're technically losing the company money).

    If your ratio is too low, the company will simply terminate you. Yes, your code could be the best out of everyone else's and could have way most test coverage. But if everyone else is shipping for many more clients than you & those clients are happy despite the worse engineering quality, then who's technically providing the least value?

  • 2
    Profile picture
    Eng @ Taro
    2 months ago

    I do think there's an in-between solution where you don't have to write spaghetti code, but the code can be written in a way where it's easy to scale it up in the future.

    Tasks as simple as naming variables in a clear way, abstracting out lines of repeated code into their own functions, abstracting logical chunks of code into descriptive named functions, separating out files logically can make code maintenance a lot more manageable. It shouldn't take that much longer.

    What is the process around your work? Is it code that's handed off to the client, or do they not ever see the code? Even if they don't see the code, do you ever make revisions to it? Even if no one else sees the code, it's easier to iterate on code that's clean.

    I wouldn't refuse the projects, but I would have some bar of code quality for yourself while you are doing development.

    • 0
      Profile picture
      Mid-Level Software Engineer [OP]
      ddam.ai
      2 months ago

      thanks @Charlie,

      I think it's common problem in startups, I was a senior engineer who leads few juniors and review their code, give comments, and I want to support them to level up on skills but it takes time of course. We have limited time and developer resources. The only way to deliver a software in given time (most of the time it's shorter than the required software features with resources that we had) is to write low quality code & fragile software that will require much more time to maintenance in the near future. It brings guilty feelings like Do I work only for money? or Why am I producing low quality products and sell them to people. What I want is give them a certain level of qualified software which gives them a high value.

  • 1
    Profile picture
    Mid-Level Software Engineer [OP]
    ddam.ai
    2 months ago

    @Jonathan, @Rahul, @Charlie

    First of all, thank you for answering a question that I have faced for last few years.

    I've dug my brain, tried to understand myself. There are two main reasons that I feel not right.

    1. Only focus on current problem/try to find light weight solution more like hard coding which will be more cost to fix or maintenance than creating it rather than considering quality, possible future problems (obviously not too deep thinking), client's additional requests which might appear in the future.
    2. Many clients don't have any idea of how the backbone works, how fragile it is, and what they see is only a frontside. If we try to explain about a backbone, they simply require it to be a bold, not increasing a budget (not all the time).

    Of course when working on projects like PoC, making a spaghetti is fine as client and we are on the same page.

    • 0
      Profile picture
      Engineer @ Robinhood
      2 months ago

      The downside of working with clients is that you're operating on their whims and you can't predict those whims. You could spend time trying to figure out how to make your code flexible for every client, but you're effectively playing roulette with your time (if you guess wrong, your business value/time ratio is 0 for your efforts).

      If you want to increase the yield of your time, you can:

      • Get better at writing code faster and better. This will lower the time investment needed to add quality to your code.
      • Understand what clients who frequently make feature requests & how valuable there are. From that list, identify the top 3 clients with the largest contracts. See if there's any repeated themes around their requests & build your code so that it can be more flexibly changed for those themes. This reduces the chances of you yielding 0 business value with your polish time since you're guessing blindly less.

      Time is the part of the equation you're missing. You only have a fixed amount of time in your day-to-day work & the clients likely have a hard timeline for needing your company's software. Clients won't budge because they have money and signed a legally binding contract. So their needs are top priority, while your desire for higher quality is very low on the company's priority list. Likewise, the company will want your time spent for them to reflect this (they're the ones paying you after all).

    • 0
      Profile picture
      Mid-Level Software Engineer [OP]
      ddam.ai
      2 months ago

      The first priority of why I have been working as a software engineer is my & clients' satisfaction, the money that you mentioned few times might be 2nd or 3rd.

    • 0
      Profile picture
      Engineer @ Robinhood
      2 months ago

      I think you misunderstood my post: the top priority is your company's satisfaction with you. Since your clients have money (which your company needs) and signed a legally binding contract, they are the main metric in which your company's satisfaction is measured around. Their time is worth money that your company needs. So that trickles then to your only priority to serving clients.

      Your satisfaction is unfortunately effectively non-existent on the company's totem pole of priorities (this will be the same for any company). If you want the company's view of the business to align with your engineering view of the business, you first need to prove that you are one of the company's most efficient engineers. Most ideas and viewpoints are reasonable, but there's too many where there's not enough time to reasonably act upon them. So to guide their decision on what to follow, people implicitly will bias towards how they perceive the value of the person providing those ideas of viewpoints. Jamie Oliver says a lot of things about cooking, but people generally listen to Gordon Ramsey over Jamie because Jamie is just saying random nonsense and Gordon Ramsey is legitimately a good chef.