File tree Expand file tree Collapse file tree 2 files changed +13
-14
lines changed Expand file tree Collapse file tree 2 files changed +13
-14
lines changed Original file line number Diff line number Diff line change @@ -132,22 +132,21 @@ def __eq__(self, other):
132
132
"""Instance is equal to another ArraySchema"""
133
133
if not isinstance (other , ArraySchema ):
134
134
return False
135
- nattr = self .nattr
136
- if nattr != other .nattr :
137
- return False
138
- if (
139
- self .sparse != other .sparse
140
- or self .cell_order != other .cell_order
141
- or self .tile_order != other .tile_order
135
+ if not (
136
+ self .sparse == other .sparse
137
+ and self .cell_order == other .cell_order
138
+ and self .tile_order == other .tile_order
139
+ and self .capacity == other .capacity
140
+ and self .coords_filters == other .coords_filters
141
+ and self .offsets_filters == other .offsets_filters
142
+ and self .validity_filters == other .validity_filters
143
+ and self .nattr == other .nattr
144
+ and self .domain == other .domain
142
145
):
143
146
return False
144
- if self .capacity != other .capacity :
145
- return False
146
- if self .domain != other .domain :
147
+ if self .sparse and self .allows_duplicates != other .allows_duplicates :
147
148
return False
148
- if self .coords_filters != other .coords_filters :
149
- return False
150
- for i in range (nattr ):
149
+ for i in range (self .nattr ):
151
150
if self .attr (i ) != other .attr (i ):
152
151
return False
153
152
return True
Original file line number Diff line number Diff line change @@ -823,7 +823,7 @@ def test_dataframe_csv_schema_only(self):
823
823
tile_order = "row-major" ,
824
824
capacity = 1001 ,
825
825
sparse = True ,
826
- allows_duplicates = False ,
826
+ allows_duplicates = True ,
827
827
)
828
828
# note: filters omitted
829
829
You can’t perform that action at this time.
0 commit comments