-
Notifications
You must be signed in to change notification settings - Fork 759
Description
Describe your environment
Python version: 3.10
Steps to reproduce
- Initialize an instance of the SimpleLogRecordProcessor class.
- Execute an action that call the shutdown method on the processor instance.
- Emit a log after the shutdown method has been called.
What is the expected behavior?
The SimpleLogRecordProcessor should gracefully handle the log emission after the shutdown method has been called and not generate a RecursionError.
What is the actual behavior?
The class generates a RecursionError due to the warning logic in the emit method, creating a recursion loop when another log is emitted after the shutdown method is being called.
Additional context
Comparing this behavior with the BatchLogRecordProcessor, it handles the scenario differently, it just returns and do not raise any warning, avoiding the RecursionError. The SimpleLogRecordProcessor should adopt a similar approach and not raise warnings to prevent the recursion loop and associated error.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
Status