BT

.NET 3.5 SP1 Is Breaking Some Applications

by Abel Avram on Oct 09, 2008 |

.NET 3.5 SP1 was released in August and, theoretically, it should not break applications based on previous versions of the CLR, respectively 2.0, 3.0, 3.5. But there are reports that some applications are broken including the open source project Castle.

Scott Hanselman, a Senior Program Manager at Microsoft, wrote on issues existing with .NET 3.5 SP1. First, he asked: "Will the .NET Framework 3.5 SP1 break my 2.0 apps?", then he answered "Almost certainly not.". After explaining why 3.5 SP1 should not affect existing .NET applications, based on CLR 2.0 and later, he admits he has "hit an edge case". He advises on doing in-house testing to make sure the SP1 won't break anything:

It IS possible that something could break, so as with all SP’s you should do compatibility testing to make sure you’re not hitting an edge case.

Castle Project founder, Hamilton Verissimo de Oliveira, who has joined Microsoft this year, has complained about SP1 breaking Castle. He explains what is broken and what they did to work around it:

    • The SP broke DynamicProxy 2 when creating a proxy for generic interfaces/methods
    • The code that started to throw an exception is there to deal with a very edge case
    • Breaking DynamicProxy breaks everyone that uses it (Rhino Mocks, Castle Windsor, NHibernate and Moq - those are the main ones I can think of now)
    • I recently confirmed the problem and changed DynamicProxy code to not use those methods “r5323: Disabled the GetOptional/RequiredCustomModifiers calls so all tests (but one) pass”

Hamilton recommends:

If some team on CLR decided to run Castle tests cases with SP1, they would have detected that. Mono does aggregate external tests cases repositories to test their platform implementation. MS could do the same for a handful of OSS projects, where license is not a problem. If that’s not possible due to legal issues, the CLR team can streamline the communication with OSS teams and get early feedback.

Scott Hanselman promises there will be a patch to .NET 3.5 SP1 before SP1 will be rolled out through Windows Update, some time in November. When that happens, all machines currently with .NET 2.0 will be upgraded to 3.5 SP1. In the meantime, those who are having problems with .NET 3.5 SP1 are encouraged to post the bugs on Microsoft's Connect site.

Hello stranger!

You need to Register an InfoQ account or to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Tell us what you think

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Why to Test Using the Beta by John Saunders

It is also the case that if the Castle people had tested their code with the beta of SP1, then we would not be having this conversation. The beta was out there for three months!

CLR 3.x? by Eugene Tolmachev

Correct me if I'm wrong, but CLR in .NET 3.x is still 2.0.
- Does 3.5 sp1 also patch my .NET 2.0 *framework*?
- Is there a single version of CLR on a machine?
- If not, is there a way to specify the CLR version to use?

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Email me replies to any of my messages in this thread

2 Discuss

Educational Content

General Feedback
Bugs
Advertising
Editorial
InfoQ.com and all content copyright © 2006-2013 C4Media Inc. InfoQ.com hosted at Contegix, the best ISP we've ever worked with.
Privacy policy
BT