diff options
-rwxr-xr-x | ipalib/aci.py | 10 | ||||
-rw-r--r-- | ipapython/install/core.py | 10 |
2 files changed, 10 insertions, 10 deletions
diff --git a/ipalib/aci.py b/ipalib/aci.py index 3019375c1..186b2e80c 100755 --- a/ipalib/aci.py +++ b/ipalib/aci.py @@ -107,17 +107,17 @@ class ACI: for token in lexer: # We should have the form (a = b)(a = b)... if token == "(": - var = lexer.next().strip() - operator = lexer.next() + var = next(lexer).strip() + operator = next(lexer) if operator != "=" and operator != "!=": # Peek at the next char before giving up - operator = operator + lexer.next() + operator = operator + next(lexer) if operator != "=" and operator != "!=": raise SyntaxError("No operator in target, got '%s'" % operator) op = operator - val = lexer.next().strip() + val = next(lexer).strip() val = self._remove_quotes(val) - end = lexer.next() + end = next(lexer) if end != ")": raise SyntaxError('No end parenthesis in target, got %s' % end) diff --git a/ipapython/install/core.py b/ipapython/install/core.py index dac8883fe..92ad12c7f 100644 --- a/ipapython/install/core.py +++ b/ipapython/install/core.py @@ -319,14 +319,14 @@ class Configurable(object): def run_until_executing(self, gen): while self.__state != _EXECUTE_RUNNING: try: - yield gen.next() + yield next(gen) except StopIteration: break def __runner(self, pending_state, running_state): self.__transition(pending_state, running_state) - step = self.__gen.next + step = lambda: next(self.__gen) while True: try: step() @@ -356,7 +356,7 @@ class Configurable(object): exc_info = sys.exc_info() step = lambda: self.__gen.throw(*exc_info) else: - step = self.__gen.next + step = lambda: next(self.__gen) def _handle_exception(self, exc_info): assert not hasattr(super(Configurable, self), '_handle_exception') @@ -498,7 +498,7 @@ class Composite(Configurable): new_validate = [] for child, validator in validate: try: - validator.next() + next(validator) except StopIteration: if child.done(): self.__components.remove(child) @@ -520,7 +520,7 @@ class Composite(Configurable): new_execute = [] for child, executor in execute: try: - executor.next() + next(executor) except StopIteration: pass else: |