Words of wisdom from my new boss #1:

"I don't understand why you develop your new endpoints in Go. I think that if speed is the problem, instead of using a different programming language, you guys can just focus on writing better code in Python."

Yes, yes, that should fix everything.
Thank you.

  • 10
    I guess you could make Python better ... in Go.... get to it man.
  • 6
    That's odd. Was there a decision to move to go bc logic, or did the boss just try to override a group decision?
  • 13
    @SortOfTested There was a decision to switch to Go over a year aGo. Also, a lot of changes with the infrastructure. For the language, one of the reasons was speed. Some of the dependencies are also already dead because they kept developing stuff in Python 2 even when 3 was already there years ago. It's just a mess they don't want to deal with in the future.
  • 4
    But, how ye gonna live without the white space syntax?
  • 9
    Task: Migrate everything to Python.
    Solution: write Python scripts only to launch all the Go programs as before.
  • 2
    It should be relatively easy to migrate from python2 to python3. There are conversion libraries for thar. It should cover a near 100% of all pythonhosted libraries and functions. It can require some manual refactoring after that.
  • 3
    @NeatNerdPrime Yes but that solves only one of the problems.
  • 4
    If speed is genuinely a concern then Go is one of the few modern languages I'd say was up to the job. Certainly not Python.

    Plus, writing code to optimise for speed in languages like Python that aren't that performant is just dumb. You end up with an unmaintainable mess of spaghetti.
  • 1
    @AlmondSauce True. That's what they did in some of the repositories and every time I had to work on those to add just tiny bit of feature, I want to fucking die.
  • 4
    I usually hate python, but if your backend is just a glorified wrapper around your database, should PyPy be fast enough?

    If you have to do heavy calculations in real-time though, you already know what to do.
  • 2
    I think that for a lot of web projects python/PHP is fast enough when code is good. Most latency comes from accessing db/disk as @kiki points out. If that is the only reason the question *might* be valid. But it seems your organisation already sports both python and Go.

    Go has a great web stack for API's and even better tooling around it. Just because of that I would go the Go route.
    So yeah fuck your boss. I'm actually kinda jealous; my organisation has no go knowledge even though I did sneak it in some small production pieces for internal use
  • 3
    @hjk101 Yeah, it's awesome. They hired one guy who is proficient in Go and I'm just learning along the way. So far I'm enjoying it and don't want to Go back. I feel lucky getting this project even though I was originally hired for Python. :)
  • 1
    Is Go faster in your case because of compilation (instead of interpretation), because of goroutines or something else?
    I don't have much experience in neither of them. I'm just curious.
  • 1
    I remember at this job I had not too long ago... devs made some processing taks in go. Sysadmins "managed" it with ooms, due to memory leaks. It was made to get killed and rerun later on. Exciting times with sleep deprivation.
  • 1
    @Lensflare I missed this comment, sorry. We have a lot of components that benefit from Go routines but even without it, it's still faster than Python. Also, the dynamic typing is causing a lot of problems.
  • 0
    @Lensflare Go is young and so it does not have as much bloatware integrated. It lacks some functionality that might make it slow later on as it matures. It just GOes... oom and such.
  • 0
    @rutee07 Is Go any faster then C though. I've heard its much easier to write so that is why it is popular. But if one had that skillset to write proper C code, one might end up with better code and running just as fast, no? It would take much longer to write tho. (I'm no coder)
  • 1
    @AtuM It's for web development and there are other things considered aside from speed.
Add Comment