2 ms·
Fer sher. But a passed-by-Context logger could be used (for example) to override a library package's default (stdlib?) logger. But what is the SOP / Best Pract
by euroderf 3y ago
Fer sher. But a passed-by-Context logger could be used (for example) to override a library package's default (stdlib?) logger.
But what is the SOP / Best Practice here ? Do many libraries have some sort of SetLogger(..) initialization call, so that loggers don't clutter the API ? Or are error returns info-(over-)loaded ?
- preseinger 3y agoit's pretty straightforward, everything that logs takes a logger as a dependency during construction