Skip to content

Commit

Permalink
Better error messages in deserializeProtoValue
Browse files Browse the repository at this point in the history
  • Loading branch information
gartens committed Mar 28, 2024
1 parent d14b95d commit 0b0969b
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,8 @@ public static PolyValue deserializeProtoValue( ProtoValue protoValue ) {
case BINARY -> deserializeToPolyBinary( protoValue );
case NULL -> deserializeToPolyNull();
case LIST -> deserializeToPolyList( protoValue );
default -> throw new GenericRuntimeException( "Should never be thrown" );
case VALUE_NOT_SET -> throw new GenericRuntimeException( "Invalid ProtoValue: no value is set" );
default -> throw new GenericRuntimeException( "Deserialization of type " + protoValue.getValueCase() + " is not supported" );
};
}

Expand Down

0 comments on commit 0b0969b

Please sign in to comment.