Skip to content

Commit

Permalink
Protect against earlier versions of the client library.
Browse files Browse the repository at this point in the history
  • Loading branch information
jclarke-csco committed Oct 30, 2023
1 parent 2d39012 commit 071a213
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
6 changes: 5 additions & 1 deletion virl/cli/nodes/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@ def nodes():
lab = safe_join_existing_lab(current_lab, client)
if lab:
# Force an operational sync.
lab.sync_operational_if_outdated()
try:
lab.sync_operational_if_outdated()
except Exception:
pass

computes = {}
try:
computes = client.get_system_health()["computes"]
Expand Down
3 changes: 2 additions & 1 deletion virl/cli/views/nodes/node_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ def node_list_table(nodes, computes):
"sync_topology_if_outdated",
):
meth = getattr(node.lab, sync)
meth()
if meth:
meth()

node.lab.auto_sync = False

Expand Down

0 comments on commit 071a213

Please sign in to comment.