OpenRIAServices / OpenRiaServices

The Open RIA Services project continues what was previously known as WCF RIA Services.
https://openriaservices.gitbook.io/openriaservices/
Apache License 2.0
54 stars 48 forks source link

Visual studio extension OpenRiaServicesLibrary project template fails in VS 2017 #227

Open andrewhenry3 opened 4 years ago

andrewhenry3 commented 4 years ago

The Open Ria Services extension in the Visual Studio Marketplace (Version 0.0.9.3) fails to create a project from the OpenRiaServicesLibrary template.

Installed 0.0.9.3 into VS 2017, created a new Open Ria Services C# OpenRiaServicesLibrary project. Got error "Package Installation Error" - Count not add all required packages to the project. The following packages failed to install from 'C:\Users\Ahenry\appdata\local\microsoft\visualstudio\15.0_A19BC0B1\EXTENSIONS\IHTCLTH3.FZU\Packages': OpenRiaServices.Client.4.6.3 : Unable to find version '4.6.3' of package 'OpenRiaServices.Client'.
Only minimal projects with no OpenRia references or link were created.

Tested with VS 15.9.20 and 15.9.11

andrewhenry3 commented 4 years ago

Here's the contents of the extension folder from that install

InstalledExtensionFolder.zip

Daniel-Svensson commented 4 years ago

Thank you for reporting the issue I will se if I can understand why it happens.

In the mean time I recommend a workaround

  1. create 2 project manually (client and server project)
  2. In client project install "OpenRiaServices.Client" (or "OpenRiaServices.Client.Core" and "OpenRiaServices.Client.CodeGen")
  3. In server project install "OpenRiaServices.Server"
  4. Right click client project and choose "Manage Open RIA Services Project Link" image
  5. In the dropdown select the server project and then choose if you want to generate the webContext class (true if you only have a single project with code generation enabled)
Daniel-Svensson commented 4 years ago

When we release the tooling for OpenRiaServices v5 I think it would be a good idea to change the wizards so that it searches for the latest release on nuget and installs that version instead of trying to use the built in extension nuget support.

andrewhenry3 commented 4 years ago

The workaround mostly did the job but some of the required references aren't added with the Client nuget install. I needed System.ComponentModel.DataAnnotations, System.Runtime.Serialization, and System.ServiceModel .

Daniel-Svensson commented 4 years ago

Thanks for the feedback. What Target framework you use for the client and did you use the newer "sdk" style project or the classic version?

andrewhenry3 commented 4 years ago

Classic style, 4.6.2

Daniel-Svensson commented 2 years ago

@andrewhenry3 is this still a problem, with the latest plugin?

andrewhenry3 commented 2 years ago

The original error still comes up for me when creating a project from the template, just the version numbers that it complains about have updated to 5.0.0. Tested in VS 2017 and 2019. I haven't tried manually creating new projects in 5.0 yet.

Daniel-Svensson commented 2 years ago

Thank you for trying it out again, I will not be able to look inte this in the near future but feel free to give it a try if you are interested.