What's holding up .NET 4.5 support on AppHarbor?
UPDATE: .NET 4.5 is now available on AppHarbor.
Like all of you, we've been eagerly awaiting the release of .NET 4.5. We have also promised to add .NET 4.5 support to AppHarbor as soon as it went RTM. That happened August 15th and it's now the 20th, so what's with the delay?
The delay is due to a bug that we uncovered while testing to make sure that adding .NET 4.5 to AppHarbor build servers would not cause problems for existing applications targeting other .NET framework versions. It turns out that using MSBuild to build projects that target .NET 3.5 on a system that has .NET 4.5 RTM installed, fails – but only if the user account running the build process has a username that is 20 characters in length and only if the project contains resource files (.resx
) . 20 characters is generally the maximum length of usernames for Windows users and it's the length of usernames that AppHarbor uses for user accounts created to perform various tasks on the platform.
Here's how to re-create the bug on a system with both .NET 3.5 and 4.5 installed:
- Create a user with a username that's 20 characters long
- Log in as that user and open Visual Studio
- Create any C# project (a console app is known to trigger the bug)
- Change the target framework to 3.5
- Add a resource file (
.resx
) to the project - Build the project
We've made Microsoft aware of the problem and we're working on a workaround. We expect final .NET 4.5 testing to complete in a few days at most and from then on you'll be able to build, test and run .NET 4.5 apps on AppHarbor.
To keep you occupied until then, we're accepting explanations for the cause of the bug in the comments: Why do you think MSBuild fails to build projects with resource files on systems with both .NET 3.5 and 4.5 if the current user's username has a length of 20 characters? The funniest/most-creative/most-accurate guess wins an AppHarbor t-shirt.