Open Closed

Upgrade 8.3.4 Exception - System.Private.ServiceModel #8565


User avatar
0
jmalla.cp created

Steps to reproduce the issue:"

  • ABP Framework version: v8.3.4
  • UI Type: MVC
  • Database System: EF Core (PostgreSQL)
  • Tiered (for MVC) or Auth Server Separated (for Angular): yes
  • Exception message and full stack trace:
  • Steps to reproduce the issue:

Recendly I upgraded from 6.0 to 8.3.4 and I followed your migration guide, but when I try to run the aplication I encountering the following error:

2024-12-31 12:03:43.005 +01:00 [INF] [] [] Starting Cincaporc.WebApp.HttpApi.Host. 2024-12-31 12:03:50.304 +01:00 [FTL] [] [] Host terminated unexpectedly! System.IO.FileNotFoundException: Could not load file or assembly 'System.Private.ServiceModel, Version=4.1.2.4, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. El sistema no puede encontrar el archivo especificado. File name: 'System.Private.ServiceModel, Version=4.1.2.4, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' at System.ModuleHandle.ResolveType(QCallModule module, Int32 typeToken, IntPtr* typeInstArgs, Int32 typeInstCount, IntPtr* methodInstArgs, Int32 methodInstCount, ObjectHandleOnStack type) at System.ModuleHandle.ResolveTypeHandle(Int32 typeToken, RuntimeTypeHandle[] typeInstantiationContext, RuntimeTypeHandle[] methodInstantiationContext) at System.Reflection.RuntimeModule.ResolveType(Int32 metadataToken, Type[] genericTypeArguments, Type[] genericMethodArguments) at System.Reflection.CustomAttribute.FilterCustomAttributeRecord(MetadataToken caCtorToken, MetadataImport& scope, RuntimeModule decoratedModule, MetadataToken decoratedToken, RuntimeType attributeFilterType, Boolean mustBeInheritable, ListBuilder1& derivedAttributes, RuntimeType& attributeType, IRuntimeMethodInfo& ctorWithParameters, Boolean& isVarArg) at System.Reflection.CustomAttribute.IsCustomAttributeDefined(RuntimeModule decoratedModule, Int32 decoratedMetadataToken, RuntimeType attributeFilterType, Int32 attributeCtorToken, Boolean mustBeInheritable) at System.Reflection.CustomAttribute.IsDefined(RuntimeType type, RuntimeType caType, Boolean inherit) at Volo.Abp.DependencyInjection.ConventionalRegistrarBase.IsConventionalRegistrationDisabled(Type type) at Volo.Abp.DependencyInjection.DefaultConventionalRegistrar.AddType(IServiceCollection services, Type type) at Volo.Abp.DependencyInjection.ConventionalRegistrarBase.AddTypes(IServiceCollection services, Type[] types) at Volo.Abp.DependencyInjection.ConventionalRegistrarBase.AddAssembly(IServiceCollection services, Assembly assembly) at Microsoft.Extensions.DependencyInjection.ServiceCollectionConventionalRegistrationExtensions.AddAssembly(IServiceCollection services, Assembly assembly) at Volo.Abp.AbpApplicationBase.ConfigureServicesAsync() at Volo.Abp.AbpApplicationFactory.CreateAsync[TStartupModule](IServiceCollection services, Action1 optionsAction) at Microsoft.Extensions.DependencyInjection.ServiceCollectionApplicationExtensions.AddApplicationAsync[TStartupModule](IServiceCollection services, Action1 optionsAction) at Microsoft.Extensions.DependencyInjection.WebApplicationBuilderExtensions.AddApplicationAsync[TStartupModule](WebApplicationBuilder builder, Action1 optionsAction) at Cincaporc.WebApp.Program.Main(String[] args) in ***************\Cincaporc.WebApp\src\Cincaporc.WebApp.HttpApi.Host\Program.cs:line 55

Could you please assist me with this matter?

Thanks


