Skip to content

Check expand_kwargs() input type before unmapping#25355

Merged
uranusjr merged 3 commits into
apache:mainfrom
astronomer:aip-42-expand-kwargs-runtime-type-check
Jul 29, 2022
Merged

Check expand_kwargs() input type before unmapping#25355
uranusjr merged 3 commits into
apache:mainfrom
astronomer:aip-42-expand-kwargs-runtime-type-check

Conversation

@uranusjr
Copy link
Copy Markdown
Member

This was originally done when the value is pushed in upstream, but that was removed when we implemented map(), and now should be done when the value is pulled. The task would have failed without these explicit checks, but with very cryptic error messages.

Close #25352

@uranusjr uranusjr requested review from XD-DENG, ashb and kaxil as code owners July 28, 2022 06:02
Comment thread airflow/models/expandinput.py Outdated
Comment thread airflow/models/expandinput.py Outdated
Comment on lines 253 to 254
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

This one shouldn’t be possible in theory since the upstream ensures the return value is list-like, but let’s check anyway.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Yep. Does not cost us too much

uranusjr added 3 commits July 29, 2022 15:19
This was originally done when the value is pushed in upstream, but that
was removed when we implemented map(), and now should be done when the
value is pulled.
@uranusjr uranusjr force-pushed the aip-42-expand-kwargs-runtime-type-check branch from 8181127 to e35651b Compare July 29, 2022 07:19
@uranusjr uranusjr merged commit 4e786e3 into apache:main Jul 29, 2022
@uranusjr uranusjr deleted the aip-42-expand-kwargs-runtime-type-check branch July 29, 2022 08:58
@ephraimbuddy ephraimbuddy added the type:bug-fix Changelog: Bug Fixes label Aug 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type:bug-fix Changelog: Bug Fixes

4 participants