mirror of
				https://github.com/juspay/hyperswitch.git
				synced 2025-11-01 02:57:02 +08:00 
			
		
		
		
	fix(logger): use specified log level only for first-party crates (#4356)
Co-authored-by: Akshay S <akshay.s@Akshay-Subramanian-D66TQ6D97K.local>
This commit is contained in:
		| @ -348,14 +348,18 @@ fn get_envfilter( | ||||
|  | ||||
|             workspace_members | ||||
|                 .drain() | ||||
|                 .zip(std::iter::repeat(filter_log_level.into_level().into())) | ||||
|                 .zip(std::iter::repeat(filter_log_level.into_level())) | ||||
|                 .fold( | ||||
|                     EnvFilter::default().add_directive(default_log_level.into_level().into()), | ||||
|                     |env_filter, (_target, directive)| { | ||||
|                     |env_filter, (target, level)| { | ||||
|                         // Safety: This is a hardcoded basic filtering directive. If even the basic | ||||
|                         // filter is wrong, it's better to panic. | ||||
|                         #[allow(clippy::expect_used)] | ||||
|                         env_filter.add_directive(directive) | ||||
|                         env_filter.add_directive( | ||||
|                             format!("{target}={level}") | ||||
|                                 .parse() | ||||
|                                 .expect("Invalid EnvFilter directive format"), | ||||
|                         ) | ||||
|                     }, | ||||
|                 ) | ||||
|         }) | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 akshay-97
					akshay-97