Upgrading from 6.0.0 to 6.0.5: Sequence contains more than one matching element
Hi,
I tried to upgrade a site from 6.0.0 to 6.0.5. The installer seemed to do it's job, and the site seemed to be working as expected.
However, when logging in to the /umbraco backend, after posting the username/password i get a error telling me
Sequence contains more than one matching element
[InvalidOperationException: Sequence contains more than one matching element]
System.Linq.Enumerable.SingleOrDefault(IEnumerable`1 source, Func`2 predicate) +4140586
Umbraco.Core.PluginManager.UpdateCachedPluginsFile(IEnumerable`1 typesFound, TypeResolutionKind resolutionType) +381
Umbraco.Core.PluginManager.LoadViaScanningAndUpdateCacheFile(TypeList typeList, TypeResolutionKind resolutionKind, Func`1 finder) +238
Umbraco.Core.PluginManager.ResolveTypes(Func`1 finder, TypeResolutionKind resolutionType, Boolean cacheResult) +1357
umbraco.BusinessLogic.Actions.Action.RegisterIActionHandlers() +131
umbraco.BusinessLogic.Actions.Action.ReRegisterActionsAndHandlers() +316
[TypeInitializationException: The type initializer for 'umbraco.BusinessLogic.Actions.Action' threw an exception.]
umbraco.BusinessLogic.Actions.Action.GetJavaScriptFileReferences() +0
umbraco.cms.presentation._umbraco.RenderActionJS() +83
umbraco.cms.presentation._umbraco.Page_Load(Object sender, EventArgs e) +1706
umbraco.BasePages.BasePage.OnLoad(EventArgs e) +19
System.Web.UI.Control.LoadRecursive() +71
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3178
After searching the forums and google'ing a bit, there seems to be various reasons for the error.
For one, the upgrade script was corrupted in 6.0.1 - but should be fixed in 6.0.2. Also, i cannot see any dropped, nor duplicated properties. Another suggestion is file access rights. I've tried to set Full access to Everyone, so i'm pretty sure that's not the issue either. Also there are some indications that a seperate app-pool is preferred.
The site runs on IIS 7.5, a seperate app-pool that runs framework 4.0
The stacktrace tells us that UpdateCachedPluginsFile is the method initiating the SingleOrDefault call.
Well i rolled back the installation, reverted all the files and rolled back the database. However the problem remained (wich was mighty wierd since a test server worked - with the same database).
It turned out that for some reason the ~\App_Data\TEMP\PluginCache files got stuck. Removing them solved the problem.
I ran the upgrade again, and it worked fine this time around.
Come to think about it i refreshed the last step of the installation wizard the first try. I recalled in Visual studio that web.config got rewritten before AND after the refresh. I had lunch with @enkelmedia who for some reason told me (not related to solving this problem) that the installation of plugins doesn't overwrite lines i config files, but rather adds them. I assume that my problem is related to that. Wether or not that is correct, my site works now, and im happy again.
Upgrading from 6.0.0 to 6.0.5: Sequence contains more than one matching element
Hi,
I tried to upgrade a site from 6.0.0 to 6.0.5.
The installer seemed to do it's job, and the site seemed to be working as expected.
However, when logging in to the /umbraco backend, after posting the username/password i get a error telling me
Sequence contains more than one matching element
After searching the forums and google'ing a bit, there seems to be various reasons for the error.
For one, the upgrade script was corrupted in 6.0.1 - but should be fixed in 6.0.2. Also, i cannot see any dropped, nor duplicated properties. Another suggestion is file access rights. I've tried to set Full access to Everyone, so i'm pretty sure that's not the issue either. Also there are some indications that a seperate app-pool is preferred.
The site runs on IIS 7.5, a seperate app-pool that runs framework 4.0
The stacktrace tells us that UpdateCachedPluginsFile is the method initiating the SingleOrDefault call.
I've got four plugins installed:
Hor do i solve it?
Ok...
Well i rolled back the installation, reverted all the files and rolled back the database.
However the problem remained (wich was mighty wierd since a test server worked - with the same database).
It turned out that for some reason the ~\App_Data\TEMP\PluginCache files got stuck. Removing them solved the problem.
I ran the upgrade again, and it worked fine this time around.
Come to think about it i refreshed the last step of the installation wizard the first try. I recalled in Visual studio that web.config got rewritten before AND after the refresh. I had lunch with @enkelmedia who for some reason told me (not related to solving this problem) that the installation of plugins doesn't overwrite lines i config files, but rather adds them. I assume that my problem is related to that. Wether or not that is correct, my site works now, and im happy again.
is working on a reply...