# C# Deserialzation fails

**URL:** <https://forum.confluent.io/t/c-deserialzation-fails/6216>\
**Category:** Non-Java Clients\
**Created:** [7 October 2022 11:39 UTC](https://forum.confluent.io/t/c-deserialzation-fails/6216 "2022-10-07T11:39:11Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![olafjo](https://avatars.discourse-cdn.com/v4/letter/o/67e7ee/32.png) [@olafjo](https://forum.confluent.io/u/olafjo)\
**Post date:** [7 October 2022 11:39 UTC](https://forum.confluent.io/t/c-deserialzation-fails/6216/1 "2022-10-07T11:39:11Z")

</div>

I am trying to consume a stream using C#

Deserialzation of both key and value (string,string) fails with exception:

Message: The type initializer for 'PerTypeValues`1' threw an exception. Trace: at System.SpanHelpers.IsReferenceOrContainsReferences[T]() at System.ReadOnlySpan`1…ctor(Void\* pointer, Int32 length)

Can anybody help to point us in the right direction??
