3 ms·
I wouldn't list the standard library as a great strength of Go. While some parts of it are quite good, some others are terrible. Notably, logging and argument p
by vbernat 9y ago
I wouldn't list the standard library as a great strength of Go. While some parts of it are quite good, some others are terrible. Notably, logging and argument parsing are pretty bad. Compare Go's "flags" and Python's "argparse" for example. And Go's "log" and Python's "logging". The Python versions are not perfect but are at least quite usable. In Go, I have yet to see a project with more than 1k lines of code that won't use a third-party argument parsing and logging package.
For logging, each package will use its own logging mechanism. Sometimes, you are lucky and you can pass your own logger (with a random interface as the interface is not part of the standard library either). Sometimes not.
For a language born less than 10 years ago, this is a pity.