Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

eXR GISO: CLI option can't override item in yaml file #26

Closed
skwsk opened this issue Nov 11, 2022 · 3 comments
Closed

eXR GISO: CLI option can't override item in yaml file #26

skwsk opened this issue Nov 11, 2022 · 3 comments

Comments

@skwsk
Copy link

skwsk commented Nov 11, 2022

The below behaviour explained in README is not working

To override any input in the yaml config file, please use the corresponding cli option and parameter.
./src/gisobuild.py --yamlfile <input_yaml_cfg> --label <new_label>
The above command will override the label specified in yaml file with new option provided via cli option --label.

@cmohapat
Copy link
Collaborator

We will review and update here.

@pvpanda
Copy link
Collaborator

pvpanda commented Dec 8, 2022

The fix you provided is incorrect. it will override everything in 'yaml_args' with whatever is in 'cli_args' including default values. for example:

in yaml:
pkglist: [x.rpm, y.rpm]

in cli:
gisobuild.py --yaml path/to/yaml/z.yaml

it will become something like as if you have passed:
pkglist: []

because [] is the default value if nothing is provided in the cli

The correct fix will be published soon.

@skwsk
Copy link
Author

skwsk commented Dec 13, 2022

Not sure if it happen with the change I provided because the items in yaml to be override only if the same item in CLI args. In your example, pkglist is not in CLI args. Anyway, it seems you preparing fix so that's good. Looking forward to seeing the fix.

@pvpanda pvpanda closed this as completed Jul 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants