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

Update to make config load/reload backward compatible. #1115

Merged
merged 1 commit into from
Sep 15, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions config/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -980,7 +980,7 @@ def load(filename, yes):
file = "/etc/sonic/config_db{}.json".format(inst)

# if any of the config files in linux host OR namespace is not present, return
if not os.path.isfile(file):
if not os.path.exists(file):
click.echo("The config_db file {} doesn't exist".format(file))
return

Expand Down Expand Up @@ -1064,7 +1064,7 @@ def reload(db, filename, yes, load_sysinfo, no_service_restart):
file = "/etc/sonic/config_db{}.json".format(inst)

# Check the file exists before proceeding.
if not os.path.isfile(file):
if not os.path.exists(file):
click.echo("The config_db file {} doesn't exist".format(file))
continue

Expand Down