Coverage for /pythoncovmergedfiles/medio/medio/usr/local/lib/python3.11/site-packages/greenlet/__init__.py: 94%

Shortcuts on this page

r m x   toggle line displays

j k   next/prev highlighted chunk

0   (zero) top of page

1   (one) first highlighted chunk

17 statements  

1# -*- coding: utf-8 -*- 

2""" 

3The root of the greenlet package. 

4""" 

5 

6__all__ = [ 

7 '__version__', 

8 '_C_API', 

9 

10 'GreenletExit', 

11 'error', 

12 

13 'getcurrent', 

14 'greenlet', 

15 

16 'gettrace', 

17 'settrace', 

18] 

19 

20# pylint:disable=no-name-in-module 

21 

22### 

23# Metadata 

24### 

25__version__ = '3.5.0' 

26from ._greenlet import _C_API # pylint:disable=no-name-in-module 

27 

28### 

29# Exceptions 

30### 

31from ._greenlet import GreenletExit 

32from ._greenlet import error 

33 

34### 

35# greenlets 

36### 

37from ._greenlet import getcurrent 

38from ._greenlet import greenlet 

39 

40### 

41# tracing 

42### 

43from ._greenlet import gettrace 

44from ._greenlet import settrace 

45 

46### 

47# Constants 

48# These constants aren't documented and aren't recommended. 

49# In 1.0, USE_GC and USE_TRACING are always true, and USE_CONTEXT_VARS 

50# is the same as ``sys.version_info[:2] >= 3.7`` 

51### 

52from ._greenlet import GREENLET_USE_CONTEXT_VARS # pylint:disable=unused-import 

53from ._greenlet import GREENLET_USE_GC # pylint:disable=unused-import 

54from ._greenlet import GREENLET_USE_TRACING # pylint:disable=unused-import 

55 

56# Controlling the use of the gc module. Provisional API for this greenlet 

57# implementation in 2.0. 

58from ._greenlet import CLOCKS_PER_SEC # pylint:disable=unused-import 

59from ._greenlet import enable_optional_cleanup # pylint:disable=unused-import 

60from ._greenlet import get_clocks_used_doing_optional_cleanup # pylint:disable=unused-import 

61 

62# Other APIS in the _greenlet module are for test support.