Skip to content

Commit 588bbbd

Browse files
committed
gh-105331: move import math to the toplevel
1 parent ca806d9 commit 588bbbd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/asyncio/tasks.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
import functools
1616
import inspect
1717
import itertools
18+
import math
1819
import types
1920
import warnings
2021
import weakref
@@ -644,7 +645,6 @@ async def sleep(delay, result=None):
644645
"""Coroutine that completes after a given time (in seconds)."""
645646

646647
# check delay value is not nan
647-
import math
648648
if math.isnan(delay):
649649
raise ValueError("Invalid value NaN (not a number)")
650650

0 commit comments

Comments
 (0)