Base solution for your next web application
Ends in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

Updating Module Zero #4579


User avatar
0
omarsultan created

I am getting internal server error while login in (api/services/app/Session/GetCurrentLoginInformations), after updating all of my nuget packages, what is the problem here ?

thanks in advance


6 Answer(s)
  • User Avatar
    0
    aaron created
    Support Team

    What's the error?

  • User Avatar
    0
    omarsultan created

    error happens in SessionAppService as shown in the attached file and this is the error " GET <a class="postlink" href="http://localhost:22742/api/services/app/Session/GetCurrentLoginInformations">http://localhost:22742/api/services/app ... formations</a> 500 (Internal Server Error) "

  • User Avatar
    0
    aaron created
    Support Team

    Show the error in Logs.txt.

  • User Avatar
    0
    omarsultan created

    ERROR 2018-01-29 15:54:58,917 [4 ] Mvc.ExceptionHandling.AbpExceptionFilter - Error mapping types.

    Mapping types: Tenant -> TenantLoginInfoDto HYVE.Jigsaw.MultiTenancy.Tenant -> HYVE.Jigsaw.Sessions.Dto.TenantLoginInfoDto

    Type Map configuration: Tenant -> TenantLoginInfoDto HYVE.Jigsaw.MultiTenancy.Tenant -> HYVE.Jigsaw.Sessions.Dto.TenantLoginInfoDto

    Property: Edition AutoMapper.AutoMapperMappingException: Error mapping types.

    Mapping types: Tenant -> TenantLoginInfoDto HYVE.Jigsaw.MultiTenancy.Tenant -> HYVE.Jigsaw.Sessions.Dto.TenantLoginInfoDto

    Type Map configuration: Tenant -> TenantLoginInfoDto HYVE.Jigsaw.MultiTenancy.Tenant -> HYVE.Jigsaw.Sessions.Dto.TenantLoginInfoDto

    Property: Edition ---> AutoMapper.AutoMapperConfigurationException: Unmapped members were found. Review the types and members below. Add a custom mapping expression, ignore, add a custom resolver, or modify the source/destination type For no matching constructor, add a no-arg ctor, add optional arguments, or map all of the constructor parameters

    Edition -> EditionInfoDto (Destination member list) Abp.Application.Editions.Edition -> HYVE.Jigsaw.Sessions.Dto.EditionInfoDto (Destination member list)

    Unmapped properties: TrialDayCount MonthlyPrice AnnualPrice IsHighestEdition IsFree

    at AutoMapper.ConfigurationValidator.AssertConfigurationIsValid(IEnumerable`1 typeMaps) at lambda_method(Closure , Tenant , TenantLoginInfoDto , ResolutionContext ) --- End of inner exception stack trace --- at lambda_method(Closure , Tenant , TenantLoginInfoDto , ResolutionContext ) at lambda_method(Closure , Object , Object , ResolutionContext ) at AutoMapper.Mapper.AutoMapper.IMapper.Map[TDestination](Object source) at HYVE.Jigsaw.Sessions.SessionAppService.

  • User Avatar
    0
    aaron created
    Support Team

    I couldn't reproduce that error with:

    var tenant = new Tenant("", "")
    {
        Edition = new Edition()
    };
    
    var dto = ObjectMapper.Map<TenantLoginInfoDto>(tenant);
    

    But you can try changing this line in CustomDtoMapper.cs:

    - configuration.CreateMap<Edition, EditionInfoDto>().Include<SubscribableEdition, EditionInfoDto>();
    + configuration.CreateMap<Edition, EditionInfoDto>(MemberList.Source).Include<SubscribableEdition, EditionInfoDto>();
    
  • User Avatar
    0
    omarsultan created

    Thanks alot , it seems like the file called CustomDtoMapper is completely changed changing it to the new version made it work for me. thanks