The Angular Workbook from Umbraco has revealed that I’m probably much better at making property editors than making drinks…
Issues upgrading to Umbraco 7.2 (and how to resolve them)
Here are the stumbling blocks I found in my upgrade from Umbraco 7.1.2 to Umbraco 7.2.
- Can’t get to verify upgrade page (spins forever)
- DependencyHandler.axd not found (404)
- Content nodes in list view don’t appear in search
How I upgraded
I have a Visual Studio 2013 project with the UmbracoCms package installed via nuget. I’ve done extensive customization of the web.config (mostly url rewriting but some other things too) but most other things are out of the box. So after checking in my existing code base, I felt pretty confident in following the general upgrade guides instructions to open the Package Console and type
Now the general upgrade guide directs people upgrading to 7.2.0 to skip all of the information about how to respond to the overwrite prompts. So I chose not let nuget overwrite my files since that is the default action.
Unfortunately the guide also directs us to skip the section that talks about merging configuration files which is how I ran into my first problem.
Can’t get to the “verify upgrade” page (spins forever)
Solution: Merge your config files (mainly web.config)
Since I didn’t have any language or ui.xml files to merge, I went straight to the finalize section of the guide and opened my site. I got to a page with the Umbraco logo and the gray background and then just sat there. Things were spinning but nothing was happening.
The way to make it stop is to go back and merge your config files. This may seem pretty obvious to you smart people out there but the guide did specifically say I should skip that section if upgrading to 7.2.0 (as of this writing).
DependencyHandler.axd not found (404)
Solution: Make sure you’re not rewriting it!
Now I was at the verify upgrade page. I clicked the button and read the facts. (do you think the two people with cats named Umbraco are the same two that have the Umbraco tattoo?). The installation finished and then it tried to redirect me to the backoffice… where it spun.
Luckily I’ve run into this problem before. I used Fiddler (a tool for watching http requests among other things) to see what was really happening. Sure enough /DependencyHandler.axd was returning a 404. I added that to my rule for excluding rewriting and things started working again. In case you’re wondering, here is what that rule looks like.
<!-- [ 1.] Filter out things that shouldn't be rewritten -->
<!-- Whitelist: Stop rewrite processing immediately for locations that don't need it -->
<rule name="StopRewriting" stopProcessing="true">
<match url="^(css|scripts|umbraco|umbraco_client|install|media|webresource.axd|scriptresource.axd|dependencyhandler.axd)" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="None" />
Content nodes in list view don’t appear in search
Solution: Rebuild and optimize your Internal Index
When I finally got into the mecca that is Umbraco 7.2 I was instantly disappointed that my most anticipated feature (the ability to link to/select things from list view) wasn’t working. No matter what list view item I searched for, it wouldn’t show results. Searching from directly within the list view worked as normal but those pages weren’t appearing in either the main backoffice search or the specific one that appears when you try to link to a list view page.
Luckily rebuilding and optimizing my index gets this working in a flash. I can only presume that either these nodes never showed up in main search before (and I never noticed) or there was some change to the way they are represented that requires the re-indexing.
Even with those three issues, this was still one of the smoothest upgrades I’ve encountered with Umbraco and nuget. I’ll continue testing the upgrade locally for a few days before deploying it to production.
Edited Note: When publishing an upgraded Umbraco to production (at least with this version) you need to update your web.config to reflect the original version number. This will allow the install (complete with any database changes) to run on the remote server. Just change your version number back to 7.2.0 when finished with the publish.
How to fix the “could not load file or assembly for [some package you already uninstalled]” Message
You’re getting a “could not load file or assembly” error message for some Umbraco package that you’ve already installed. You’ve searched for and deleted every reference to said package from code and removed the dlls from bin.
It continues to happen, making you want to stab things.
Touch your global.asax file. No seriously. Apparently that clears the plugincache. Or something. Sigh.
Back Story and Source
Once upon a time, I installed the CMSImport plugin on Umbraco 7.0.1. I needed to import some news articles and it looked like the tool for the job.
It was great! I imported all the things and it worked and birds sang and people were all happy and stuff. But then it was over, I was finished with CMSImport and did not want to import things anymore. So I uninstalled it. Because that’s what you do in these situations.
This seemed to make my installation very unhappy. I guess it missed CMSImport. It started throwing weird errors when I did things like delete a media file. The ghost of CMSImport was haunting me without leaving a trace in the.. trace… log. Anyway. To cut straight to the point, when my weeks of randomly deleting files and sporadic Googleing failed as if no one in the face of the internet has ever had this problem before, I bit the bullet and upgraded to 7.0.4.
I won’t get into how I had to try that 3 times and then ended up not even running the installer. (grrr). Lets just say that when I loaded my fresh installation and deleted a file, I got the same error.
Then I stumbled across this throwaway comment on a completely different issue (emphasis mine).
…could you try touching the global.asax file (just put a space in it and save it) to see if that helps? Sounds like the plugincache is in an invalid state and this helps clear it.
So I did that and it worked. I hope it works for you.