Skip to content

Fix: Account for missing stdin / stdout when checking whether the runtime environment is interactive#5500

Merged
izeigerman merged 1 commit intomainfrom
fix-missing-stdin-stdout
Oct 7, 2025
Merged

Fix: Account for missing stdin / stdout when checking whether the runtime environment is interactive#5500
izeigerman merged 1 commit intomainfrom
fix-missing-stdin-stdout

Conversation

@izeigerman
Copy link
Collaborator

Closes ##5498

@izeigerman izeigerman requested review from a team and Copilot October 7, 2025 16:28
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR fixes a bug in the interactive environment detection by adding null checks for stdin and stdout before calling isatty() methods.

  • Adds null checks for sys.stdin and sys.stdout before calling their isatty() methods
  • Prevents potential AttributeError when stdin/stdout are None in certain runtime environments

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@izeigerman izeigerman merged commit 0d15b4b into main Oct 7, 2025
33 of 35 checks passed
@izeigerman izeigerman deleted the fix-missing-stdin-stdout branch October 7, 2025 18:27
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