Skip to content

Conversation

@dstandish
Copy link
Contributor

When we are running airflow locally with providers installed from sources, often many providers will be discovered which we haven't installed the deps for. This generally results in a very large amount of traceback logging, which has a very negative effect on usefulness of terminal output. Here we suppress this error logging for providers that are installed from sources.

When we are running airflow locally with providers installed from sources, often many providers will be discovered which we haven't installed the deps for.  This generally results in a very large amount of traceback logging, which has a very negative effect on usefulness of terminal output.  Here we suppress this error logging for providers that are installed from sources.
@dstandish dstandish requested a review from potiuk March 28, 2022 22:30
Copy link
Member

@potiuk potiuk left a comment

Choose a reason for hiding this comment

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

Looks cool! Thanks!

NIT: I'd use Enum or bool for providers/sources, but having string is nice for debugging too, so no problem wiht it (and TIL about post_init_)

@github-actions github-actions bot added the okay to merge It's ok to merge this PR as it does not require more tests label Mar 28, 2022
@github-actions
Copy link

The PR is likely OK to be merged with just subset of tests for default Python and Database versions without running the full matrix of tests, because it does not modify the core of Airflow. If the committers decide that the full tests matrix is needed, they will add the label 'full tests needed'. Then you should rebase to the latest main or amend the last commit of the PR, and push it with --force-with-lease.

@potiuk
Copy link
Member

potiuk commented Mar 28, 2022

Also 'airflow providers list' cmd needs fixing too :)

@potiuk
Copy link
Member

potiuk commented Mar 28, 2022

(Remnant from time when ProviderInfo was just a tuple it seems).

@dstandish
Copy link
Contributor Author

NIT: I'd use Enum or bool for providers/sources, but having string is nice for debugging too, so no problem wiht it (and TIL about post_init_)

yeah thought about Enum but thought it was too heavy handed for this

But bool is a good idea then we don't need post_init

@dstandish dstandish merged commit b5a786b into apache:main Mar 29, 2022
@dstandish dstandish deleted the providers-from-sources-import-error-to-debug branch March 29, 2022 15:56
dstandish added a commit to astronomer/airflow that referenced this pull request Mar 29, 2022
PR apache#22579 suppressed provider import log warnings when running from sources. For whatever reason, CI didn't run test_providers_manager.py so I didn't catch that changes were needed there.
dstandish added a commit that referenced this pull request Mar 29, 2022
PR #22579 suppressed provider import log warnings when running from sources. For whatever reason, CI didn't run test_providers_manager.py so I didn't catch that changes were needed there.
@ephraimbuddy ephraimbuddy added the changelog:skip Changes that should be skipped from the changelog (CI, tests, etc..) label Apr 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog:skip Changes that should be skipped from the changelog (CI, tests, etc..) okay to merge It's ok to merge this PR as it does not require more tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants