Activities of "JorisIwell"

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

When selecting a menu item it gets highlighted, however on one of our pages there are elements which add query parameters to the url. When this happens, the highlight of the page disappears in the menu. Is there a way for lepton x to recognize that we are still on the same page and therefore highlight the page element in the menu?

I don't think we change the state anywhere. We use the standard ABP AuthGuard and OAuth flow so nothing custom on our end. Do you have any idea where we could find this problem in our code if we unbeknownst to us still add some customisation to this all?

  • ABP Framework version: v7.4.2
  • UI Type: Angular
  • Database System: EF Core SQL Server
  • Tiered (for MVC) or Auth Server Separated (for Angular): no
  • Exception message and full stack trace: 404 page not found, no relevant stack trace as the 404 makes sense
  • Steps to reproduce the issue:

We recently upgraded from v5.x to 7.4.2 and started using openIddict as a replacement for identityserver. Steps: Log out of our application Go directly to a url with query parameters, e.g. https://myurl.com/cubes/monitoring?group=installed User is prompted to login User logs in User gets redirected to url with the returnUrl that is present in the login-request User does not get redirected to https://myurl.com/cubes/monitoring?group=installed but instead to https://myurl.com/cubes/monitoring%3Fgroup%3Dinstalled which messes up our routing resulting in a 404.

In the network tab of the developer tools of the browser we can see that the url that is used as the returnUrl of the https://api.myurl.com/Account/Login/.... is double encoded (returnUrl%3D%252Fcubes%252Fmonitoring%253Fgroup%253Dinstalled). Our suspicion is that this should not be the case and causes the user to be directed to the encoded version of our returnUrl. FYI, we do not use a custom AuthGuard, instead we use the @abp/ng.core AuthGuard. We highly suspect this behaviour was not present in our application before upgrading ABP (and angular).

Nice, this fixes all my tests! Thank you so much :D

  • ABP Framework version: v7.0.1
  • UI Type: Angular
  • Database System: EF Core (SQL Server)
  • Tiered (for MVC) or Auth Server Separated (for Angular): no
  • Exception message and full stack trace:
Volo.Abp.AbpInitializationException: An error occurred during the initialize Volo.Abp.Modularity.OnApplicationInitializationModuleLifecycleContributor...

Volo.Abp.AbpInitializationException
An error occurred during the initialize Volo.Abp.Modularity.OnApplicationInitializationModuleLifecycleContributor phase of the module MyApplication.PortalTestBaseModule, MyApplication.TestBase, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null: BeginExecuteReader requires the command to have a transaction when the connection assigned to the command is in a pending local transaction.  The Transaction property of the command has not been initialized.. See the inner exception for details.
   at Volo.Abp.Modularity.ModuleManager.InitializeModules(ApplicationInitializationContext context)
   at Volo.Abp.AbpApplicationBase.InitializeModules()
   at Volo.Abp.AbpApplicationWithExternalServiceProvider.Initialize(IServiceProvider serviceProvider)
   at Volo.Abp.Testing.AbpIntegratedTest`1..ctor()
   at MyApplication.PortalTestBase`1..ctor()
   at MyApplication.PortalApplicationTestBase..ctor() in /Users/user/RiderProjects/Portal/aspnet-core/test/MyApplication.Application.Tests/PortalApplicationTestBase.cs:line 20
   at MyApplication.BackgroundTasks.EnecoAvailabilityWorkerTests..ctor() in /Users/user/RiderProjects/Portal/aspnet-core/test/MyApplication.Application.Tests/BackgroundTasks/EnecoAvailabilityWorkerTests.cs:line 29
   at System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean wrapExceptions)

