Skip to content

Commit

Permalink
fix timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
Apurva Raghunath committed Jul 14, 2022
1 parent cedb09c commit 0cdae0e
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1503,7 +1503,7 @@ def load_configuration(self,
(str(ex)))

def commit_configuration(self, ignore_warning=None, comment=None,
confirmed=None, full=False):
confirmed=None, timeout=30, full=False):
"""Commit the candidate configuration.
Commit the configuration. Assumes the configuration is already opened.
Expand All @@ -1512,13 +1512,14 @@ def commit_configuration(self, ignore_warning=None, comment=None,
ignore_warning - Which warnings to ignore.
comment - The commit comment
confirmed - Number of minutes for commit confirmed.
timeout - Timeout for commit configuration. Default timeout value is 30s.
full - apply full commit
Failures:
- An error returned from committing the configuration.
"""
if self.conn_type != "local":
self._pyez_conn.commit_configuration(ignore_warning, comment, confirmed)
self._pyez_conn.commit_configuration(ignore_warning, comment, timeout, confirmed)
return

if self.dev is None or self.config is None:
Expand All @@ -1529,6 +1530,7 @@ def commit_configuration(self, ignore_warning=None, comment=None,
self.config.commit(ignore_warning=ignore_warning,
comment=comment,
confirm=confirmed,
timeout=timeout,
full=full)
self.logger.debug("Configuration committed.")
except (self.pyez_exception.RpcError,
Expand Down

0 comments on commit 0cdae0e

Please sign in to comment.