Developer forum

Forum » Dynamicweb 9.0 Upgrade issues » Error after upgrade from 9.4.18 to 9.5.1

Error after upgrade from 9.4.18 to 9.5.1

Harald Brouwers
Reply

Hi there,

I just did an upgrade to the latest DW version (DW 9.5.1 and updated all packages offered by the DW via nuget). And now I'm getting errors when I try to do a publish in VisualStudio. The error is:

The file is: Admin\Content\Area\Sort.aspx

And also the Admin is giving me Dynamicweb.UI.Controls related errors:

Can you offer a solution for this problem?

Greetings Harald


Replies

 
Nicolai Pedersen
Reply

Hi Harald

Obviously you have package references that are not updated.

You have to ensure you updated Dynamicweb.Admin and all its dependencies.

In your visual studio solution open the package manager, how does it look like on the update tab?

In nuget You can run an update-package -reinstall on the admin package in the console and see if that will help. Alternatively uninstall the admin package and install it again.

Sorry about the inconvenience.

BR Nicolai

 
Harald Brouwers
Reply

Hi Nicolai,

Thanks for you resonse.
I already installed all possible updates from the Dynamicweb Myget repository. In VisualStudio the package manager looks like this:

Just to be sure I ran a reinstall (Update-Package Dynamicweb.Admin -Reinstall) of the Admin. But the problem is still the same. I attached my packages.config.

 
Nicolai Pedersen
Reply

Well - somewhere in you /Bin you have old dll's. Did you remember to do a clean and rebuild? Updating the package references will just update the package cache - you need to rebuild and maybe clean for the new dlls to get copied into your /bin folder.

From MyGet the admin package, you can see the required version - see dump.

Check the dll in your /bin if that is this version after the rebuild - if not, you need to figure out why - you have to check your output window in VS to see if it give pointers.

BR Nicolai

Capture.PNG
 
Harald Brouwers
Reply

Hi Nicolai,

I cleaned the project and did a new build. Then I checked the bin folder for the version of the dll. This is the latest version, but still the problem persists.

Greetings Harald

 
Nicolai Pedersen
Reply

I need to see your IIS setup - is /Admin a virtual directory?

Can you provide a dump of your website in IIS (the website expanded in the tree) and your folder structure

 
Harald Brouwers
Reply

This is my current IIS setup, the admin is not a virtual directory. I tested changing it to a virtual directory but that made no difference.

 
Nicolai Pedersen
Reply

It seems that your /Admin is not 9.5

So somehow your /admin is not updated

 
Harald Brouwers
Reply

Hi Nicolai,

I did some further testing and to start I started a new VisualStudio Project and did a clean install of the Dynamicweb.Admin package. Then I compared the bin folder of the new installation with the bin folder of the upgraded solution. And there were a lot of differences:

I compared the Admin directory of the fresh nuget install with the Downloadable version on the website and there were 237 files missing in the nuget version of the Admin. So I copied those to my own project Admin

And I copy the bin folder of the clean install to my own project, now the error dissapears,

On a rebuild all the. xml files in the bin which were initially installed are removed. But that proves no problems as far as I can see.

The question which remains is, why is the upgrade via nuget failing, while copying the files of a clean nuget installation does work. And why are there so much differences between the downloadable version of the Dw core and the NuGet version.

Greetings Harald

 
Nicolai Pedersen
Reply

Hi Harald

It is the same files in both. I looked a little closer - what happened here is that the Dynamicweb.Admin package has a dependency for Dynamicweb.UI.Controls 1.9 as I showed you in the first thread. If you look at the version you had in your bin, you have version 2.0.1 - which is a new major - which apperently is not compatible with 9.5.1 version of the admin package. So when you upgraded you admin package, you took newest versions of all dependencies, and that caused this to happen.

So that is the explanation - the UI.Controls should have been backwards compatible from our side - that is why you see the exception(s).

I will have the Dynamicweb.UI.Controls fixed again.

Sorry about the inconvenience.

BR Nicolai

 
Harald Brouwers
Reply

Hi Nicolai,

I disagree that the Admin's (the downloadable version and the NuGet version) are the same. For examle the Dictionary files are missing from the nuget version and also several javascript files, for example:

And about the Dynamicweb.UI.Controls version. In an earlier stage I tried downgrading the Dynamicweb.UI.Controls to version 1.9.0 to test if that would solve the problem. But that was not the case at that time. So there might be more going on.

Greetings Harald

 
Nicolai Pedersen
Reply

Hi Harald

It is the same dll version/build at least with the same references.

I will have the build team look into if they can conclude the same missing files and find out why.

BR Nicolai

 
Harald Brouwers
Reply
This post has been marked as an answer

Hi Nicolai, thanks for the response and looking into the problem!

One other thing which gave me troubles:
I created a copy of my WebApp in azure, to test the update to 9.5.1. After I did a publish I got a "Object reference not found" error, and the site and admin stopped working. In the DW logging the following error:

2018-09-18 12:51:04.557: Could not send email to sha@dynamicweb.dk. System.Web.HttpException (0x80004005): Request is not available in this context    at System.Web.HttpContext.get_Request()    at System.Web.HttpContextWrapper.get_Request()    at Dynamicweb.Environment.Web.SystemWebContextManager.get_Request()    at Dynamicweb.Mailing.EmailHandler.Send(MailMessage mailMessage, Boolean logging, Boolean throwException)

After some searching, the solution was to delete the .licence file to get the solution working again.

Greetings Harald

Votes for this answer: 1
 
Nicolai Pedersen
Reply

Thanks - will take look at that. But basically this seems to be caused by the solution not being able to talk to our license service.

 
Martin Vang
Martin Vang
Reply

Hi Harald,

I've bugged it as TFS #55200 with a high priority.

BR

Martin

 

You must be logged in to post in the forum