hanabi1224 / bevy_assets_bundler

Assets Bundler for bevy, with encryption support
MIT License
45 stars 9 forks source link

Log level for operations is higher than necessary #7

Open Veritius opened 2 years ago

Veritius commented 2 years ago

Many operations performed by bevy_assets_bundler are at the info logging level, which, if you're loading a lot of assets (such as if you're using bevy_asset_loader), is not necessary. Logging at the debug or trace level is likely a better choice.

Currently, the console just looks like this, blotting out a lot of other, far more useful information.

2022-10-28T04:26:21.982035Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: load_path: "fonts/firasans/FiraSans-Light.ttf"
2022-10-28T04:26:22.034407Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: load_path: "fonts/firasans/FiraSans-Medium.ttf"
2022-10-28T04:26:23.665905Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: get_metadata: "prototypes/architect/debug"
2022-10-28T04:26:23.666537Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: [read_directory] "prototypes/architect/debug"
2022-10-28T04:26:23.667102Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: get_metadata: "prototypes/architect/debug/debug1.building.yml"
2022-10-28T04:26:23.668114Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: load_path: "prototypes/architect/debug/debug1.building.yml"
2022-10-28T04:26:23.668100Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: get_metadata: "prototypes/architect/debug/debug2.building.yml"
2022-10-28T04:26:23.672126Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: get_metadata: "prototypes/architect/housing"
2022-10-28T04:26:23.672246Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: load_path: "prototypes/architect/debug/debug2.building.yml"
2022-10-28T04:26:23.673181Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: [read_directory] "prototypes/architect/housing"        
2022-10-28T04:26:23.675513Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: get_metadata: "prototypes/architect/housing/tent.building.yml"
2022-10-28T04:26:23.695405Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: load_path: "prototypes/architect/housing/tent.building.yml"
2022-10-28T04:26:23.786199Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: get_metadata: "prototypes/architect/debug"
2022-10-28T04:26:23.788888Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: [read_directory] "prototypes/architect/debug"
2022-10-28T04:26:23.789917Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: get_metadata: "prototypes/architect/debug/debug1.building.yml"
2022-10-28T04:26:23.791779Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: get_metadata: "prototypes/architect/debug/debug2.building.yml"
2022-10-28T04:26:23.793509Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: get_metadata: "prototypes/architect/housing"
2022-10-28T04:26:23.795351Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: [read_directory] "prototypes/architect/housing"        
2022-10-28T04:26:23.796482Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: get_metadata: "prototypes/architect/housing/tent.building.yml"
2022-10-28T04:26:24.148054Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: load_path: "images/misc/hampter.png"
2022-10-28T04:26:24.148181Z  INFO bevy_assets_bundler::plugin::bundled_asset_io: load_path: "fonts/firasans/FiraSans-Regular.ttf"
hanabi1224 commented 2 years ago

I believe you can customize log level per crate using filters

Veritius commented 2 years ago

It's still a lot of unnecessary work for every crate that uses this one.