skybrud / Skybrud.Umbraco.Redirects

Redirects manager for Umbraco.
https://packages.limbo.works/skybrud.umbraco.redirects/
MIT License
36 stars 41 forks source link

backoffice not rendering in v10 #159

Closed dampee closed 1 year ago

dampee commented 1 year ago

After deploy on production, we get a bizar javascript error, and the layout is screwed up. This is only on the content nodes and not on the dashboard.

this is the error and stacktrace from the javascript console

Error: [$compile:multidir] http://errors.angularjs.org/1.8.3/$compile/multidir?p0=skybr…plate&p5=%3Cskybrud-redirects-node%20node%3D%22vm.node%22%3E
    F http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:25
    ba http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:103
    aa http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:96
    ha http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:102
    k http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:159
    $digest http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:171
    $apply http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:174
    k http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:125
    v http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:131
    onload http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:131
umbraco-backoffice-js.js.v638024121250000000:147:202
    e http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:147
    get http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:118
    ha http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:103
    k http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:159
    $digest http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:171
    $apply http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:174
    k http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:125
    v http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:131
    onload http://our.stagingdomain.com/sb/umbraco-backoffice-js.js.v638024121250000000:131

afbeelding

abjerner commented 1 year ago

Hi @dampee

What version of Umbraco and Skybrud Redirects are you running?

It sounds a lot like this issue (which should be fixed as of 4.0.1): https://github.com/skybrud/Skybrud.Umbraco.Redirects/issues/148

dampee commented 1 year ago

It was indeed after an upgrade to the latest version (umbraoc 10.3 + 4.0.2) After reading the issue you mentioned above, I read that you switched to embedded resources. Then the "multidir" error started to make sense.

This error means that the App_Plugins/Skybrud.Umbraco.Redirects folder was still available on the production server AND as embedded resource in the DLL.

After deleting this folder it seems to work flawless.

abjerner commented 1 year ago

Great to hear it works 👍

With Razor Class Libraries, the files are embedded in the NuGet package, and not the DLL, so locally the files are served from the NuGet package, but in production it should still be physical files.

The culprit behind the issue seemed to be because Umbraco introduced a redirectsNode directive that then conflicted with my directive of the same name, so mine was renamed to skybrudRedirectsNode. If you already had upgraded to 4.0.2, I'd say you still experienced the issue because the Node.js file somehow wasn't properly updated in production.