skartknet / Iconic

The ultimate icon picker for Umbraco backoffice
MIT License
7 stars 8 forks source link

Duplicate Iconic Property Editors in Umbraco 11 #25

Closed ghost closed 1 year ago

ghost commented 1 year ago

This was after a 10.3.2 to 11 upgrade. But, I even deleted my data types, unintalled Iconic, reinstalled, and readded new data types... same result.

image

image

a-t-k commented 1 year ago

5.2.0-beta3 does not get rid of the problem. Its still two property editors there.

After some changes in Data Types/Icon its not possible to save changed DataType. The PostSave method in FE cause exception in Backend.

(umbraco/backoffice/umbracoapi/datatype/PostSave)

a-t-k commented 1 year ago

Well, i found the Problem.

a-t-k commented 1 year ago

It is wery important to delete old files from iconic addon in app_plugins folder.

Project Type is switched to RCL. When app_plugins folder has old iconic project, then umbraco read it on start of umbraco app too. Then "PropertyEditorCollection" hat two same "property editors" with the same type and same alias in container.

On app start there are no warnings in logs. User cant see what going on. Exception will be throw in another palces. (on vadidation of data type befor controller action executiin starts)

skartknet commented 1 year ago

Thanks @a-t-k . Your right, if you're upgrading the package, some content will be duplicated. As you said, the project is now a Razor Class Library, so all the old files will remain in the project.

I can't find a way of removing the old files. If you have any idea please let me know.

ribsdigital commented 1 year ago

hey @a-t-k and @skartknet i hit this exact same problem today...

my App_Plugins folder is empty, i've cleaned the solution and also gone to the lengths of deleting every bin and obj folder in each project in my solution...

no joy, still got two iconic datatypes in the backoffice and if i try and use either of them i get:


Received an error from the server
An error occurred

Sequence contains more than one matching element
Exception Details
System.InvalidOperationException, System.Private.CoreLib, Version=7.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e: Sequence contains more than one matching element `

has anyone figured out a way out of this?
ribsdigital commented 1 year ago

ok, we managed to work around this by:

  1. uninstalling the package (we were using v5.0.0)
  2. clean the solution (manually deleted the bin and obj)
  3. delete any iconic folders from C:\Users\you-user\.nuget\packages
  4. install the 5.2.0-beta3 version

after spinning up the project we now only have one iconic datatype in the backoffice.

the only byproduct is that we've lost the datatype configuration (this is an upgraded project from v8) but i think we can easily recreate them.

skartknet commented 1 year ago

I'll close this for now, as it looks the problem was solved.