Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion cassandra/cqltypes.py
Original file line numberDiff line numberDiff line change
Expand Up@@ -1026,7 +1026,9 @@ def serialize_safe(cls, val, protocol_version):
try:
item = val[i]
except TypeError:
item = getattr(val, fieldname)
item = getattr(val, fieldname, None)
Comment thread
fruch marked this conversation as resolved.
if item is None and not hasattr(val, fieldname):
log.warning(f"field {fieldname} is part of the UDT {cls.typename} but is not present in the value {val}")

if item is not None:
packed_item = subtype.to_binary(item, proto_version)
Expand Down