feat(api): Implement EventManager error logging and add coverage (#29204)
- Ensure `EventManager._notify_layers` logs exceptions instead of silently swallowing them so GraphEngine layer failures surface for debugging - Introduce unit tests to assert the logger captures the runtime error when collecting events - Enable the `S110` lint rule to catch `try-except-pass` patterns - Add proper error logging for existing `try-except-pass` blocks.
This commit is contained in:
@@ -253,7 +253,7 @@ class ProviderConfiguration(BaseModel):
|
||||
try:
|
||||
credentials[key] = encrypter.decrypt_token(tenant_id=self.tenant_id, token=credentials[key])
|
||||
except Exception:
|
||||
pass
|
||||
logger.exception("Failed to decrypt credential secret variable %s", key)
|
||||
|
||||
return self.obfuscated_credentials(
|
||||
credentials=credentials,
|
||||
@@ -765,7 +765,7 @@ class ProviderConfiguration(BaseModel):
|
||||
try:
|
||||
credentials[key] = encrypter.decrypt_token(tenant_id=self.tenant_id, token=credentials[key])
|
||||
except Exception:
|
||||
pass
|
||||
logger.exception("Failed to decrypt model credential secret variable %s", key)
|
||||
|
||||
current_credential_id = credential_record.id
|
||||
current_credential_name = credential_record.credential_name
|
||||
|
||||
Reference in New Issue
Block a user