Unable to resolve 'dotnet-svcutil (>= 0.5.10306-preview)' for '.NETCoreApp,Version=v1.1'
Scaffolding Code ... Error:Error: Restoring packages for C:\Users\Administrator\AppData\Local\Temp\WCFConnectedService\2017_Mar_17_20_34_33\svcutil_bootstrap\project.csproj... Restoring packages for C:\Projects\WorkSpace\Nic\Server API\ServerAPI\ServerAPI\ServerAPI.csproj... Restoring packages for C:\Projects\WorkSpace\Nic\Server API\ServerAPI\ViewModelCore\ViewModelCore.csproj... Restoring packages for C:\Projects\WorkSpace\Nic\Server API\ServerAPI\DbModelCoew\ModelCore.csproj... Lock file has not changed. Skipping lock file write. Path: C:\Projects\WorkSpace\Nic\Server API\ServerAPI\ViewModelCore\obj\project.assets.json Restore completed in 871.15 ms for C:\Projects\WorkSpace\Nic\Server API\ServerAPI\ViewModelCore\ViewModelCore.csproj. Lock file has not changed. Skipping lock file write. Path: C:\Projects\WorkSpace\Nic\Server API\ServerAPI\DbModelCoew\obj\project.assets.json Restore completed in 1.25 sec for C:\Projects\WorkSpace\Nic\Server API\ServerAPI\DbModelCoew\ModelCore.csproj. C:\Program Files\dotnet\sdk\1.0.0\NuGet.targets(97,5): error : Unable to resolve 'dotnet-svcutil (>= 0.5.10306-preview)' for '.NETCoreApp,Version=v1.1'. [C:\Users\Administrator\AppData\Local\Temp\WCFConnectedService\2017_Mar_17_20_34_33\svcutil_bootstrap\project.csproj] Lock file has not changed. Skipping lock file write. Path: C:\Projects\WorkSpace\Nic\Server API\ServerAPI\ServerAPI\obj\project.assets.json Restore completed in 3 sec for C:\Projects\WorkSpace\Nic\Server API\ServerAPI\ServerAPI\ServerAPI.csproj. Generating MSBuild file C:\Users\Administrator\AppData\Local\Temp\WCFConnectedService\2017_Mar_17_20_34_33\svcutil_bootstrap\obj\project.csproj.nuget.g.props. Generating MSBuild file C:\Users\Administrator\AppData\Local\Temp\WCFConnectedService\2017_Mar_17_20_34_33\svcutil_bootstrap\obj\project.csproj.nuget.g.targets. Writing lock file to disk. Path: C:\Users\Administrator\AppData\Local\Temp\WCFConnectedService\2017_Mar_17_20_34_33\svcutil_bootstrap\obj\
Same issue to #1807?
This issue is reported by a different customer(Sinoheh Enayati) on the download page. It could be same issue. Waiting for Sinoheh confirmation to see if it needs further investigation.
I just received this same error.
[3/21/2017 6:41:30.073 AM] Adding WCF Service - Preview to the project. [3/21/2017 6:41:30.088 AM] Scaffolding Code ... [3/21/2017 6:41:37.652 AM] Error:Error: Restoring packages for C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap\project.csproj... Restoring packages for C:\Dev\Test Projects\aspnetcorewcf\aspnetcorewcf\aspnetcorewcf.csproj... Lock file has not changed. Skipping lock file write. Path: C:\Dev\Test Projects\aspnetcorewcf\aspnetcorewcf\obj\project.assets.json Restore completed in 1.41 sec for C:\Dev\Test Projects\aspnetcorewcf\aspnetcorewcf\aspnetcorewcf.csproj. C:\Program Files\dotnet\sdk\1.0.1\NuGet.targets(97,5): error : Unable to resolve 'dotnet-svcutil (>= 0.5.10306-preview)' for '.NETCoreApp,Version=v1.1'. [C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap\project.csproj] Generating MSBuild file C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap\obj\project.csproj.nuget.g.props. Generating MSBuild file C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap\obj\project.csproj.nuget.g.targets. Writing lock file to disk. Path: C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap\obj\project.assets.json Restore failed in 2.74 sec for C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap\project.csproj.
Errors in C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap\project.csproj Unable to resolve 'dotnet-svcutil (>= 0.5.10306-preview)' for '.NETCoreApp,Version=v1.1'.
NuGet Config files used: C:\Users\pennerg\AppData\Roaming\NuGet\NuGet.Config C:\Program Files (x86)\NuGet\Config\Microsoft.VisualStudio.Offline.config C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap\NuGet.Config
Feeds used:
https://api.nuget.org/v3/index.json
C:\Program Files (x86)\Microsoft SDKs\NuGetPackages
An error occurred while bootstrapping svcutil. This usually happens when processing references. You might be able to work around this problem by not providing reference parameters, and manually removing any types redefined in the generated proxy code.
Failed to generate service reference. [3/21/2017 6:41:37.824 AM] Failed adding WCF Service - Preview to the project.
I am using Visual Studio 2017 Enterprise on Windows 7
@gregp55305 Could you check the below Nuget.Config file to see if package resource 'local' is disabled machine wise?
c:\Users\pennerg\AppData\Roaming\NuGet\NuGet.Config C:\Program Files (x86)\NuGet\Config\Microsoft.VisualStudio.Offline.config
If so, you can workaround the issue by rename the disabled 'local' package source.
Please let me know if it helps, Thanks, Hong
I don't see a package source called 'local' in either of those config files. Here are the contents of both of those config files:
NuGet.Config:
Microsoft.VisualStudio.Offline.Config:
Hmm the contents of the config files didn't paste...
NuGet.Config:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<activePackageSource>
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
</activePackageSource>
<packageSources>
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" />
<add key="IHC Package Source" value="http://ihcphxdevweb01.iac.com/ihcnuget/nuget" />
</packageSources>
<packageRestore>
<add key="enabled" value="True" />
<add key="automatic" value="True" />
</packageRestore>
<bindingRedirects>
<add key="skip" value="False" />
</bindingRedirects>
<disabledPackageSources />
</configuration>
Microsoft.VisualStudio.Offline.Config:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<add key="Microsoft Visual Studio Offline Packages" value="C:\Program Files (x86)\Microsoft SDKs\NuGetPackages\"/>
</packageSources>
</configuration>
Sorry for the formatting...
@gregp55305 in the C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap\NuGet.Config, could you check if dotnet-svcutil.0.5.10306-preview.nupkg exists in the 'local' package source path?
@gregp55305 I noticed that you global Nuget config file specify only one active package resource. This might cause package not found problem according to http://docs.myget.org/docs/how-to/nuget-configuration-inheritance.
Could you change it to below:
<activePackageSource>
<add key="All" value="(Aggregate source)" />
</activePackageSource>
Thanks, Hong
I'll check that when I get back to work tomorrow. Would it be possible for you to post an example of a global Nuget config file or does that not make sense?
This is what on my machine. Be aware of that I do not use activePackageSource.
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" />
</packageSources>
<packageRestore>
<add key="enabled" value="True" />
<add key="automatic" value="True" />
</packageRestore>
<bindingRedirects>
<add key="skip" value="False" />
</bindingRedirects>
<packageManagement>
<add key="format" value="0" />
<add key="disabled" value="False" />
</packageManagement>
</configuration>
You have referred to a 'local' package source a couple of times, what exactly does that mean?
@gregp55305 We uses this name in our bootstrap tool, you can see an example in C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap\NuGet.Config
I updated the activePackageSource value to what you suggested and then closed out of all instances of Visual Studio. I also located the nuget.config file with the 'local' reference and confirmed the path for the packageSource in that file does exist. Then restarted VS 2017, but the end result was the same when trying to generate connected wcf service.
@gregp55305 I'm sorry to hear that you are still hitting the issue. To further diagnose, Could you:
- go to folder C:\Users\pennerg\AppData\Local\Temp\WCFConnectedService\2017_Mar_21_06_41_30\svcutil_bootstrap
- Rename 'Local' in the NeGet.Config to a Guid(to make sure it's unique across your machine).
- The run the command:
dotnet restore
Let me know if step 3) succeeded for you.
Thanks, Hong
step 3 did succeed. I assume that you wanted me to run dotnet restore from the project root directory.
Or did I need to run that from the svcutil_bootstrap directory?
I ran 'dotnet restore' from the svcutil_bootstrap directory. That failed. The message is familiar. "Unable to resolve 'dotnet-svcutil ()= 0.5.10306-preview' for '.NETCoreApp,Version=v1.1
This looks like a nuget problem. There is one more thing you can try.
- Go to the svcutil_bootstrap.
- dotnet add package dotnet-svcutil -v 0.5.10306-preview -s "the path to where the package located"
- If 2) succeed, it will cache the package in your local nuget package cache, the issue should be gone.
Progress, but no success: Received another error:
`[3/22/2017 1:47:35.233 PM] Adding WCF Service - Preview to the project. [3/22/2017 1:47:35.242 PM] Scaffolding Code ... [3/22/2017 1:48:03.091 PM] Error:Warning: Cannot import wsdl:binding Detail: An exception was thrown while running a WSDL import extension: System.ServiceModel.Channels.StandardBindingImporter Error: The method or operation is not implemented. XPath to Error Source: //wsdl:definitions[@targetNamespace='CustomerProfile.AgentService.AgentService']/wsdl:binding[@name='BasicHttpBinding_IAgentService'] Warning: Cannot import wsdl:port Detail: XPath to Error Source: //wsdl:definitions[@targetNamespace='http://tempuri.org/']/wsdl:service[@name='AgentService']/wsdl:port[@name='BasicHttpBinding_IAgentService'] Error: No endpoints compatible with .Net Core apps were found.
Failed to generate service reference. [3/22/2017 1:48:03.140 PM] Failed adding WCF Service - Preview to the project.`
Great to hear it work around the Nuget issue!
For the new issue you hit, it looks like your service requires a feature .dotnet core does not support yet, such as message security. See a similar issue in https://github.com/dotnet/wcf/issues/1354