diff options
author | Thomas A Caswell <tcaswell@gmail.com> | 2017-10-21 00:14:32 -0400 |
---|---|---|
committer | Thomas A Caswell <tcaswell@gmail.com> | 2017-10-21 00:14:32 -0400 |
commit | f668f7f39662586306d853049c5fe96125209cb8 (patch) | |
tree | 5ae4d417b19f2c4e299e0af471494a0894ad21bf | |
parent | 5fa8aef2b03ff5c2779e2f677e172343256736cf (diff) | |
download | pexpect-f668f7f39662586306d853049c5fe96125209cb8.tar.gz |
FIX: rename async.py -> _async.py to avoid syntax errors in 3.7
async has moved to a proper keyword resulting in syntax errors on
import.
-rw-r--r-- | pexpect/_async.py (renamed from pexpect/async.py) | 0 | ||||
-rw-r--r-- | pexpect/spawnbase.py | 6 |
2 files changed, 3 insertions, 3 deletions
diff --git a/pexpect/async.py b/pexpect/_async.py index 3a1a1ad..3a1a1ad 100644 --- a/pexpect/async.py +++ b/pexpect/_async.py diff --git a/pexpect/spawnbase.py b/pexpect/spawnbase.py index 966bf11..9cdcba6 100644 --- a/pexpect/spawnbase.py +++ b/pexpect/spawnbase.py @@ -349,7 +349,7 @@ class SpawnBase(object): exp = Expecter(self, searcher_re(pattern_list), searchwindowsize) if async_: - from .async import expect_async + from ._async import expect_async return expect_async(exp, timeout) else: return exp.expect_loop(timeout) @@ -398,7 +398,7 @@ class SpawnBase(object): exp = Expecter(self, searcher_string(pattern_list), searchwindowsize) if async_: - from .async import expect_async + from ._async import expect_async return expect_async(exp, timeout) else: return exp.expect_loop(timeout) @@ -501,7 +501,7 @@ class SpawnBase(object): # For 'with spawn(...) as child:' def __enter__(self): return self - + def __exit__(self, etype, evalue, tb): # We rely on subclasses to implement close(). If they don't, it's not # clear what a context manager should do. |