acquire-project / acquire-python

Acquire: a multi-camera video streaming software focusing on microscopy
Apache License 2.0
18 stars 9 forks source link

question about logging #172

Open tlambert03 opened 8 months ago

tlambert03 commented 8 months ago

When I instantiate an acquire.Runtime I get a bunch of logging.ERROR level logs for drivers that I'm unlikely to ever use (since I don't have all those cameras).

Log: warn enabled
Log: error enabled
/Users/runner/work/acquire-python/acquire-python/acquire-common/acquire-core-libs/src/acquire-device-hal/device/hal/loader.c:125 - driver_load(): Failed to initialize driver at "acquire-driver-hdcam"
/Users/runner/work/acquire-python/acquire-python/acquire-common/acquire-core-libs/src/acquire-device-hal/device/hal/loader.c:125 - driver_load(): Failed to initialize driver at "acquire-driver-egrabber"
/Users/runner/work/acquire-python/acquire-python/acquire-common/acquire-core-libs/src/acquire-device-hal/device/hal/loader.c:125 - driver_load(): Failed to initialize driver at "acquire-driver-spinnaker"
/Users/runner/work/acquire-python/acquire-python/acquire-common/acquire-core-libs/src/acquire-device-hal/device/hal/loader.c:125 - driver_load(): Failed to initialize driver at "acquire-driver-pvcam"

I can silence these of course with getLogger("acquire").setLevel("CRITICAL") ... but that seems somewhat drastic. Are these just for the time being, intended for eventual removal? Or is there a better way to silence errors on unused drivers?