Skip to content

Conversation

@Stephen0512
Copy link
Contributor

This pull request fixes a file-handling issue in the intezer_sdk/_endpoint_analysis_api.py. The current implementation uses open() without explicitly closing the file, which can potentially lead to resource leaks. While Python's garbage collector will eventually close the file once it is no longer referenced, it is generally better practice to explicitly close files or use a context manager.

This change replaces the direct open() call with a with statement to ensure proper file closure and follow Python best practices. The issue was identified during an ongoing research project.

@davidt99 davidt99 requested a review from itamarga January 29, 2026 11:17
Copy link
Contributor

@itamarga itamarga left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@davidt99 davidt99 merged commit a012a48 into intezer:master Jan 29, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants