From 75b09dae543fe8786e154b5272ee10bb4a32db46 Mon Sep 17 00:00:00 2001 From: Thom Smith Date: Fri, 21 May 2021 14:15:11 -0400 Subject: [PATCH] Change typing stub to make pyright happy. --- st3/sublime_lib/_compat/typing.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/st3/sublime_lib/_compat/typing.py b/st3/sublime_lib/_compat/typing.py index 7cfe95c..2ec5b35 100644 --- a/st3/sublime_lib/_compat/typing.py +++ b/st3/sublime_lib/_compat/typing.py @@ -1,4 +1,6 @@ -try: +import sys + +if sys.version_info >= (3, 8, 0): from typing import * # noqa: F401, F403 -except ImportError: +else: from .typing_stubs import * # type: ignore # noqa: F401, F403