mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-02-16 23:13:37 +08:00
Fix type for six.reraise to make it match sys.exc_info()
The docs for six say the simple case is `reraise(*sys.exc_info())`
This commit is contained in:
committed by
Łukasz Langa
parent
37dff4d8bc
commit
8a8680371a
4
third_party/2/six/__init__.pyi
vendored
4
third_party/2/six/__init__.pyi
vendored
@@ -5,7 +5,7 @@ from __future__ import print_function
|
||||
import types
|
||||
from typing import (
|
||||
Any, AnyStr, Callable, Dict, Iterable, Mapping, Optional,
|
||||
Pattern, Tuple, TypeVar, Union, overload, ValuesView, KeysView, ItemsView
|
||||
Pattern, Tuple, Type, TypeVar, Union, overload, ValuesView, KeysView, ItemsView
|
||||
)
|
||||
import typing
|
||||
import unittest
|
||||
@@ -79,7 +79,7 @@ def assertRaisesRegex(self: unittest.TestCase, msg: str = ...) -> Any: ...
|
||||
def assertRaisesRegex(self: unittest.TestCase, callable_obj: Callable[..., Any], *args: Any, **kwargs: Any) -> Any: ...
|
||||
def assertRegex(self: unittest.TestCase, text: AnyStr, expected_regex: Union[AnyStr, Pattern[AnyStr]], msg: str = ...) -> None: ...
|
||||
|
||||
def reraise(tp: type, value: Optional[BaseException], tb: Optional[types.TracebackType] = ...) -> None: ...
|
||||
def reraise(tp: Optional[Type[BaseException]], value: Optional[BaseException], tb: Optional[types.TracebackType] = ...) -> None: ...
|
||||
def exec_(_code_: Union[unicode, types.CodeType], _globs_: Dict[str, Any] = ..., _locs_: Dict[str, Any] = ...): ...
|
||||
def raise_from(value: BaseException, from_value: BaseException) -> None: ...
|
||||
|
||||
|
||||
Reference in New Issue
Block a user