Skip to content

Commit 1ae9019

Browse files
authored
add trace to CLI help output (#1868)
* add trace to CLI --help output * sort log levels by verbosity
1 parent 3283b79 commit 1ae9019

File tree

2 files changed

+20
-20
lines changed

2 files changed

+20
-20
lines changed

cmd/juno/juno.go

+19-19
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ import (
2626
)
2727

2828
const greeting = `
29-
_
30-
| |
31-
| |_ _ _ __ ___
32-
_ | | | | | '_ \ / _ \
33-
| |__| | |_| | | | | (_) |
29+
_
30+
| |
31+
| |_ _ _ __ ___
32+
_ | | | | | '_ \ / _ \
33+
| |__| | |_| | | | | (_) |
3434
\____/ \__,_|_| |_|\___/ %s
3535
3636
Juno is a Go implementation of a Starknet full-node client created by Nethermind.
@@ -118,14 +118,14 @@ const (
118118
defaultGwTimeout = 5 * time.Second
119119
defaultCorsEnable = false
120120

121-
configFlagUsage = "The yaml configuration file."
122-
logLevelFlagUsage = "Options: debug, info, warn, error."
121+
configFlagUsage = "The YAML configuration file."
122+
logLevelFlagUsage = "Options: trace, debug, info, warn, error."
123123
httpUsage = "Enables the HTTP RPC server on the default port and interface."
124124
httpHostUsage = "The interface on which the HTTP RPC server will listen for requests."
125125
httpPortUsage = "The port on which the HTTP server will listen for requests."
126-
wsUsage = "Enables the Websocket RPC server on the default port."
127-
wsHostUsage = "The interface on which the Websocket RPC server will listen for requests."
128-
wsPortUsage = "The port on which the websocket server will listen for requests."
126+
wsUsage = "Enables the WebSocket RPC server on the default port."
127+
wsHostUsage = "The interface on which the WebSocket RPC server will listen for requests."
128+
wsPortUsage = "The port on which the WebSocket server will listen for requests."
129129
dbPathUsage = "Location of the database files."
130130
networkUsage = "Options: mainnet, sepolia, sepolia-integration."
131131
networkCustomName = "Custom network name."
@@ -138,8 +138,8 @@ const (
138138
pprofUsage = "Enables the pprof endpoint on the default port."
139139
pprofHostUsage = "The interface on which the pprof HTTP server will listen for requests."
140140
pprofPortUsage = "The port on which the pprof HTTP server will listen for requests."
141-
colourUsage = "Uses --colour=false command to disable colourized outputs (ANSI Escape Codes)."
142-
ethNodeUsage = "Websocket endpoint of the Ethereum node. In order to verify the correctness of the L2 chain, " +
141+
colourUsage = "Use `--colour=false` command to disable colourized outputs (ANSI Escape Codes)."
142+
ethNodeUsage = "WebSocket endpoint of the Ethereum node. To verify the correctness of the L2 chain, " +
143143
"Juno must connect to an Ethereum node and parse events in the Starknet contract."
144144
pendingPollIntervalUsage = "Sets how frequently pending block will be updated (0s will disable fetching of pending block)."
145145
p2pUsage = "EXPERIMENTAL: Enables p2p server."
@@ -149,14 +149,14 @@ const (
149149
p2pFeederNodeUsage = "EXPERIMENTAL: Run juno as a feeder node which will only sync from feeder gateway and gossip the new" +
150150
" blocks to the network."
151151
p2pPrivateKeyUsage = "EXPERIMENTAL: Hexadecimal representation of a private key on the Ed25519 elliptic curve."
152-
metricsUsage = "Enables the prometheus metrics endpoint on the default port."
153-
metricsHostUsage = "The interface on which the prometheus endpoint will listen for requests."
154-
metricsPortUsage = "The port on which the prometheus endpoint will listen for requests."
155-
grpcUsage = "Enable the HTTP GRPC server on the default port."
156-
grpcHostUsage = "The interface on which the GRPC server will listen for requests."
157-
grpcPortUsage = "The port on which the GRPC server will listen for requests."
152+
metricsUsage = "Enables the Prometheus metrics endpoint on the default port."
153+
metricsHostUsage = "The interface on which the Prometheus endpoint will listen for requests."
154+
metricsPortUsage = "The port on which the Prometheus endpoint will listen for requests."
155+
grpcUsage = "Enable the HTTP gRPC server on the default port."
156+
grpcHostUsage = "The interface on which the gRPC server will listen for requests."
157+
grpcPortUsage = "The port on which the gRPC server will listen for requests."
158158
maxVMsUsage = "Maximum number for VM instances to be used for RPC calls concurrently"
159-
maxVMQueueUsage = "Maximum number for requests to queue after reaching max-vms before starting to reject incoming requets"
159+
maxVMQueueUsage = "Maximum number for requests to queue after reaching max-vms before starting to reject incoming requests"
160160
remoteDBUsage = "gRPC URL of a remote Juno node"
161161
rpcMaxBlockScanUsage = "Maximum number of blocks scanned in single starknet_getEvents call"
162162
dbCacheSizeUsage = "Determines the amount of memory (in megabytes) allocated for caching data in the database."

utils/log.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import (
1313

1414
var ErrUnknownLogLevel = fmt.Errorf(
1515
"unknown log level (known: %s, %s, %s, %s, %s)",
16-
DEBUG, INFO, WARN, ERROR, TRACE,
16+
TRACE, DEBUG, INFO, WARN, ERROR,
1717
)
1818

1919
type LogLevel int

0 commit comments

Comments
 (0)