question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Mapster.EFCore does not support .net 6

See original GitHub issue

Mapster.EFCore.Tests

  • change from .netcore3.1 to .net 6
  • update nugets
  • run EFCoreTest.TestFindObject
  •        dto.BuildAdapter()
              .**EntityFromContext**(context)
              .AdaptTo(poco);
    

Test method Mapster.EFCore.Tests.EFCoreTest.TestFindObject threw exception: System.MissingMethodException: Method not found: ‘System.Type Microsoft.EntityFrameworkCore.Metadata.ITypeBase.get_ClrType()’. at Mapster.TypeAdapterBuilderExtensions.<>c__DisplayClass0_01.<EntityFromContext>b__0(TypeAdapterConfig config) at Mapster.TypeAdapterConfig.<>c__DisplayClass99_0.<Fork>b__0(String _) in C:\Dev\Github\Mapster\src\Mapster\TypeAdapterConfig.cs:line 705 at System.Collections.Concurrent.ConcurrentDictionary2.GetOrAdd(TKey key, Func2 valueFactory) at Mapster.TypeAdapterConfig.Fork(Action1 action, String key1, Int32 key2) in C:\Dev\Github\Mapster\src\Mapster\TypeAdapterConfig.cs:line 702 at Mapster.TypeAdapterBuilder1.ForkConfig(Action1 action, String key1, Int32 key2) in C:\Dev\Github\Mapster\src\Mapster\TypeAdapterBuilder.cs:line 39 at Mapster.TypeAdapterBuilderExtensions.EntityFromContext[TSource](TypeAdapterBuilder`1 builder, DbContext context) in C:\Dev\Github\Mapster\src\Mapster.EFCore\TypeAdapterBuilderExtensions.cs:line 18 at Mapster.EFCore.Tests.EFCoreTest.TestFindObject() in C:\Dev\Github\Mapster\src\Mapster.EFCore.Tests\EFCoreTest.cs:line 37

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

5reactions
QadiymStewartcommented, Aug 8, 2022

Doesn’t work still getting an error

[2022-08-08T14:42:57.453Z] Error: System.MissingMethodException: Method not found: ‘System.Type Microsoft.EntityFrameworkCore.Metadata.ITypeBase.get_ClrType()’. at Mapster.TypeAdapterBuilderExtensions.<>c__DisplayClass0_01.<EntityFromContext>b__0(TypeAdapterConfig config) at Mapster.TypeAdapterConfig.<>c__DisplayClass99_0.<Fork>b__0(String _) at System.Collections.Concurrent.ConcurrentDictionary2.GetOrAdd(TKey key, Func2 valueFactory) at Mapster.TypeAdapterConfig.Fork(Action1 action, String key1, Int32 key2) at Mapster.TypeAdapterBuilderExtensions.EntityFromContext[TSource](TypeAdapterBuilder`1 builder, DbContext context)

0reactions
apphostcommented, Jul 28, 2022

still not fixed yet?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Enjoy Using Mapster in .Net 6
Today, developers are paying more attention to mapping libraries than ever before, because modern architecture forces them to map object to ...
Read more >
Getting Started With Mapster in ASP.NET Core
Mapster is an object-to-object mapper used in .NET projects. Let's learn what it can do and how it compares to the giants like...
Read more >
Mapster.EFCore 5.1.0
Mapster.EFCore 5.1.0 .NET Standard 2.1. There is a newer prerelease version of this package available.
Read more >
Object Mapping - Mapster | ASP.NET 6 REST API Following ...
If the mapping is simple, the mapping library doesn't add any real value and I would prefer to manually map it. AutoMapper/ Mapster...
Read more >
Enjoy using Mapster in .Net 6 :: Articles - Sergey Drozdov
I don't know why some programmers choose this way for mapping! ... IRegister is an interface in Mapster library so it implemented to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found