You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Running nvflare provision against a project.yml that doesn't pass argument checks returns a 0 exit code, making it impossible to reliably use the nvflare provision command in scripts, unless the script parses nvflare provision output.
Unable to handle command: provision due to: name=client1.nvidia-flare-example.com is ill-formatted based on regex_pattern=^[A-Za-z0-9-_]+$
sub_parser is: ArgumentParser(prog='nvflare provision', usage=None, description=None, formatter_class=<class 'argparse.HelpFormatter'>, conflict_handler='error', add_help=True)
usage: nvflare provision [-h] [-p PROJECT_FILE] [-w WORKSPACE] [-c CUSTOM_FOLDER] [--add_user ADD_USER] [--add_client ADD_CLIENT]
optional arguments:
-h, --help show this help message and exit
-p PROJECT_FILE, --project_file PROJECT_FILE
file to describe FL project
-w WORKSPACE, --workspace WORKSPACE
directory used by provision
-c CUSTOM_FOLDER, --custom_folder CUSTOM_FOLDER
additional folder to load python codes
--add_user ADD_USER yaml file for added user
--add_client ADD_CLIENT
yaml file for added client
Get the exit code:
echo$?
Observe the output:
0
Expected behavior
nvflare provision should return a non-zero exit code on validation errors.
Environment (please complete the following information):
Reproducible using the nvflare docker image: nvflare/nvflare:2.4.2
The text was updated successfully, but these errors were encountered:
ferrarimarco
changed the title
[BUG] nvflare provision doesn't exit with a code >0 on errors
[BUG] nvflare provision doesn't exit with a code >0 on input validation errors
Mar 12, 2025
Describe the bug
Running
nvflare provision
against aproject.yml
that doesn't pass argument checks returns a0
exit code, making it impossible to reliably use thenvflare provision
command in scripts, unless the script parsesnvflare provision
output.To Reproduce
Steps to reproduce the behavior:
project.yml
with the following contents:Run
nvflare provision
Observe the output:
Expected behavior
nvflare provision
should return a non-zero exit code on validation errors.Environment (please complete the following information):
Reproducible using the nvflare docker image:
nvflare/nvflare:2.4.2
The text was updated successfully, but these errors were encountered: