Coder Social home page Coder Social logo

.NET 8 support about bogus HOT 9 CLOSED

felipementel avatar felipementel commented on May 24, 2024
.NET 8 support

from bogus.

Comments (9)

felipementel avatar felipementel commented on May 24, 2024 3

image

Everything is fine!

from bogus.

digitalcoyote avatar digitalcoyote commented on May 24, 2024 1

After .Net 5.0 the .Net Standard was replaced with just .Net x.0. NuGet.org listing .Net 6.0 means that it supports .Net 6.0+, but this specific package may not take advantage of some .Net 7.0+ features.

I've been using Bogus.Net in a couple .Net 7.0 and .Net 8.0 projects.

See: https://devblogs.microsoft.com/dotnet/the-future-of-net-standard/

from bogus.

felipementel avatar felipementel commented on May 24, 2024 1

Yes, I think @digitalcoyote is absolutely correct ^; this was my understanding too.

Cool, @felipementel very glad you got the problem sorted out. Was it a problem with your NuGet.config?

hello @bchavez ,
Those steps to add your package at Package Source Mapping.
At step 3, I type "Bogus*" and click ate step 5

image

from bogus.

bchavez avatar bchavez commented on May 24, 2024

What specifically about .NET 8 needs to be supported?

DateOnly and TimeOnly types were introduced in .NET 6 and there's a .NET 6 TFM distribution already to support those types:

<TargetFrameworks>net40;netstandard1.3;netstandard2.0;net6.0</TargetFrameworks>

IIRC, from a consumer standpoint, any net8.0 TFM application you create automatically uses Bogus' net6.0 TFM distribution.

from bogus.

felipementel avatar felipementel commented on May 24, 2024

@bchavez sorry for late comment, I was travel

When I try to add the Bogus library to my .net 8 project, this happen:

╰─❯ dotnet add package Bogus

Determining projects to restore...
Writing C:\Users\felipe.augusto\AppData\Local\Temp\tmpxcgl2d.tmp
info : X.509 certificate chain validation will use the default trust store selected by .NET for code signing.
info : X.509 certificate chain validation will use the default trust store selected by .NET for timestamping.
info : Adding PackageReference for package 'Bogus' into project 'C:\Proj\DEPLOY\DEPLOY.EntityFramwork.Analize.v1\src\DEPLOY.EntityFramework.v1\DEPLOY.EntityFramework.v1.csproj'.
info : GET https://api.nuget.org/v3/registration5-gz-semver2/bogus/index.json
info : OK https://api.nuget.org/v3/registration5-gz-semver2/bogus/index.json 155ms
info : GET https://api.nuget.org/v3/registration5-gz-semver2/bogus/page/2.1.4/18.0.1.json
info : OK https://api.nuget.org/v3/registration5-gz-semver2/bogus/page/2.1.4/18.0.1.json 167ms
info : GET https://api.nuget.org/v3/registration5-gz-semver2/bogus/page/18.0.2/31.0.3.json
info : OK https://api.nuget.org/v3/registration5-gz-semver2/bogus/page/18.0.2/31.0.3.json 155ms
info : GET https://api.nuget.org/v3/registration5-gz-semver2/bogus/page/32.0.1/35.4.0.json
info : OK https://api.nuget.org/v3/registration5-gz-semver2/bogus/page/32.0.1/35.4.0.json 161ms
info : Restoring packages for C:\Proj\DEPLOY\DEPLOY.EntityFramwork.Analize.v1\src\DEPLOY.EntityFramework.v1\DEPLOY.EntityFramework.v1.csproj...
error: NU1100: Unable to resolve 'Bogus (>= 35.4.0)' for 'net8.0'. PackageSourceMapping is enabled, the following source(s) were not considered: nuget.org. <------- this message is important !!!
info : GET https://api.nuget.org/v3/vulnerabilities/index.json
info : OK https://api.nuget.org/v3/vulnerabilities/index.json 65ms
info : GET https://api.nuget.org/v3-vulnerabilities/2024.02.14.05.49.15/vulnerability.base.json
info : GET https://api.nuget.org/v3-vulnerabilities/2024.02.14.05.49.15/2024.02.15.11.21.40/vulnerability.update.json
info : OK https://api.nuget.org/v3-vulnerabilities/2024.02.14.05.49.15/vulnerability.base.json 16ms
info : OK https://api.nuget.org/v3-vulnerabilities/2024.02.14.05.49.15/2024.02.15.11.21.40/vulnerability.update.json 34ms
error: Package 'Bogus' is incompatible with 'all' frameworks in project 'C:\Proj\DEPLOY\DEPLOY.EntityFramwork.Analize.v1\src\DEPLOY.EntityFramework.v1\DEPLOY.EntityFramework.v1.csproj'.
╭─ pwsh  C:\Proj\DEPLOY\DEPLOY.EntityFramwork.Analize.v1\src\DEPLOY.EntityFramework.v1   main ?1 ~1

and the csproj is:

<Project Sdk="Microsoft.NET.Sdk">

 <PropertyGroup>
   <OutputType>Exe</OutputType>
   <TargetFramework>net8.0</TargetFramework>
   <ImplicitUsings>enable</ImplicitUsings>
   <Nullable>enable</Nullable>
 </PropertyGroup>

 <ItemGroup>
   <PackageReference Include="EntityFramework" Version="6.4.4" />
   <PackageReference Include="Microsoft.EntityFrameworkCore" Version="8.0.1" />
   <PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="8.0.1">
     <PrivateAssets>all</PrivateAssets>
     <IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
   </PackageReference>
   <PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="8.0.1" />
 </ItemGroup>

</Project>

from bogus.

bchavez avatar bchavez commented on May 24, 2024

@felipementel Looks like it works fine here:

image

from bogus.

bchavez avatar bchavez commented on May 24, 2024

> error: NU1100: Unable to resolve 'Bogus (>= 35.4.0)' for 'net8.0'. PackageSourceMapping is enabled, the following source(s) were not considered: nuget.org. <------- this message is important !!!

Yes, I do think the message is important.

You probably want to check your NuGet.config (and any project directory tree .configs or Directory.Build.props/targets ) for anything obscure or custom PackageSourceMappings because the error message says "nuget.org was not considered for resolving the Bogus package" it seems.

from bogus.

felipementel avatar felipementel commented on May 24, 2024

> error: NU1100: Unable to resolve 'Bogus (>= 35.4.0)' for 'net8.0'. PackageSourceMapping is enabled, the following source(s) were not considered: nuget.org. <------- this message is important !!!

Yes, I do think the message is important.

You probably want to check your NuGet.config (and any project directory tree .configs or Directory.Build.props/targets ) for anything obscure or custom PackageSourceMappings because the error message says "nuget.org was not considered for resolving the Bogus package" it seems.

Thanks to answer!

At nuget.org website, don't have a support to .NET 8

image

I will continue to try to install the package

from bogus.

bchavez avatar bchavez commented on May 24, 2024

Yes, I think @digitalcoyote is absolutely correct ^; this was my understanding too.

Cool, @felipementel very glad you got the problem sorted out. Was it a problem with your NuGet.config?

from bogus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.