Type x does not match type x errors

Sometimes you can get these kinds of errors using the new Workflow Foundation ReceiveActivity when property binding the incoming value. So why does this happen Well it appears the validation is comparing the type of the original interface to to the type of the proxy generated. In this case because the actual type passed isn’t shared between the client and the server.

But as the generated proxy type actually gets exactly the same name as the original, even though it is a different type defined in a different assembly, it appears as though comparing two the same types says they are not equal.

So is there a problem in the code?

No there isn’t because the client doesn’t have a reference to the original type, which is why the proxy was generated in the first place, the proxy is always used. So the error is bogus and should not be reported.

So this is a but that is going to be fixed? Well apparently not according to this bug report feedback. Apparently we just have to ignore the error [:(] which sort of sucks big time. As far as I am concerned an incorrectly reported error is a serious bug and should be fixed as it is likely to waste a lot of time and might result in serious problems being ignored.

 

So if you agree that problems like this should be fixed please go here and vote for this to be fixed!

Enjoy!

One thought on “Type x does not match type x errors

Leave a Reply

Your email address will not be published. Required fields are marked *


*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>