From 70ddf02d217c9588857ff9dc5d0efce03f611de1 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Fri, 19 Feb 2016 19:51:11 -0800 Subject: [PATCH] Use relative imports in asyncio.tasks and asyncio.futures --- stdlib/3.4/asyncio/futures.pyi | 2 +- stdlib/3.4/asyncio/tasks.pyi | 9 +++------ 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/stdlib/3.4/asyncio/futures.pyi b/stdlib/3.4/asyncio/futures.pyi index 37e72a157..81f2fb5e6 100644 --- a/stdlib/3.4/asyncio/futures.pyi +++ b/stdlib/3.4/asyncio/futures.pyi @@ -1,5 +1,5 @@ from typing import Any, Union, Callable, TypeVar, List, Generic, Iterable, Generator -from asyncio.events import AbstractEventLoop +from .events import AbstractEventLoop # __all__ = ['CancelledError', 'TimeoutError', # 'InvalidStateError', # 'wrap_future', diff --git a/stdlib/3.4/asyncio/tasks.pyi b/stdlib/3.4/asyncio/tasks.pyi index 4475c4ab0..14ca97b5d 100644 --- a/stdlib/3.4/asyncio/tasks.pyi +++ b/stdlib/3.4/asyncio/tasks.pyi @@ -1,15 +1,12 @@ from typing import Any, Iterable, TypeVar, Set, Dict, List, TextIO, Union, Tuple, Generic, Callable, Generator -from asyncio.events import AbstractEventLoop -from asyncio.futures import Future -# __all__ = ['iscoroutinefunction', 'iscoroutine', -# 'as_completed', 'async', -# 'gather', 'shield', -# ] __all__ = ['Task', 'sleep', 'FIRST_COMPLETED', 'FIRST_EXCEPTION', 'ALL_COMPLETED', 'wait', 'wait_for'] +from .events import AbstractEventLoop +from .futures import Future + FIRST_EXCEPTION = 'FIRST_EXCEPTION' FIRST_COMPLETED = 'FIRST_COMPLETED' ALL_COMPLETED = 'ALL_COMPLETED'