30 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Can you share code or project to reproduce the exception?

    Thanks.

  • User Avatar
    0
    jmalla.cp created

    Of course, give me your github user

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    https://github.com/maliming

  • User Avatar
    0
    jmalla.cp created

    you Allready have access

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    Ok, I will check it. Thanks

  • User Avatar
    0
    jmalla.cp created

    You have to review the development-dotnet8 branch

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    Do I need any additional steps?

  • User Avatar
    0
    jmalla.cp created

    We use reddis and PostrgeSQL in local containers to test locally, but that's about it

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    Ok I will check it asap. : )

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Can you invite me again?

    Thanks.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    Thanks. I have joined.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    It works on my machine. You can try to run abp clean command then re-run the Cincaporc.WebApp.HttpApi.Host.

    [20:34:29 INF] Starting Cincaporc.WebApp.HttpApi.Host.
    [20:34:31 INF] Loaded ABP modules:
    [20:34:31 INF] - Cincaporc.WebApp.WebAppHttpApiHostModule
    [20:34:31 INF]   - Cincaporc.WebApp.WebAppHttpApiModule
    [20:34:31 INF]     - Cincaporc.WebApp.WebAppApplicationContractsModule
    [20:34:31 INF]       - Cincaporc.WebApp.WebAppDomainSharedModule
    [20:34:31 INF]         - Volo.Abp.AuditLogging.AbpAuditLoggingDomainSharedModule
    [20:34:31 INF]           - Volo.Abp.Validation.AbpValidationModule
    [20:34:31 INF]             - Volo.Abp.Validation.AbpValidationAbstractionsModule
    [20:34:31 INF]             - Volo.Abp.Localization.AbpLocalizationModule
    [20:34:31 INF]               - Volo.Abp.VirtualFileSystem.AbpVirtualFileSystemModule
    [20:34:31 INF]               - Volo.Abp.Settings.AbpSettingsModule
    [20:34:31 INF]                 - Volo.Abp.Localization.AbpLocalizationAbstractionsModule
    [20:34:31 INF]                 - Volo.Abp.Security.AbpSecurityModule
    [20:34:31 INF]                 - Volo.Abp.Data.AbpDataModule
    [20:34:31 INF]                   - Volo.Abp.ObjectExtending.AbpObjectExtendingModule
    [20:34:31 INF]                   - Volo.Abp.Uow.AbpUnitOfWorkModule
    [20:34:31 INF]                   - Volo.Abp.EventBus.Abstractions.AbpEventBusAbstractionsModule
    [20:34:31 INF]               - Volo.Abp.Threading.AbpThreadingModule
    [20:34:31 INF]         - Volo.Abp.BackgroundJobs.AbpBackgroundJobsDomainSharedModule
    [20:34:31 INF]         - Volo.Abp.FeatureManagement.AbpFeatureManagementDomainSharedModule
    [20:34:31 INF]           - Volo.Abp.Json.SystemTextJson.AbpJsonSystemTextJsonModule
    [20:34:31 INF]             - Volo.Abp.Json.AbpJsonAbstractionsModule
    [20:34:31 INF]             - Volo.Abp.Timing.AbpTimingModule
    [20:34:31 INF]         - Volo.Abp.Identity.AbpIdentityProDomainSharedModule
    [20:34:31 INF]           - Volo.Abp.Identity.AbpIdentityDomainSharedModule
    [20:34:31 INF]             - Volo.Abp.Users.AbpUsersDomainSharedModule
    [20:34:31 INF]             - Volo.Abp.Features.AbpFeaturesModule
    [20:34:31 INF]               - Volo.Abp.MultiTenancy.AbpMultiTenancyModule
    [20:34:31 INF]                 - Volo.Abp.MultiTenancy.AbpMultiTenancyAbstractionsModule
    [20:34:31 INF]               - Volo.Abp.Authorization.AbpAuthorizationAbstractionsModule
    [20:34:31 INF]           - Volo.Abp.Ldap.AbpLdapAbstractionsModule
    [20:34:31 INF]         - Volo.Abp.OpenIddict.AbpOpenIddictDomainSharedModule
    [20:34:31 INF]         - Volo.Abp.PermissionManagement.AbpPermissionManagementDomainSharedModule
    //...
    [20:34:31 INF]       - Volo.Abp.BackgroundWorkers.Hangfire.AbpBackgroundWorkersHangfireModule
    [20:34:31 INF]         - Volo.Abp.Hangfire.AbpHangfireModule
    [20:34:31 INF]   - Cincaporc.WebApp.EntityFrameworkCore.WebAppEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.Identity.EntityFrameworkCore.AbpIdentityProEntityFrameworkCoreModule
    [20:34:31 INF]       - Volo.Abp.Identity.EntityFrameworkCore.AbpIdentityEntityFrameworkCoreModule
    [20:34:31 INF]         - Volo.Abp.Users.EntityFrameworkCore.AbpUsersEntityFrameworkCoreModule
    [20:34:31 INF]           - Volo.Abp.EntityFrameworkCore.AbpEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.OpenIddict.EntityFrameworkCore.AbpOpenIddictEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.PermissionManagement.EntityFrameworkCore.AbpPermissionManagementEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.SettingManagement.EntityFrameworkCore.AbpSettingManagementEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.EntityFrameworkCore.PostgreSql.AbpEntityFrameworkCorePostgreSqlModule
    [20:34:31 INF]     - Volo.Abp.BackgroundJobs.EntityFrameworkCore.AbpBackgroundJobsEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.AuditLogging.EntityFrameworkCore.AbpAuditLoggingEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.FeatureManagement.EntityFrameworkCore.AbpFeatureManagementEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.LanguageManagement.EntityFrameworkCore.LanguageManagementEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Saas.EntityFrameworkCore.SaasEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.TextTemplateManagement.EntityFrameworkCore.TextTemplateManagementEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.Gdpr.AbpGdprEntityFrameworkCoreModule
    [20:34:31 INF]     - Volo.Abp.BlobStoring.Database.EntityFrameworkCore.BlobStoringDatabaseEntityFrameworkCoreModule
    [20:34:31 INF]   - Volo.Abp.Swashbuckle.AbpSwashbuckleModule
    [20:34:31 INF]   - Volo.Abp.AspNetCore.Serilog.AbpAspNetCoreSerilogModule
    [20:34:31 INF]   - Volo.Abp.BackgroundJobs.Hangfire.AbpBackgroundJobsHangfireModule
    [20:34:31 INF] Start installing Hangfire SQL objects...
    [20:34:31 INF] Hangfire SQL objects installed.
    [20:34:31 INF] Starting Hangfire Server using job storage: 'PostgreSQL Server: Host: localhost, DB: ExtranetDev, Schema: hangfire'
    [20:34:31 INF] Using the following options for PostgreSQL job storage:
    [20:34:31 INF] Server malim:92837:6092d144 successfully announced in 65.8427 ms
    [20:34:31 DBG] Execution loop ServerHeartbeatProcess:331fb301 has started in 0.4855 ms
    [20:34:31 INF] Server malim:92837:6092d144 is starting the registered dispatchers: ServerWatchdog, ServerJobCancellationWatcher, ExpirationManager, CountersAggregator, Worker, DelayedJobScheduler, RecurringJobScheduler...
    [20:34:32 INF] ErpFake service has been initialized
    [20:34:32 INF] ErpService has been initialized
    [20:34:32 INF] User profile is available. Using '/Users/maliming/.aspnet/DataProtection-Keys' as key repository; keys will not be encrypted at rest.
    [20:34:32 DBG] Waiting to acquire the distributed lock for saving external localizations...
    [20:34:32 INF] Saving external localizations...
    [20:34:34 INF] Initialized all ABP modules.
    [20:34:34 INF] Initializing UI Database
    [20:34:34 INF] Saving healthchecks configuration to database
    [20:34:34 INF] Now listening on: https://localhost:44368
    [20:34:34 DBG] Executing HealthCheck collector HostedService.
    [20:34:34 INF] Start processing HTTP request GET https://localhost:44368/health-status
    [20:34:34 INF] Sending HTTP request GET https://localhost:44368/health-status
    [20:34:34 INF] Application started. Press Ctrl+C to shut down.
    [20:34:34 INF] Hosting environment: Development
    [20:34:34 INF] Content root path: /Users/maliming/Github/Cincaporc.WebApp/src/Cincaporc.WebApp.HttpApi.Host
    [20:34:34 INF] Request starting HTP/1.1 GET https://localhost:44368/health-status - null null
    [20:34:41 INF] Request finished HTTP/2 GET https://localhost:44368/favicon.ico - 404 0 null 3.4824ms
    [20:34:41 INF] Request reached the end of the middleware pipeline without being handled by application code. Request path: GET https://localhost:44368/favicon.ico, Response status code: 404
    [20:34:42 INF] Completed to save external localizations.
    [20:34:44 INF] Request starting HTTP/2 GET https://localhost:44368/ - null null
    [20:34:44 INF] Executing endpoint 'Cincaporc.WebApp.Controllers.HomeController.Index (Cincaporc.WebApp.HttpApi.Host)'
    [20:34:44 INF] Route matched with {action = "Index", controller = "Home", area = "", page = ""}. Executing controller action with signature Microsoft.AspNetCore.Mvc.ActionResult Index() on controller Cincaporc.WebApp.Controllers.HomeController (Cincaporc.WebApp.HttpApi.Host).
    [20:34:44 INF] Executing RedirectResult, redirecting to /swagger.
    [20:34:44 INF] Executed action Cincaporc.WebApp.Controllers.HomeController.Index (Cincaporc.WebApp.HttpApi.Host) in 18.1288ms
    [20:34:44 INF] Executed endpoint 'Cincaporc.WebApp.Controllers.HomeController.Index (Cincaporc.WebApp.HttpApi.Host)'
    [20:34:44 INF] Request finished HTTP/2 GET https://localhost:44368/ - 302 0 null 82.5294ms
    
  • User Avatar
    0
    jmalla.cp created

    After run "abp clean" in all projects and re-run, the error persist

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Can you try to add <PackageReference Include="System.Private.ServiceModel" Version="4.10.2" /> to your Cincaporc.WebApp.HttpApi.Host?

    I think this only happened on your machine.

  • User Avatar
    0
    jmalla.cp created

    Solved thanks. But now I have this other error in web.public project.

    2024-12-31 14:38:24.758 +01:00 [ERR] [] [] An unhandled exception has occurred while executing the request. Autofac.Core.Registration.ComponentNotRegisteredException: The requested service 'Volo.Abp.Studio.Client.AspNetCore.AbpStudioMiddleware' has not been registered. To avoid this exception, either register a component to provide the service, check for service registration using IsRegistered(), or use the ResolveOptional() method to resolve an optional dependency.

    See https://autofac.rtfd.io/help/service-not-registered for more info. at Autofac.ResolutionExtensions.ResolveService(IComponentContext context, Service service, IEnumerable1 parameters) at Autofac.ResolutionExtensions.Resolve(IComponentContext context, Type serviceType, IEnumerable1 parameters) at Autofac.ResolutionExtensions.Resolve(IComponentContext context, Type serviceType) at Autofac.Extensions.DependencyInjection.AutofacServiceProvider.GetRequiredService(Type serviceType) at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType) at Microsoft.AspNetCore.Http.MiddlewareFactory.Create(Type middlewareType) at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.<>c__DisplayClass2_0.<<CreateMiddleware>b__0>d.MoveNext() --- End of stack trace from previous location --- at Microsoft.AspNetCore.Localization.RequestLocalizationMiddleware.Invoke(HttpContext context) at Microsoft.AspNetCore.RequestLocalization.AbpRequestLocalizationMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.<>c__DisplayClass2_0.<<CreateMiddleware>b__0>d.MoveNext() --- End of stack trace from previous location --- at Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddlewareImpl.Invoke(HttpContext context) 2024-12-31 14:38:24.773 +01:00 [INF] [] [] Request finished HTTP/2 GET https://localhost:44311/favicon.ico - 500 null text/plain; charset=utf-8 24.9398ms

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    You can try to remove the app.UseAbpStudioLink(); or depend on the typeof(AbpStudioClientAspNetCoreModule)

  • User Avatar
    0
    jmalla.cp created

    Which package I need to add typeof(AbpStudioClientAspNetCoreModule)?

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    WebAppWebPublicModule

  • User Avatar
    0
    jmalla.cp created

    Thanks maliming.

    Now I can put the user and password but then the system throw this error:

    2025-01-02 12:29:44.583 +01:00 [ERR] [] [] An unhandled exception has occurred while executing the request.
    System.ArgumentException: An item with the same key has already been added. Key: [ApplicationMenuItem] Name = SaasHost.Tenants
       at System.Collections.Generic.Dictionary`2.TryInsert(TKey key, TValue value, InsertionBehavior behavior)
       at System.Collections.Generic.Dictionary`2.Add(TKey key, TValue value)
       at Volo.Abp.SimpleStateChecking.SimpleStateCheckerResult`1..ctor(IEnumerable`1 states, Boolean initValue)
       at Volo.Abp.SimpleStateChecking.SimpleStateCheckerManager`1.IsEnabledAsync(TState[] states)
       at Volo.Abp.UI.Navigation.MenuManager.CheckPermissionsAsync(IServiceProvider serviceProvider, IHasMenuItems menuWithItems)
       at Volo.Abp.UI.Navigation.MenuManager.GetInternalAsync(String name)
       at Volo.Abp.UI.Navigation.MenuManager.GetAsync(String[] menuNames)
       at HvCiKp40TrGNI1EEHck.uspIgh4lHyahrts3I8u.ExecuteAsync()
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderPageCoreAsync(IRazorPage page, ViewContext context)
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderPageAsync(IRazorPage page, ViewContext context, Boolean invokeViewStarts)
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderAsync(ViewContext context)
       at Microsoft.AspNetCore.Mvc.ViewFeatures.HtmlHelper.RenderPartialCoreAsync(String partialViewName, Object model, ViewDataDictionary viewData, TextWriter writer)
       at Microsoft.AspNetCore.Mvc.ViewFeatures.HtmlHelper.PartialAsync(String partialViewName, Object model, ViewDataDictionary viewData)
       at kQGUV7miWwBKM2Susvl.yj2yF7mDj6ng9IGkvXx.&lt;&gt;c__DisplayClass21_0.Oi3NtHwOckd7VEFrMB6.MoveNext()
    --- End of stack trace from previous location ---
       at Microsoft.AspNetCore.Razor.Runtime.TagHelpers.TagHelperExecutionContext.SetOutputContentAsync()
       at kQGUV7miWwBKM2Susvl.yj2yF7mDj6ng9IGkvXx.ExecuteAsync()
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderPageCoreAsync(IRazorPage page, ViewContext context)
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderPageAsync(IRazorPage page, ViewContext context, Boolean invokeViewStarts)
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderLayoutAsync(ViewContext context, ViewBufferTextWriter bodyWriter)
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderAsync(ViewContext context)
       at Microsoft.AspNetCore.Mvc.ViewFeatures.ViewExecutor.ExecuteAsync(ViewContext viewContext, String contentType, Nullable`1 statusCode)
       at Microsoft.AspNetCore.Mvc.ViewFeatures.ViewExecutor.ExecuteAsync(ViewContext viewContext, String contentType, Nullable`1 statusCode)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.&lt;InvokeNextResultFilterAsync&gt;g__Awaited|30_0[TFilter,TFilterAsync](ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResultExecutedContextSealed context)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.ResultNext[TFilter,TFilterAsync](State& next, Scope& scope, Object& state, Boolean& isCompleted)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.InvokeResultFilters()
    --- End of stack trace from previous location ---
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.&lt;InvokeNextResourceFilter&gt;g__Awaited|25_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.InvokeFilterPipelineAsync()
    --- End of stack trace from previous location ---
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.&lt;InvokeAsync&gt;g__Logged|17_1(ResourceInvoker invoker)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.&lt;InvokeAsync&gt;g__Logged|17_1(ResourceInvoker invoker)
       at Microsoft.AspNetCore.Routing.EndpointMiddleware.&lt;Invoke&gt;g__AwaitRequestTask|7_0(Endpoint endpoint, Task requestTask, ILogger logger)
       at Volo.Abp.AspNetCore.Serilog.AbpSerilogMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
       at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.&lt;&gt;c__DisplayClass2_0.&lt;&lt;CreateMiddleware&gt;b__0>d.MoveNext()
    --- End of stack trace from previous location ---
       at Swashbuckle.AspNetCore.SwaggerUI.SwaggerUIMiddleware.Invoke(HttpContext httpContext)
       at Swashbuckle.AspNetCore.Swagger.SwaggerMiddleware.Invoke(HttpContext httpContext, ISwaggerProvider swaggerProvider)
       at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)
       at Volo.Abp.Studio.Client.AspNetCore.AbpStudioMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
       at Volo.Abp.Studio.Client.AspNetCore.AbpStudioMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
       at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.&lt;&gt;c__DisplayClass2_0.&lt;&lt;CreateMiddleware&gt;b__0>d.MoveNext()
    --- End of stack trace from previous location ---
       at Cincaporc.WebApp.Middleware.Logging.SessionLoggingMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) in C:\Users\jmalla.CINCA\source\repos\Cincaporc.WebApp\src\Cincaporc.WebApp.Middleware\Logging\SessionLoggingMiddleware.cs:line 23
       at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.&lt;&gt;c__DisplayClass2_0.&lt;&lt;CreateMiddleware&gt;b__0>d.MoveNext()
    --- End of stack trace from previous location ---
       at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
       at Volo.Abp.AspNetCore.Security.AbpSecurityHeadersMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
       at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.&lt;&gt;c__DisplayClass2_0.&lt;&lt;CreateMiddleware&gt;b__0>d.MoveNext()
    --- End of stack trace from previous location ---
       at Microsoft.AspNetCore.Localization.RequestLocalizationMiddleware.Invoke(HttpContext context)
       at Microsoft.AspNetCore.RequestLocalization.AbpRequestLocalizationMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
       at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.&lt;&gt;c__DisplayClass2_0.&lt;&lt;CreateMiddleware&gt;b__0>d.MoveNext()
    --- End of stack trace from previous location ---
       at Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddlewareImpl.Invoke(HttpContext context)
    
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Maybe you should get saas menu from administration instead of AddItem

  • User Avatar
    0
    jmalla.cp created

    If I comment that, I get the same error

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    How can I reproduce this exception with your project?

    What is the branch and steps.

    Thanks,.

  • User Avatar
    0
    jmalla.cp created

    The banch is development-dotnet8 and the only step is to try to do login on web project.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    I can't reproduce


    Please use 7.5.1 as package of Microsoft.IdentityModel version.

  • User Avatar
    0
    jmalla.cp created

    I have written down this references but I have the same error

    Exception has occurred: CLR/System.ArgumentException
    Exception thrown: 'System.ArgumentException' in System.Private.CoreLib.dll: 'An item with the same key has already been added. Key: [ApplicationMenuItem] Name = SaasHost.Tenants'
       at System.ThrowHelper.ThrowAddingDuplicateWithKeyArgumentException[T](T key)
       at System.Collections.Generic.Dictionary`2.TryInsert(TKey key, TValue value, InsertionBehavior behavior)
       at System.Collections.Generic.Dictionary`2.Add(TKey key, TValue value)
       at Volo.Abp.SimpleStateChecking.SimpleStateCheckerResult`1..ctor(IEnumerable`1 states, Boolean initValue)
       at Volo.Abp.SimpleStateChecking.SimpleStateCheckerManager`1.&lt;IsEnabledAsync&gt;d__8.MoveNext()
       at Volo.Abp.UI.Navigation.MenuManager.&lt;CheckPermissionsAsync&gt;d__15.MoveNext()
       at Volo.Abp.UI.Navigation.MenuManager.&lt;GetInternalAsync&gt;d__14.MoveNext()
       at Volo.Abp.UI.Navigation.MenuManager.&lt;GetAsync&gt;d__12.MoveNext()
       at HvCiKp40TrGNI1EEHck.uspIgh4lHyahrts3I8u.&lt;ExecuteAsync&gt;d__0.MoveNext()
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.&lt;RenderPageCoreAsync&gt;d__20.MoveNext()
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.&lt;RenderPageAsync&gt;d__19.MoveNext()
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.&lt;RenderAsync&gt;d__18.MoveNext()
       at Microsoft.AspNetCore.Mvc.ViewFeatures.HtmlHelper.&lt;RenderPartialCoreAsync&gt;d__60.MoveNext()
       at Microsoft.AspNetCore.Mvc.ViewFeatures.HtmlHelper.&lt;PartialAsync&gt;d__57.MoveNext()
       at kQGUV7miWwBKM2Susvl.yj2yF7mDj6ng9IGkvXx.&lt;&gt;c__DisplayClass21_0.Oi3NtHwOckd7VEFrMB6.MoveNext()
       at Microsoft.AspNetCore.Razor.Runtime.TagHelpers.TagHelperExecutionContext.&lt;SetOutputContentAsync&gt;d__32.MoveNext()
       at kQGUV7miWwBKM2Susvl.yj2yF7mDj6ng9IGkvXx.&lt;ExecuteAsync&gt;d__21.MoveNext()
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.&lt;RenderPageCoreAsync&gt;d__20.MoveNext()
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.&lt;RenderPageAsync&gt;d__19.MoveNext()
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.&lt;RenderLayoutAsync&gt;d__22.MoveNext()
       at Microsoft.AspNetCore.Mvc.Razor.RazorView.&lt;RenderAsync&gt;d__18.MoveNext()
       at Microsoft.AspNetCore.Mvc.ViewFeatures.ViewExecutor.&lt;ExecuteAsync&gt;d__22.MoveNext()
       at Microsoft.AspNetCore.Mvc.ViewFeatures.ViewExecutor.&lt;ExecuteAsync&gt;d__22.MoveNext()
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.&lt;&lt;InvokeNextResultFilterAsync&gt;g__Awaited|30_0>d`2.MoveNext()
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResultExecutedContextSealed context)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.ResultNext[TFilter,TFilterAsync](State& next, Scope& scope, Object& state, Boolean& isCompleted)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.InvokeResultFilters()
    --- End of stack trace from previous location ---
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<<InvokeNextResourceFilter>g__Awaited|25_0>d.MoveNext()
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.InvokeFilterPipelineAsync()
    --- End of stack trace from previous location ---
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<<InvokeAsync>g__Logged|17_1>d.MoveNext()
       at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<<InvokeAsync>g__Logged|17_1>d.MoveNext()
       at Microsoft.AspNetCore.Routing.EndpointMiddleware.<<Invoke>g__AwaitRequestTask|7_0>d.MoveNext()
       at Volo.Abp.AspNetCore.Serilog.AbpSerilogMiddleware.<InvokeAsync>d__6.MoveNext()
       at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.<>c__DisplayClass2_0.<<CreateMiddleware>b__0>d.MoveNext()
       at Swashbuckle.AspNetCore.SwaggerUI.SwaggerUIMiddleware.<Invoke>d__5.MoveNext()
       at Swashbuckle.AspNetCore.Swagger.SwaggerMiddleware.<Invoke>d__4.MoveNext()
       at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.<Invoke>d__11.MoveNext()
       at Volo.Abp.Studio.Client.AspNetCore.AbpStudioMiddleware.<InvokeAsync>d__0.MoveNext()
       at Volo.Abp.Studio.Client.AspNetCore.AbpStudioMiddleware.<InvokeAsync>d__0.MoveNext()
       at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.<>c__DisplayClass2_0.<<CreateMiddleware>b__0>d.MoveNext()
       at Cincaporc.WebApp.Middleware.Logging.SessionLoggingMiddleware.<InvokeAsync>d__2.MoveNext() in C:\Users\jmalla.CINCA\source\repos\Cincaporc.WebApp\src\Cincaporc.WebApp.Middleware\Logging\SessionLoggingMiddleware.cs:line 23
    
Made with ❤️ on ABP v9.1.0-preview. Updated on January 02, 2025, 07:06