When upgrading to Sitecore 8.2, watch out for this issue that we ran into. If you have any View Renderings that don’t end in “.cshtml”, like for example you had an extra space at the end of one of them and it ended in “.cshtml “, you may have a problem. Sitecore, in an effort to be helpful I am sure, will add “.cshtml” to the end of your rendering path if it isn’t already there (I’m guessing someone forgot a .Trim()). If you have an extra space like we did, however, your renderings will break and you will see this:
In order to fix it, just update the path to remove the extra space at the end. In an effort to be helpful myself, I’m including a Sitecore PowerShell command that will help you find the list of offending view renderings. Packaging this command into a fire-and-forget script can be an exercise for the reader. 🙂
(Get-Item /sitecore/layout -Query "/sitecore/layout/renderings//*[@@templatename='View rendering']") | where-object {$_.Path -match ".cshtml " }