Skip to content

Commit

Permalink
Merge pull request #679 from gbregman/devel
Browse files Browse the repository at this point in the history
Display local and OMAP version when update completes
  • Loading branch information
gbregman authored May 27, 2024
2 parents 500d011 + a959d3f commit b27f177
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions control/state.py
Original file line number Diff line number Diff line change
Expand Up @@ -646,8 +646,9 @@ def update(self) -> bool:
# Get version and state from OMAP
omap_state_dict = self.omap.get_state()
omap_version = int(omap_state_dict[self.omap.OMAP_VERSION_KEY])
local_version = self.omap.get_local_version()

if self.omap.get_local_version() < omap_version:
if local_version < omap_version:
local_state_dict = self.local.get_state()
local_state_keys = local_state_dict.keys()
omap_state_keys = omap_state_dict.keys()
Expand Down Expand Up @@ -682,7 +683,7 @@ def update(self) -> bool:
# Update local state and version
self.local.reset(omap_state_dict)
self.omap.set_local_version(omap_version)
self.logger.debug("Update complete.")
self.logger.debug(f"Update complete ({local_version} -> {omap_version}).")

return True

Expand Down

0 comments on commit b27f177

Please sign in to comment.