go-ethereum/signer/core
jwasinger 28e7371701
all: replace log15 with slog (#28187)
This PR replaces Geth's logger package (a fork of [log15](https://github.com/inconshreveable/log15)) with an implementation using slog, a logging library included as part of the Go standard library as of Go1.21.

Main changes are as follows:
* removes any log handlers that were unused in the Geth codebase.
* Json, logfmt, and terminal formatters are now slog handlers.
* Verbosity level constants are changed to match slog constant values.  Internal translation is done to make this opaque to the user and backwards compatible with existing `--verbosity` and `--vmodule` options.
* `--log.backtraceat` and `--log.debug` are removed.

The external-facing API is largely the same as the existing Geth logger.  Logger method signatures remain unchanged.

A small semantic difference is that a `Handler` can only be set once per `Logger` and not changed dynamically.  This just means that a new logger must be instantiated every time the handler of the root logger is changed.

----
For users of the `go-ethereum/log` module. If you were using this module for your own project, you will need to change the initialization. If you previously did 
```golang
log.Root().SetHandler(log.LvlFilterHandler(log.LvlInfo, log.StreamHandler(os.Stderr, log.TerminalFormat(true))))
```
You now instead need to do 
```golang
log.SetDefault(log.NewLogger(log.NewTerminalHandlerWithLevel(os.Stderr, log.LevelInfo, true)))
```
See more about reasoning here: https://github.com/ethereum/go-ethereum/issues/28558#issuecomment-1820606613
2023-11-29 08:33:50 +01:00
..
apitypes signer: run tests in parallel (#28536) 2023-11-20 08:20:59 +01:00
testdata signer/core: rename testdata files (#27063) 2023-04-17 10:36:47 -04:00
api.go signer/core: show helptext when clef rejects signing (#27538) 2023-07-06 03:50:44 -04:00
api_test.go signer: run tests in parallel (#28536) 2023-11-20 08:20:59 +01:00
auditlog.go all: replace log15 with slog (#28187) 2023-11-29 08:33:50 +01:00
cliui.go cmd/clef: only print first N accounts on startup (#26128) 2022-11-08 21:17:12 +01:00
gnosis_safe.go all: update license headers and AUTHORS from git history (#24947) 2022-05-24 20:39:40 +02:00
signed_data.go les, signer, light: replace noarg fmt.Errorf with errors.New (#27336) 2023-05-25 02:51:13 -04:00
signed_data_test.go signer: run tests in parallel (#28536) 2023-11-20 08:20:59 +01:00
stdioui.go rpc: use atomic types (#27214) 2023-05-04 04:54:45 -04:00
uiapi.go les, signer, light: replace noarg fmt.Errorf with errors.New (#27336) 2023-05-25 02:51:13 -04:00
validation.go all: fix some go-critic linter warnings (#23709) 2021-10-13 17:31:02 +02:00
validation_test.go signer: run tests in parallel (#28536) 2023-11-20 08:20:59 +01:00