[protobuf] What causes TargetInvocationException during serialization

2014-05-16 Thread Marco P.
I am trying to serialize something like this (i'll summarize as the object 
is more complex):

class Anag {

}

System.Reflection.TargetInvocationException was unhandled
  Message=TargetInvocationException
  StackTrace:
at System.Reflection.RuntimePropertyInfo.GetValue()
at ProtoBuf.Serializers.TupleSerializer.GetValue()
at ProtoBuf.Serializers.TupleSerializer.Write()
at ProtoBuf.Meta.RuntimeTypeModel.Serialize()
at ProtoBuf.ProtoWriter.WriteObject()
at 
ProtoBuf.Serializers.SubItemSerializer.ProtoBuf.Serializers.IProtoSerializer.Write()
at ProtoBuf.Serializers.TagDecorator.Write()
at ProtoBuf.Serializers.ListDecorator.Write()
at ProtoBuf.Serializers.PropertyDecorator.Write()
at ProtoBuf.Serializers.TypeSerializer.Write()
at ProtoBuf.Meta.RuntimeTypeModel.Serialize()
at ProtoBuf.Meta.TypeModel.SerializeCore()
at ProtoBuf.Meta.TypeModel.Serialize()
at ProtoBuf.Meta.TypeModel.Serialize()
at ProtoBuf.Serializer.Serialize()
 [...]
  InnerException: 

-- 
You received this message because you are subscribed to the Google Groups 
Protocol Buffers group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to protobuf+unsubscr...@googlegroups.com.
To post to this group, send email to protobuf@googlegroups.com.
Visit this group at http://groups.google.com/group/protobuf.
For more options, visit https://groups.google.com/d/optout.


Re: [protobuf] What causes TargetInvocationException during serialization

2014-05-16 Thread Marc Gravell
Oops, meant to reply-all!
On 16 May 2014 19:34, Marc Gravell marc.grav...@gmail.com wrote:

 This is specifically protobuf-net; I have received a repro case from Marco
 separately via email, so I will investigate and post back here and
 directly, but short version don't know off the top of my head; at first
 glance, it looks like it must be a bug in the CF-specific code of
 protobuf-net.

 Marc


 On 16 May 2014 14:58, Marco P. marco...@gmail.com wrote:

 I am trying to serialize something like this (i'll summarize as the
 object is more complex):

 class Anag {

 }

 System.Reflection.TargetInvocationException was unhandled
   Message=TargetInvocationException
   StackTrace:
 at System.Reflection.RuntimePropertyInfo.GetValue()
 at ProtoBuf.Serializers.TupleSerializer.GetValue()
 at ProtoBuf.Serializers.TupleSerializer.Write()
 at ProtoBuf.Meta.RuntimeTypeModel.Serialize()
 at ProtoBuf.ProtoWriter.WriteObject()
 at
 ProtoBuf.Serializers.SubItemSerializer.ProtoBuf.Serializers.IProtoSerializer.Write()
 at ProtoBuf.Serializers.TagDecorator.Write()
 at ProtoBuf.Serializers.ListDecorator.Write()
 at ProtoBuf.Serializers.PropertyDecorator.Write()
 at ProtoBuf.Serializers.TypeSerializer.Write()
 at ProtoBuf.Meta.RuntimeTypeModel.Serialize()
 at ProtoBuf.Meta.TypeModel.SerializeCore()
 at ProtoBuf.Meta.TypeModel.Serialize()
 at ProtoBuf.Meta.TypeModel.Serialize()
 at ProtoBuf.Serializer.Serialize()
  [...]
   InnerException:

  --
 You received this message because you are subscribed to the Google Groups
 Protocol Buffers group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to protobuf+unsubscr...@googlegroups.com.
 To post to this group, send email to protobuf@googlegroups.com.
 Visit this group at http://groups.google.com/group/protobuf.
 For more options, visit https://groups.google.com/d/optout.




 --
 Regards,

 Marc


-- 
You received this message because you are subscribed to the Google Groups 
Protocol Buffers group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to protobuf+unsubscr...@googlegroups.com.
To post to this group, send email to protobuf@googlegroups.com.
Visit this group at http://groups.google.com/group/protobuf.
For more options, visit https://groups.google.com/d/optout.