System.InvalidOperationException
BeginExecuteReader requires the command to have a transaction when the connection assigned to the command is in a pending local transaction.  The Transaction property of the command has not been initialized.
   at Microsoft.Data.SqlClient.SqlCommand.<>c.<ExecuteDbDataReaderAsync>b__208_0(Task`1 result)
   at System.Threading.Tasks.ContinuationResultTaskFromResultTask`2.InnerInvoke()
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location ---
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.Tasks.Task.ExecuteWithThreadLocal(Task& currentTaskSlot, Thread threadPoolThread)
--- End of stack trace from previous location ---
   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)
   at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)
   at Microsoft.EntityFrameworkCore.Query.Internal.SingleQueryingEnumerable`1.AsyncEnumerator.InitializeReaderAsync(AsyncEnumerator enumerator, CancellationToken cancellationToken)
   at Microsoft.EntityFrameworkCore.SqlServer.Storage.Internal.SqlServerExecutionStrategy.ExecuteAsync[TState,TResult](TState state, Func`4 operation, Func`4 verifySucceeded, CancellationToken cancellationToken)
   at Microsoft.EntityFrameworkCore.Query.Internal.SingleQueryingEnumerable`1.AsyncEnumerator.MoveNextAsync()
   at Microsoft.EntityFrameworkCore.EntityFrameworkQueryableExtensions.ToListAsync[TSource](IQueryable`1 source, CancellationToken cancellationToken)
   at Microsoft.EntityFrameworkCore.EntityFrameworkQueryableExtensions.ToListAsync[TSource](IQueryable`1 source, CancellationToken cancellationToken)
   at Volo.Abp.SettingManagement.EntityFrameworkCore.EfCoreSettingRepository.GetListAsync(String providerName, String providerKey, CancellationToken cancellationToken)
   at Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo)
   at Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapterWithReturnValue`1.ProceedAsync()
   at Volo.Abp.Uow.UnitOfWorkInterceptor.InterceptAsync(IAbpMethodInvocation invocation)
   at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter`1.InterceptAsync[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo, Func`3 proceed)
   at Volo.Abp.SettingManagement.SettingManagementStore.SetCacheItemsAsync(String providerName, String providerKey, String currentName, SettingCacheItem currentCacheItem)
   at Volo.Abp.SettingManagement.SettingManagementStore.GetCacheItemAsync(String name, String providerName, String providerKey)
   at Volo.Abp.SettingManagement.SettingManagementStore.GetOrNullAsync(String name, String providerName, String providerKey)
   at Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo)
   at Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapterWithReturnValue`1.ProceedAsync()
   at Volo.Abp.Uow.UnitOfWorkInterceptor.InterceptAsync(IAbpMethodInvocation invocation)
   at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter`1.InterceptAsync[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo, Func`3 proceed)
   at Volo.Abp.Settings.TenantSettingValueProvider.GetOrNullAsync(SettingDefinition setting)
   at Volo.Abp.Settings.SettingProvider.GetOrNullValueFromProvidersAsync(IEnumerable`1 providers, SettingDefinition setting)
   at Volo.Abp.Settings.SettingProvider.GetOrNullAsync(String name)
   at Volo.Abp.Settings.SettingProviderExtensions.GetAsync[T](ISettingProvider settingProvider, String name, T defaultValue)
   at Volo.Abp.Identity.AbpIdentityOptionsManager.OverrideOptionsAsync(String name, IdentityOptions options)
   at Volo.Abp.Identity.IdentityDataSeeder.SeedAsync(String adminEmail, String adminPassword, Nullable`1 tenantId)
   at Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo)
   at Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapterWithReturnValue`1.ProceedAsync()
   at Volo.Abp.Uow.UnitOfWorkInterceptor.InterceptAsync(IAbpMethodInvocation invocation)
   at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter`1.InterceptAsync[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo, Func`3 proceed)
   at Volo.Abp.Data.DataSeeder.SeedAsync(DataSeedContext context)
   at Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous(IInvocation invocation, IInvocationProceedInfo proceedInfo)
   at Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapter.ProceedAsync()
   at Volo.Abp.Uow.UnitOfWorkInterceptor.InterceptAsync(IAbpMethodInvocation invocation)
   at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter`1.InterceptAsync(IInvocation invocation, IInvocationProceedInfo proceedInfo, Func`3 proceed)
   at MyApplication.PortalTestBaseModule.&lt;&gt;c__DisplayClass3_0.&lt;&lt;SeedTestData&gt;b__0>d.MoveNext() in /Users/user/RiderProjects/Portal/aspnet-core/test/MyApplication.TestBase/PortalTestBaseModule.cs:line 52
--- End of stack trace from previous location ---
   at Nito.AsyncEx.Synchronous.TaskExtensions.WaitAndUnwrapException(Task task)
   at Nito.AsyncEx.AsyncContext.&lt;&gt;c__DisplayClass15_0.&lt;Run&gt;b__0(Task t)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location ---
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.Tasks.Task.ExecuteWithThreadLocal(Task& currentTaskSlot, Thread threadPoolThread)
--- End of stack trace from previous location ---
   at Nito.AsyncEx.Synchronous.TaskExtensions.WaitAndUnwrapException(Task task)
   at Nito.AsyncEx.AsyncContext.Run(Func`1 action)
   at Volo.Abp.Threading.AsyncHelper.RunSync(Func`1 action)
   at MyApplication.PortalTestBaseModule.SeedTestData(ApplicationInitializationContext context) in /Users/user/RiderProjects/Portal/aspnet-core/test/MyApplication.TestBase/PortalTestBaseModule.cs:line 48
   at MyApplication.PortalTestBaseModule.OnApplicationInitialization(ApplicationInitializationContext context) in /Users/user/RiderProjects/Portal/aspnet-core/test/MyApplication.TestBase/PortalTestBaseModule.cs:line 43
   at Volo.Abp.Modularity.OnApplicationInitializationModuleLifecycleContributor.Initialize(ApplicationInitializationContext context, IAbpModule module)
   at Volo.Abp.Modularity.ModuleManager.InitializeModules(ApplicationInitializationContext context)
  • Steps to reproduce the issue:

Upgraded ABP from version 6.0.0 to 7.0.1 (before this, all tests ran successfully). After the upgrade and following the migration guide, I had to extended the connectionString to the DB by adding TrustServerCertificate=True to the variable to make my build succeed. Unfortunately most of my tests are now broken. All tests that use my DB give the above error. The error seems to occur at the moment I am seeding the database for the tests. This is done with the following code:

        private static void SeedTestData(ApplicationInitializationContext context)
        {
            AsyncHelper.RunSync(async () =>
            {
                using (var scope = context.ServiceProvider.CreateScope())
                {
                    await scope.ServiceProvider
                        .GetRequiredService&lt;IDataSeeder&gt;()
                        .SeedAsync();
                }
            });
        }

The error gets thrown on the using (var scope ...)-line. Google tells me that when this error occurs I should add the transaction to the SQL command which throws the error, but as you can see, this does not seem to be applicable to my situation.

I do not think this is an effect of the TrustServerCertificate=True, however I thought it was worth mentioning this information.

Any help would be appreciated!

Showing 1 to 5 of 5 entries
Made with ❤️ on ABP v9.1.0-preview. Updated on November 11, 2024, 11:11