jens-scheffler-bosch commented on issue #33078: URL: https://github.com/apache/airflow/issues/33078#issuecomment-1668358725
If you want an empty value to be mapped you need to tell the system to. If you think about this the other way around: Mapping with a zero length result (because task was skipped) would mean you need to make the mapping wither with an empty value (`None`) and then the logic need to accept empty vlaues (might fail?) or you need to add a kind of "fallback mapping" like "if no result then take _something==what?_ as fallback mapping value. Airflow can not guess and just mapping with `None` would also be inconsistent. So I'd propose if you want to have a kind of "use `None`if mapping skipped" or `if nothing resulting take `something`as fallback then you need to add this logic via e.g. a `PythonOperator` in between. I see this rather as feature, that you can make yourself, not a bug. My leftover concern your be that others might stumble over the same problem again, so it would be good to have some kind of logging for this. You probably see logs of details of mapping results in the last task executed before your mapped task as the scheduling of follow-up tasks is happening distributed on the workers at time of ending task execution. But if you stumble over this really hard to understand. If you have any ideas how to expose this in logs explicitly, ideas welcome (e.g. print a warning if empty mapping is used as input). -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
