Skip to content

Commit de501bc

Browse files
committed
Format the binary dictionary generator diagnostic
1 parent 17652cb commit de501bc

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎vgi/codegen/cpp_records.py‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,9 @@ def _map(dtype: pa.DataType, annotation: object, *, model: _Model, origin: str)
203203
if dtype.equals(pa.dictionary(pa.int32(), pa.binary())):
204204
return "Bytes"
205205
if not (dtype.index_type.equals(pa.int16()) and dtype.value_type.equals(pa.string()) and not dtype.ordered):
206-
raise GeneratorError(f"{origin}: only dictionary<int16, utf8> and dictionary<int32, binary> are supported, got {dtype}.")
206+
raise GeneratorError(
207+
f"{origin}: only dictionary<int16, utf8> and dictionary<int32, binary> are supported, got {dtype}."
208+
)
207209
if isinstance(base, type) and issubclass(base, enum.Enum):
208210
return _register_enum(base, model)
209211
return "std::string"

0 commit comments

Comments
 (0)