<" /> <" /> <"/>

NU1102 Unable to find package Communications.Interface with version (>= 6.0.0)

23 Views Asked by At

I have a .net class library called Communications.Interface, this is the .csproj of this project :

  <Project Sdk="Microsoft.NET.Sdk">
  <PropertyGroup>
    <TargetFramework>net6.0</TargetFramework>
    <ImplicitUsings>enable</ImplicitUsings>
    <Nullable>enable</Nullable>
    <GeneratePackageOnBuild>true</GeneratePackageOnBuild>
    <Title>Communications Interface</Title>
    <Authors>X</Authors>
    <Description>Communication services</Description>
    <PackageReleaseNotes>Added language to notification templates.</PackageReleaseNotes>
    <Copyright>2022-2023</Copyright>
    <PackageId>Communications.Interface</PackageId>
    <PackageVersion>2.0.0</PackageVersion>
  </PropertyGroup>
</Project>

I want to upgrade the package version of this library so I change it from <PackageVersion>2.0.0</PackageVersion> to <PackageVersion>6.0.0</PackageVersion> then I built it, everything went fine until I refer to this library in another one in the same solution called Communication.

This is the .csproj of Communication project :

<Project Sdk="Microsoft.NET.Sdk">
  <PropertyGroup>
    <TargetFramework>net6.0</TargetFramework>
    <ImplicitUsings>enable</ImplicitUsings>
    <Nullable>enable</Nullable>
    <GeneratePackageOnBuild>true</GeneratePackageOnBuild>
    <Title>Communications</Title>
    <Authors>X</Authors>
    <Description>Communication services</Description>
    <PackageReleaseNotes>Communication services</PackageReleaseNotes>
    <Copyright>2022-2023</Copyright>
    <PackageId>Communications</PackageId>
    <PackageVersion>2.0.0</PackageVersion>
  </PropertyGroup>
  <ItemGroup>
    <PackageReference Include="MailKit" Version="4.1.0" />
    <PackageReference Include="Microsoft.Extensions.Configuration" Version="6.0.1" />
    <PackageReference Include="Microsoft.Extensions.Options" Version="6.0.0" />
    <PackageReference Include="Communications.Interface" Version="2.0.0" />
  </ItemGroup>
</Project>

So I ofcourse changed from <PackageReference Include="Communications.Interface" Version="2.0.0" /> to <PackageReference Include="Communications.Interface" Version="6.0.0" /> and also change the package version from <PackageVersion>2.0.0</PackageVersion> to <PackageVersion>6.0.0</PackageVersion> and built it.

Then it gives me this error :

Severity    Code    Description Project File    Line    Suppression State
Error   NU1102  Unable to find package Communications.Interface with version (>= 6.0.0)
  - Found 4 version(s) in DotNetPackages [ Nearest version: 2.0.0 ]
  - Found 0 version(s) in nuget.org Communications  

Can anyone help me ? PS: I didn't publish this change in azure yet

0

There are 0 best solutions below