File tree Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -129,7 +129,7 @@ def get_mask_array_type():
129
129
class MaskArray (_MaskArray , ArrowBoolArray ):
130
130
pass
131
131
132
- except ImportError :
132
+ except ModuleNotFoundError :
133
133
class MaskArray (_MaskArray , NumpyBoolArray ):
134
134
pass
135
135
Original file line number Diff line number Diff line change 5
5
multiple dtypes. Not all methods are implemented yet, and the
6
6
current implementation is not efficient.
7
7
"""
8
+ from distutils .version import LooseVersion
8
9
import copy
9
10
import itertools
10
11
11
12
import numpy as np
12
- import pyarrow as pa
13
13
14
14
import pandas as pd
15
15
from pandas .api .types import is_scalar
16
16
from pandas .api .extensions import (
17
17
ExtensionArray , ExtensionDtype , register_extension_dtype , take )
18
18
19
+ try :
20
+ import pyarrow as pa
21
+ if pa .__version__ < LooseVersion ('0.10.0' ):
22
+ raise ImportError ("pyarrow minimum for bool suppport is 0.10.0" )
23
+ except ModuleNotFoundError :
24
+ raise
25
+
19
26
20
27
@register_extension_dtype
21
28
class ArrowBoolDtype (ExtensionDtype ):
You can’t perform that action at this time.
0 commit comments