Add `env_logger::init()` to Replica?

Can I ask to add env_logger::init() to Replica?

It would greatly help me (and other developers with similar problems) to debug why Replica does not succeed to set a HTTPS connection to https://localhost (inside my Docker image with local certificate authority), while debugging my HTTP outcalls related software.

I have a trouble debugging it and having tracing capabilities would be a great help.

So, is missing env_logger::init() in dfinity/ic repo intentional (like reducing memory footprint) or is it just forgotten? In any case, I would vote to add it.

Do you know about the log level control in dfx.json? Or are you asking for a different way to control log levels?

If you put this in dfx.json, you get debug level info for the replica.

{
     "defaults": {
       "replica": {
         "log_level": "info"
       }
     },
     "networks": {
       "local": {
         "bind": "127.0.0.1:8000"
       }
     }
   }

The HTTP adapter is separate, for that it would be e.g.

{
     "defaults": {
       "canister_http": {
         "log_level": "info"
       }
     },
     "networks": {
       "local": {
         "bind": "127.0.0.1:8000"
       }
     }
   }

Thanks, your reply was useful. I didn’t know.