holepunchto / pear

combined Peer-to-Peer (P2P) Runtime, Development & Deployment tool
https://docs.pears.com/
Apache License 2.0
116 stars 11 forks source link

Logger parse level bug fix (TRACE or 3) #377

Closed AndreiRegiani closed 1 month ago

AndreiRegiani commented 1 month ago

Two bugs:

  1. parse was missing to handle TRACE=3
  2. fallback value was ERROR=1 instead of INFO=2, because the enum in parse function had the wrong count

Based on the --help

    --log-level <level>   Level to log at. 0,1,2,3 (OFF,ERR,INF,TRC)
image