diff --git a/flux_local/tool/selector.py b/flux_local/tool/selector.py index f5c4c407..8c7456f8 100644 --- a/flux_local/tool/selector.py +++ b/flux_local/tool/selector.py @@ -30,6 +30,8 @@ def __call__( option_string: str | None = None, ) -> None: values = values.split(",") + if not values[0]: + return try: source = git_repo.Source.from_str(values[0]) except ValueError: diff --git a/tests/tool/testdata/diff_ks_yaml_empty_sources.yaml b/tests/tool/testdata/diff_ks_yaml_empty_sources.yaml new file mode 100644 index 00000000..87fd2253 --- /dev/null +++ b/tests/tool/testdata/diff_ks_yaml_empty_sources.yaml @@ -0,0 +1,10 @@ +args: +- diff +- ks +- apps +- --path +- tests/testdata/cluster/ +- -o +- yaml +- --sources +- ""