This error has started to occur after a 5.0 upgrade.
I get the following exception when I try to log in to the development version of my application.
AbpException: Could not find the bundle file '/libs/bootstrap/js/bootstrap.enable.tooltips.everywhere.js' for the bundle 'Lepton.Global'! Volo.Abp.AspNetCore.Mvc.UI.Bundling.TagHelpers.AbpTagHelperResourceService.ProcessAsync(ViewContext viewContext, TagHelper tagHelper, TagHelperContext context, TagHelperOutput output, List<BundleTagHelperItem> bundleItems, string bundleName)
The url that is shown is https://localhost:44322/Account/Login?... where 44322 is the ip address of the HttpAPI.Host application, so it appears this issue is occurring in the HttpAPi.Host application. When updating the projects I did get error messages from NPM. When I compare a fresh 5.0 project to my project there appear to be a lot of differences in the wwwroot>libs folder of the HttpAPI.Host project. In my project bootstrap appears to still be version 4...
How do I fix this? I've tried various things with NPM and Yarn, but to be honest, don't know what I'm doing. One option is to copy all the lib files from the fresh 5.0 project to my project, but this doesn't seem to be the correct way to go about this?
Happy to share the project.
AbpException: Could not find the bundle file '/libs/bootstrap/js/bootstrap.enable.tooltips.everywhere.js' for the bundle 'Lepton.Global'! Volo.Abp.AspNetCore.Mvc.UI.Bundling.TagHelpers.AbpTagHelperResourceService.ProcessAsync(ViewContext viewContext, TagHelper tagHelper, TagHelperContext context, TagHelperOutput output, List<BundleTagHelperItem> bundleItems, string bundleName)
Volo.Abp.AspNetCore.Mvc.UI.Bundling.TagHelpers.AbpTagHelperResourceService.ProcessAsync(ViewContext viewContext, TagHelper tagHelper, TagHelperContext context, TagHelperOutput output, List<BundleTagHelperItem> bundleItems, string bundleName) Volo.Abp.AspNetCore.Mvc.UI.Bundling.TagHelpers.AbpBundleTagHelperService<TTagHelper, TService>.ProcessAsync(TagHelperContext context, TagHelperOutput output) Microsoft.AspNetCore.Razor.Runtime.TagHelpers.TagHelperRunner.<RunAsync>g__Awaited|0_0(Task task, TagHelperExecutionContext executionContext, int i, int count) S9GI3Kab0OYekHAdVtF.j9qEckezhcegY5LyPKI+<>c__DisplayClass32_0+ST4rfZQbFxr7MKR0CwZ.MoveNext() Microsoft.AspNetCore.Razor.Runtime.TagHelpers.TagHelperExecutionContext.SetOutputContentAsync() S9GI3Kab0OYekHAdVtF.j9qEckezhcegY5LyPKI.ExecuteAsync() Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderPageCoreAsync(IRazorPage page, ViewContext context) Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderPageAsync(IRazorPage page, ViewContext context, bool invokeViewStarts) Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderLayoutAsync(ViewContext context, ViewBufferTextWriter bodyWriter) Microsoft.AspNetCore.Mvc.Razor.RazorView.RenderAsync(ViewContext context) Microsoft.AspNetCore.Mvc.ViewFeatures.ViewExecutor.ExecuteAsync(ViewContext viewContext, string contentType, Nullable<int> statusCode) Microsoft.AspNetCore.Mvc.ViewFeatures.ViewExecutor.ExecuteAsync(ViewContext viewContext, string contentType, Nullable<int> statusCode) Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextResultFilterAsync>g__Awaited|30_0<TFilter, TFilterAsync>(ResourceInvoker invoker, Task lastTask, State next, Scope scope, object state, bool isCompleted) Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResultExecutedContextSealed context) Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.ResultNext<TFilter, TFilterAsync>(ref State next, ref Scope scope, ref object state, ref bool isCompleted) Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeResultFilters>g__Awaited|28_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, object state, bool isCompleted) Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextResourceFilter>g__Awaited|25_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, object state, bool isCompleted) Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context) Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(ref State next, ref Scope scope, ref object state, ref bool isCompleted) Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeFilterPipelineAsync>g__Awaited|20_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, object state, bool isCompleted) Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Logged|17_1(ResourceInvoker invoker) Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Logged|17_1(ResourceInvoker invoker) Microsoft.AspNetCore.Routing.EndpointMiddleware.<Invoke>g__AwaitRequestTask|6_0(Endpoint endpoint, Task requestTask, ILogger logger) Volo.Abp.AspNetCore.Serilog.AbpSerilogMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) Microsoft.AspNetCore.Builder.UseMiddlewareExtensions+<>c__DisplayClass6_1+<<UseMiddlewareInterface>b__1>d.MoveNext() Volo.Abp.AspNetCore.Auditing.AbpAuditingMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) Volo.Abp.AspNetCore.Auditing.AbpAuditingMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) Microsoft.AspNetCore.Builder.UseMiddlewareExtensions+<>c__DisplayClass6_1+<<UseMiddlewareInterface>b__1>d.MoveNext() Swashbuckle.AspNetCore.SwaggerUI.SwaggerUIMiddleware.Invoke(HttpContext httpContext) Swashbuckle.AspNetCore.Swagger.SwaggerMiddleware.Invoke(HttpContext httpContext, ISwaggerProvider swaggerProvider) Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context) IdentityServer4.Hosting.IdentityServerMiddleware.Invoke(HttpContext context, IEndpointRouter router, IUserSession session, IEventService events, IBackChannelLogoutService backChannelLogoutService) IdentityServer4.Hosting.MutualTlsEndpointMiddleware.Invoke(HttpContext context, IAuthenticationSchemeProvider schemes) Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context) IdentityServer4.Hosting.BaseUrlMiddleware.Invoke(HttpContext context) Volo.Abp.AspNetCore.Uow.AbpUnitOfWorkMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) Microsoft.AspNetCore.Builder.UseMiddlewareExtensions+<>c__DisplayClass6_1+<<UseMiddlewareInterface>b__1>d.MoveNext() Volo.Abp.AspNetCore.ExceptionHandling.AbpExceptionHandlingMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) Volo.Abp.AspNetCore.ExceptionHandling.AbpExceptionHandlingMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) Microsoft.AspNetCore.Builder.UseMiddlewareExtensions+<>c__DisplayClass6_1+<<UseMiddlewareInterface>b__1>d.MoveNext() Volo.Abp.AspNetCore.MultiTenancy.MultiTenancyMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) Microsoft.AspNetCore.Builder.UseMiddlewareExtensions+<>c__DisplayClass6_1+<<UseMiddlewareInterface>b__1>d.MoveNext() Microsoft.AspNetCore.Builder.ApplicationBuilderAbpJwtTokenMiddlewareExtension+<>c__DisplayClass0_0+<<UseJwtTokenMiddleware>b__0>d.MoveNext() Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context) Microsoft.AspNetCore.Localization.RequestLocalizationMiddleware.Invoke(HttpContext context) Microsoft.AspNetCore.RequestLocalization.AbpRequestLocalizationMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) Microsoft.AspNetCore.Builder.UseMiddlewareExtensions+<>c__DisplayClass6_1+<<UseMiddlewareInterface>b__1>d.MoveNext() Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddleware.Invoke(HttpContext context)
Thank you. I don't understand why, but this fixed the issue.
I've sent you a link.
I had commented out the code in the SolutionMenuContributor , GetFirstProjectAsync method.
Did you uncomment it before you tested. SolutionMenuContributor still doesn't work for me, although the test class does. This is the issue.
I've sent you a project. The class that has the issue is SolutionMenuContributor in the Blazor project. The test class/method is ProjectApplicationTests class GetListAsyncForSltn method in the Datansa.App.Application.Tests project.
Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples, to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, please use the search on the homepage.
If you're creating a bug/problem report, please include following:
I have this method in a MenuContributor class in my Blazor project: <br>
private async Task<Guid> GetFirstProjectAsync(Guid sltnId)
{
Console.WriteLine($"SLTNID = {sltnId} ");
var projectFilter = new GetProjectsInput
{
SltnId = new Guid("00000000-14ba-4f0f-8417-c2f312768aea")
};
projectFilter.MaxResultCount = PageSize;
projectFilter.SkipCount = (CurrentPage - 1) * PageSize;
projectFilter.Sorting = CurrentSorting;
var result = await _projectsAppService.GetListAsync(projectFilter); <--- THIS IS WHERE THE EXCEPTION HAPPENS
if (result.Items.FirstOrDefault() != null)
{
return result.Items.FirstOrDefault().Id;
}
else
{
Guid defaultGuid = default;
return defaultGuid;
}
}
>> mono_wasm_start_single_stepping 2 crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100] Unhandled exception rendering component: Instances cannot be resolved and nested lifetimes cannot be created from this LifetimeScope as it (or one of its parent scopes) has already been disposed. System.ObjectDisposedException: Instances cannot be resolved and nested lifetimes cannot be created from this LifetimeScope as it (or one of its parent scopes) has already been disposed. at Autofac.Core.Lifetime.LifetimeScope.BeginLifetimeScope(Object tag) at Autofac.Core.Lifetime.LifetimeScope.BeginLifetimeScope() at Autofac.Extensions.DependencyInjection.AutofacServiceScopeFactory.CreateScope() at Volo.Abp.Validation.ObjectValidator.GetErrors(Object validatingObject, String name, Boolean allowNull) at Volo.Abp.Validation.MethodInvocationValidator.AddMethodParameterValidationErrors(IAbpValidationResult context, ParameterInfo parameterInfo, Object parameterValue) at Volo.Abp.Validation.MethodInvocationValidator.AddMethodParameterValidationErrors(MethodInvocationValidationContext context) at Volo.Abp.Validation.MethodInvocationValidator.Validate(MethodInvocationValidationContext context) at Volo.Abp.Validation.ValidationInterceptor.Validate(IAbpMethodInvocation invocation) at Volo.Abp.Validation.ValidationInterceptor.InterceptAsync(IAbpMethodInvocation invocation) at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter`1.<InterceptAsync>d__3`1[[Volo.Abp.Validation.ValidationInterceptor, Volo.Abp.Validation, Version=4.3.2.0, Culture=neutral, PublicKeyToken=null],[Volo.Abp.Application.Dtos.PagedResultDto`1[[Datansa.App.Solution.ProjectDto, Datansa.App.Application.Contracts, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]], Volo.Abp.Ddd.Application.Contracts, Version=4.3.2.0, Culture=neutral, PublicKeyToken=null]].MoveNext() at Datansa.App.Blazor.Navigation.SolutionMenuContributor.GetFirstProjectAsync(Guid sltnId) in C:\Users\agilm\Documents\Repos\Datansa.App\src\Datansa.App.Blazor\Navigation\SolutionMenuContributor.cs:line 109 at Datansa.App.Blazor.Navigation.SolutionMenuContributor.ConfigureMainMenuAsync(MenuConfigurationContext context) in C:\Users\agilm\Documents\Repos\Datansa.App\src\Datansa.App.Blazor\Navigation\SolutionMenuContributor.cs:line 63 at Datansa.App.Blazor.Navigation.SolutionMenuContributor.ConfigureMenuAsync(MenuConfigurationContext context) in C:\Users\agilm\Documents\Repos\Datansa.App\src\Datansa.App.Blazor\Navigation\SolutionMenuContributor.cs:line 49 at Volo.Abp.UI.Navigation.MenuManager.GetAsync(String name) at Volo.Abp.AspNetCore.Components.Web.LeptonTheme.Components.ApplicationLayout.Navigation.MainMenuProvider.GetMenuAsync() at Volo.Abp.AspNetCore.Components.Web.LeptonTheme.Components.ApplicationLayout.MainHeader.MainHeader.OnInitializedAsync() at Microsoft.AspNetCore.Components.ComponentBase.RunInitAndSetParametersAsync() at Microsoft.AspNetCore.Components.RenderTree.Renderer.GetErrorHandledTask(Task taskToHandle)
However, I replicated the logic in a test method in my Application.Tests test project and the logic worked fine without exception.
Is it something to do with GUID?
This the class its trying to return:
public class ProjectDto : FullAuditedEntityDto<Guid> { public string Name { get; set; } public string Description { get; set; } public int DisplayOrder { get; set; } public List<ProjectConformDto> ProjectConforms { get; set; } }
Happy to provide the project if required.
Hi.
Yes that worked. So the issue was, in the Test class there was no ambient UOW, as there would be in an ApplicationService class.
Thanks for your help.
I've sent the project by email.
By the way, the Test class that contains the Test method is "EntityInstanceManager_Tests" in the Datansa.App.Domain.Tests project under the "Solution" folder.
Is there a way to provide my Project privately ?