MCPcopy Create free account
hub / github.com/apache/arrow / fields

Function fields

python/pyarrow/tests/strategies.py:184–194  ·  view source on GitHub ↗
(draw, type_strategy=primitive_types, name_strategy=None)

Source from the content-addressed store, hash-verified

182
183@st.composite
184def fields(draw, type_strategy=primitive_types, name_strategy=None):
185 if name_strategy is None:
186 name_strategy = custom_text
187 name = draw(name_strategy)
188 typ = draw(type_strategy)
189 if pa.types.is_null(typ):
190 nullable = True
191 else:
192 nullable = draw(st.booleans())
193 meta = draw(metadata)
194 return pa.field(name, type=typ, nullable=nullable, metadata=meta)
195
196
197def list_types(item_strategy=primitive_types):

Callers 3

struct_typesFunction · 0.70
schemasFunction · 0.70
strategies.pyFile · 0.70

Calls 2

is_nullMethod · 0.80
fieldMethod · 0.45

Tested by

no test coverage detected