Hide keyboard shortcuts

Hot-keys on this page

r m x p   toggle line displays

j k   next/prev highlighted chunk

0   (zero) top of page

1   (one) first highlighted chunk

1from pandas.util._decorators import Appender, Substitution, cache_readonly # noqa 

2 

3from pandas import compat 

4from pandas.core.util.hashing import hash_array, hash_pandas_object # noqa 

5 

6# compatibility for import pandas; pandas.util.testing 

7 

8if compat.PY37: 

9 

10 def __getattr__(name): 

11 if name == "testing": 

12 import pandas.util.testing 

13 

14 return pandas.util.testing 

15 else: 

16 raise AttributeError(f"module 'pandas.util' has no attribute '{name}'") 

17 

18 

19else: 

20 

21 class _testing: 

22 def __getattr__(self, item): 

23 import pandas.util.testing 

24 

25 return getattr(pandas.util.testing, item) 

26 

27 testing = _testing() 

28 

29 

30del compat