uranusjr commented on code in PR #70805:
URL: https://github.com/apache/airflow/pull/70805#discussion_r3827753396
##########
task-sdk/src/airflow/sdk/coordinators/java/coordinator.py:
##########
@@ -200,16 +201,23 @@ class JavaCoordinator(SubprocessCoordinator):
jvm_args: list[str] = attrs.field(factory=list)
jars_root: list[pathlib.Path] = attrs.field(
converter=convert_roots,
- validator=attrs.validators.min_len(1),
+ factory=list,
Review Comment:
With `min_len(1)` gone, a `jars_root` that templates to empty or None no
longer fails at construction, which silently selects co-located mode and scans
the whole dag bundle.
I don't think #71134 covers this. That issue detects ambiguity during the
scan instead. Here there may be no ambiguity at all: if the bundle holds
exactly one executable JAR, or `main_class` is set, its checks never fire and
the wrong mode just silently succeeds. It's also on hold behind AIP-85's
importer path, so a config typo would go unguarded until that lands.
This one is a constructor-time check and needs nothing from AIP-85. A
sentinel default distinguishing "not passed" from "passed empty", or an
explicit `use_task_bundle=True`, keeps a broken config failing fast.
--
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]