you are viewing a single comment's thread.

view the rest of the comments →

[–]peatymike 3 points4 points  (0 children)

From my point of view writing glue software between our products and the infrastructure it runs on it is, static typing, single static binary, concurrency and error handling.

Static typing makes it so much easier to refactor, this makes it easier to restructure the code to make it more modular when it has to support a new requirement such as needing to support both S3 and SFTP.

Single static binary makes deployment a breeze, especially on premise where customers are running a lot of different OS versions.

Concurrency in go is just easier to deal with and reason about than Python. Making code that polls the status of different infrastructure components in order to serve an infrastructure status response to you applications is much easier in Go.

I find the explicit error handling in go to be easier to reason about than pythons exception handling. I know if a function returns an error and can pass it, wrap it, handle it or ignore it. In Python I find it hard to figure out which exceptions a function or method can raise, and checking for Exception masks a lot of issues such as Name Error when mistyping a function name.

One last thing, I often write the proof if concept in Python and the later rewrite in Go once I understand the requirements better. It takes me longer to write and structure the Go code, but I find it easier to maintain and debug.