Skip to content

Conversation

@dejii
Copy link
Contributor

@dejii dejii commented Aug 14, 2025

Fixes bug in MessageQueueTrigger.

When there are no matching providers, or multiple providers recognize the same queue, the logging code attempted to join provider class objects directly, causing:

TypeError: sequence item 0: expected str instance, SqsMessageQueueProvider found

MESSAGE_QUEUE_PROVIDERS contains a list of class objects

MESSAGE_QUEUE_PROVIDERS = [create_class_by_name(name)() for name in providers_manager.queue_class_names]

but .join([ ... ]) expects strings
", ".join([provider for provider in MESSAGE_QUEUE_PROVIDERS]),

Added new tests to cover various scenarios including:

  • No available message queue providers.
  • Queue not recognized by any provider.
  • Collision where a queue is recognized by multiple providers.

^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

@potiuk potiuk merged commit 339daf6 into apache:main Aug 15, 2025
73 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants