fix(parse): handle PYTEST_THEME env var in DAG integrity test by josh-fell · Pull Request #2028 · astronomer/astro-cli
When running `astro dev parse`, the monkeypatched os.getenv() returns MOCKED_PYTEST_THEME_VALUE for unset environment variables. Pytest validates PYTEST_THEME against known Pygment styles and fails with: ERROR: PYTEST_THEME environment variable had an invalid value: 'MOCKED_PYTEST_THEME_VALUE'. Only valid pygment styles are allowed. This occurs when Astro projects specify "--color=yes" in pytest configs, causing pytest to check the PYTEST_THEME environment variable. Solution: Return None for PYTEST_THEME when no default is provided, following the same pattern used for the JENKINS_HOME fix (#601). Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
jlaneve
deleted the
josh-fell/fix-pytest-theme-mock
branch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters