Activities of "VivekKoppula"

I created a starter Balzor Server project and ran in two scenerios. The two scenerios differ only in the fact that the ASPNETCORE_ENVIRONMENT is different. In one case its 'Development', and in the other case its 'DevelopmentTwo', anything other then 'Development'

First the necessary details are as follows.

The dotnet version is 6.0.100-rc.2.21505.57 ABP version is 4.4.3 (Stable)

UI Type is Blazor Server. No Preview(Its just .net 5)

DB Provide: Ef Core

Tiered (MVC) or Identity Server Separated (Angular): No

Now the two scenerios.

I am running the blazor app running on my localhost.

In the scenerio one, I connect to the local db database on my local machine. The ASPNETCORE_ENVIRONMENT is 'Development'. For this I selected the IIS Express profile which looks as follows in launchSettings.json.

"IIS Express": {
	  "commandName": "IISExpress",
	  "launchBrowser": true,
	  "environmentVariables": {
		"ASPNETCORE_ENVIRONMENT": "Development"
	  }
	},
    

I created settings file named it appsettings.Development.json. Its contents are as follows.

{
  "ConnectionStrings": {
	"Default": "Data Source=(localdb)\\MSSQLLocalDB;Initial Catalog=BvhHrSita;Integrated Security=True;Connect Timeout=30;Encrypt=False;TrustServerCertificate=False;ApplicationIntent=ReadWrite;MultiSubnetFailover=False"
  },
  "SomeVar": "Development Env"
}

I modified the CreateHostBuilder method in the Program.cs file as follows to include the appsettings.development.json file.

    public static IHostBuilder CreateHostBuilder(string[] args) =>
        Host.CreateDefaultBuilder(args)
            .ConfigureAppConfiguration(build =>
            {

                var env = Environment.GetEnvironmentVariable("ASPNETCORE_ENVIRONMENT");

                build.AddJsonFile("appsettings.secrets.json", optional: false);
                build.AddJsonFile("appsettings.json", optional: false);
                build.AddJsonFile($"appsettings.{env}.json", optional: false);
            })
            .ConfigureWebHostDefaults(webBuilder =>
            {
                webBuilder.UseStartup<Startup>();
            })
            .UseAutofac()
            .UseSerilog();
            

In this scenerio, the app works fine as expected.

In the scenerio two, everything is same except the ASPNETCORE_ENVIRONMENT is anything other than 'Development', I choose 'DevelopmentTwo'. To create this scenerio I did the following.

First I made a copy of appsettings.Development.json and named it appsettings.DevelopmentTwo.json. Its contents are as follows.

{
  "ConnectionStrings": {
	"Default": "Data Source=(localdb)\\MSSQLLocalDB;Initial Catalog=BvhHrSita;Integrated Security=True;Connect Timeout=30;Encrypt=False;TrustServerCertificate=False;ApplicationIntent=ReadWrite;MultiSubnetFailover=False"
  },
  "SomeVar": "Developemnt Two Env"
}

The Connection String is exactly same, only the SomeVar is now as you can see Development Two Env.

Also I added a new profile in launchSettings.json as follows to help me set env var ASPNETCORE_ENVIRONMENT to DevelopmentTwo as follows.

"IISExpressDevTwo": {
  "commandName": "IISExpress",
  "launchBrowser": true,
  "environmentVariables": {
    "ASPNETCORE_ENVIRONMENT": "DevelopmentTwo"
  }
},

Here again, the only diff is ASPNETCORE_ENVIRONMENT which is DevelopmentTwo.

Now when I run this profile, the app does not run properly.

If I press F12 to look at the console, I see the following mesages.

DevTools failed to load source map: Could not load content for https://localhost:44313/__bundles/toastr.js.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for https://localhost:44313/__bundles/bootstrap.min.css.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE	

I added a few lines of code to the ConfigureServices Method in BlazorModule.cs file to know exactly which profile is being loaded and what the evn var is as follows. This is just for debugging, and not required for reproducing the issue.

    public override void ConfigureServices(ServiceConfigurationContext context)
    {
        var hostingEnvironment = context.Services.GetHostingEnvironment();
        var configuration = context.Services.GetConfiguration();

        var env = Environment.GetEnvironmentVariable("ASPNETCORE_ENVIRONMENT");
        var envName = hostingEnvironment.EnvironmentName;
        var connString = configuration.GetConnectionString("Default");
        //configuration

        var myValue = configuration.GetValue<string>("SomeVar");


        ConfigureUrls(configuration);
        

So now when I launch the app, I see the following

If I select the earlier profile, where the ASPNETCORE_ENVIRONMENT is just Development and not DevelopmentTwo, I see the following as I launch the app.

So as you can see the the only difference is ASPNETCORE_ENVIRONMENT.

In summary, when ever ASPNETCORE_ENVIRONMENT is anything other then Development, the app would not run properly. The F12 shows the following.

DevTools failed to load source map: Could not load content for https://localhost:44313/__bundles/toastr.js.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE
DevTools failed to load source map: Could not load content for https://localhost:44313/__bundles/bootstrap.min.css.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE	

And when I see the logs, I see an exception like the following(when the ASPNETCORE_ENVIRONMENT is anything other then Development).

2021-10-24 18:12:09.000 +05:30 [DBG] Added 0 entity changes to the current audit log
2021-10-24 18:12:09.020 +05:30 [ERR] An unhandled exception has occurred while executing the request.
Volo.Abp.AbpException: Could not find file '/_content/Blazorise/blazorise.css'
   at Volo.Abp.AspNetCore.Mvc.UI.Bundling.BundlerBase.GetFileInfo(IBundlerContext context, String file)
   at Volo.Abp.AspNetCore.Mvc.UI.Bundling.BundlerBase.GetAndMinifyFileContent(IBundlerContext context, String fileName)
   at Volo.Abp.AspNetCore.Mvc.UI.Bundling.BundlerBase.GetFileContentConsideringMinification(IBundlerContext context, String fileName)
   at Volo.Abp.AspNetCore.Mvc.UI.Bundling.BundlerBase.Bundle(IBundlerContext context)
   at Volo.Abp.AspNetCore.Mvc.UI.Bundling.BundleManager.<>c__DisplayClass16_0.<GetBundleFilesAsync>b__0()
   at System.Collections.Generic.AbpDictionaryExtensions.&lt;&gt;c__DisplayClass7_0`2.<GetOrAdd>b__0(TKey k)
   at System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory)
   at System.Collections.Generic.AbpDictionaryExtensions.GetOrAdd[TKey,TValue](ConcurrentDictionary`2 dictionary, TKey key, Func`1 factory)
   at Volo.Abp.AspNetCore.Mvc.UI.Bundling.BundleCache.GetOrAdd(String bundleName, Func`1 factory)

Something is fishy with respect to bundling. But when the env var is ASPNETCORE_ENVIRONMENT is Development things run fine.

Hope that I am not missing something trivial here and you will be able to reproduce this. Any advice is appreciated. Let me know if you need any details further.

I suggest take a look at this bug that I created first and then come here.

I created a starter Balzor Server project and deployed it to Azure. While it looks fine on local mcahine, something is wrong when ran on Azure.

The details are as follows.

The dotnet version is 6.0.100-rc.2.21505.57 ABP version is 4.4.3 (Stable)

UI Type is Blazor Server.

DB Provide: Ef Core

Tiered (MVC) or Identity Server Separated (Angular): No

First I created necessary resources on Azure, Web App Service and also backend Database.

I applied the migrations on the created database using the migrator project.

Then created a env var on the app service as follows.

Now I generated the app on .net 5(no preview, and not .net 6), and next in the code, I added a appsettings.Production.json file for production database(on azure) connection string.

Now I deployed the app from Visual Studio Publish as follows.

Finally the problem.

I launch the website running on Azure, the home page looks fine. I click the login link to get to the login page. This is also fine.

Once I login, the home page now looks differet, and here is the problem.

The left menu does not have the Saas and Administration menu items.

On the right, the admin does not appear, but you can click it.

When I pressed F12, I saw this message, but it seems there is no relevance to the problem at hand.

DevTools failed to load source map: Could not load content for https://bvhhrsitawebsitedev.azurewebsites.net/__bundles/toastr.js.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE

I felt there is some problem with bundling, and so I commented out the following code to diable the bundling and then redeployed. But the problem remained.

While My Account page looks fine as I navigate to it, the tenants page on the other hand has a different problem.

Authorization Failed, Given policy has not granted.

Other pages also show errors.

Hope I am not missing something trival.

I created a new Blazor Server(Not Web Assembly) app and I get the following error as I run the app.

Sometimes it works, but most f the times, I am getting this error.

The dotnet version is 6.0.100-rc.2.21505.57 ABP version is 4.4.3 (Stable)

  • DB provider: Its EF Core with Sql
  • Tiered (MVC) or Identity Server Separated (Angular): no

Let me know, If you need any further details.

I used preview checkbox so the latest is used. I am keen for the preview because hot reloading is supported in .net 6, and with blazor server(not web assembly) and I have also the latest VS 2022 Preview 5. So a typical csproj file looks like this.

	  <PropertyGroup>
		<TargetFramework>net6.0</TargetFramework>
		<AspNetCoreHostingModel>InProcess</AspNetCoreHostingModel>
		<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
		<GenerateBindingRedirectsOutputType>true</GenerateBindingRedirectsOutputType>
		<GenerateRuntimeConfigurationFiles>true</GenerateRuntimeConfigurationFiles>
		<MvcRazorExcludeRefAssembliesFromPublish>false</MvcRazorExcludeRefAssembliesFromPublish>
		<PreserveCompilationReferences>true</PreserveCompilationReferences>
	  </PropertyGroup>

	  <ItemGroup>
		<PackageReference Include="AspNetCore.HealthChecks.UI" Version="5.0.1" />
		<PackageReference Include="AspNetCore.HealthChecks.UI.Client" Version="5.0.1" />
		<PackageReference Include="AspNetCore.HealthChecks.UI.InMemory.Storage" Version="5.0.1" />
		<PackageReference Include="Serilog.AspNetCore" Version="4.0.0" />
		<PackageReference Include="Serilog.Sinks.Async" Version="1.5.0" />
		<PackageReference Include="Blazorise.Bootstrap" Version="0.9.4.1" />
		<PackageReference Include="Blazorise.Icons.FontAwesome" Version="0.9.4.1" />
		<PackageReference Include="Microsoft.AspNetCore.Authentication.Google" Version="6.0.0-rc.*" />
		<PackageReference Include="Microsoft.AspNetCore.Authentication.MicrosoftAccount" Version="6.0.0-rc.*" />
		<PackageReference Include="Microsoft.AspNetCore.Authentication.Twitter" Version="6.0.0-rc.*" />
	  </ItemGroup>

	  <ItemGroup>
		<ProjectReference Include="..\Bvh.HrSita.Application\Bvh.HrSita.Application.csproj" />
		<ProjectReference Include="..\Bvh.HrSita.HttpApi\Bvh.HrSita.HttpApi.csproj" />
		<ProjectReference Include="..\Bvh.HrSita.EntityFrameworkCore\Bvh.HrSita.EntityFrameworkCore.csproj" />
		<PackageReference Include="Volo.Abp.Autofac" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.Swashbuckle" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.AspNetCore.Authentication.JwtBearer" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.AspNetCore.Serilog" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.AspNetCore.Mvc.UI.Theme.Lepton" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.AspNetCore.Components.Server.LeptonTheme" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.Account.Pro.Public.Web.IdentityServer" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.Account.Pro.Admin.Blazor.Server" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.AuditLogging.Blazor.Server" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.Identity.Pro.Blazor.Server" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.LeptonTheme.Management.Blazor.Server" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.IdentityServer.Blazor.Server" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.LanguageManagement.Blazor.Server" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Saas.Host.Blazor.Server" Version="5.0.0-beta.1" />
		<PackageReference Include="Volo.Abp.TextTemplateManagement.Blazor.Server" Version="5.0.0-beta.1" />
	  </ItemGroup>

The logs look below.

2021-10-17 12:17:34.118 +05:30 [INF] Authorization failed. These requirements were not met:
		PermissionRequirement: LeptonThemeManagement.Settings
		2021-10-17 12:17:34.121 +05:30 [INF] Authorization failed. These requirements were not met:
		PermissionRequirement: LeptonThemeManagement.Settings
		2021-10-17 12:17:34.389 +05:30 [WRN] Unhandled exception rendering component: Undefined permission: IdentitySer�
		Volo.Abp.AbpException: Undefined permission: IdentitySer�
		   at Volo.Abp.Authorization.Permissions.PermissionDefinitionManager.Get(String name)
		   at Volo.Abp.Authorization.Permissions.PermissionChecker.IsGrantedAsync(ClaimsPrincipal claimsPrincipal, String[] names)
		   at Volo.Abp.Authorization.Permissions.PermissionChecker.IsGrantedAsync(String[] names)
		   at Volo.Abp.Authorization.Permissions.RequirePermissionsSimpleBatchStateChecker`1.IsEnabledAsync(SimpleBatchStateCheckerContext`1 context)
		   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 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, ComponentState owningComponentState)
		2021-10-17 12:17:34.395 +05:30 [ERR] Unhandled exception in circuit 'dIVgARWqvTUNtLj0M2vYqV8hgjEwCDp1me3m7bVpJdE'.
        
        
		2021-10-17 12:19:03.476 +05:30 [INF] Request starting HTTP/2 POST https://localhost:44313/_blazor/disconnect multipart/form-data;+boundary=----WebKitFormBoundarya2fTLzwEz9Z9ylvJ 359
		2021-10-17 12:19:03.496 +05:30 [INF] No CORS policy found for the specified request.
		2021-10-17 12:19:03.497 +05:30 [INF] Executing endpoint 'Blazor disconnect'
		2021-10-17 12:19:03.500 +05:30 [INF] Executed endpoint 'Blazor disconnect'
		2021-10-17 12:19:03.502 +05:30 [INF] Request finished HTTP/2 POST https://localhost:44313/_blazor/disconnect multipart/form-data;+boundary=----WebKitFormBoundarya2fTLzwEz9Z9ylvJ 359 - 200 - - 25.3870ms

This is a follow upto this question

I am trying to add swagger support by doing the following.

  1. Added the following line of code the web module.

    context.Services.AddElsaApiEndpoints(); // The following is throwing exception context.Services.AddElsaSwagger();

But it is throwing exception. The exception is shown below for your reference. So I had to comment out.

  1. Also tried to add the following code in the same ElsaDemoWebModule.cs file.

    app.UseAbpSwaggerUI(options => { options.SwaggerEndpoint("/swagger/v1/swagger.json", "ElsaDemo API"); // The following did not help. options.SwaggerEndpoint("/swagger/v1/swagger.json", "Elsa"); });

But it did help. I get Elsa in the drop down, but selecting it does not give the elsa swagger UI.

The full exception is as follows.

An unhandled exception occurred while processing the request. ArgumentException: An item with the same key has already been added. Key: v1 System.Collections.Generic.Dictionary<TKey, TValue>.TryInsert(TKey key, TValue value, InsertionBehavior behavior)

DependencyResolutionException: An exception was thrown while invoking the constructor 'Void .ctor(Microsoft.Extensions.Options.IOptions`1[Swashbuckle.AspNetCore.SwaggerGen.SwaggerGenOptions], System.IServiceProvider, Microsoft.AspNetCore.Hosting.IWebHostEnvironment)' on type 'ConfigureSwaggerGeneratorOptions'. Autofac.Core.Activators.Reflection.BoundConstructor.Instantiate()

DependencyResolutionException: An exception was thrown while activating Swashbuckle.AspNetCore.SwaggerGen.SwaggerGenerator -> λ:Swashbuckle.AspNetCore.SwaggerGen.SwaggerGeneratorOptions -> Microsoft.Extensions.Options.OptionsManager1[[Swashbuckle.AspNetCore.SwaggerGen.SwaggerGeneratorOptions, Swashbuckle.AspNetCore.SwaggerGen, Version=6.1.4.0, Culture=neutral, PublicKeyToken=d84d99fb0135530a]] -> Microsoft.Extensions.Options.OptionsFactory1[[Swashbuckle.AspNetCore.SwaggerGen.SwaggerGeneratorOptions, Swashbuckle.AspNetCore.SwaggerGen, Version=6.1.4.0, Culture=neutral, PublicKeyToken=d84d99fb0135530a]] -> λ:Microsoft.Extensions.Options.IConfigureOptions`1[[Swashbuckle.AspNetCore.SwaggerGen.SwaggerGeneratorOptions, Swashbuckle.AspNetCore.SwaggerGen, Version=6.1.4.0, Culture=neutral, PublicKeyToken=d84d99fb0135530a]][] -> Swashbuckle.AspNetCore.SwaggerGen.ConfigureSwaggerGeneratorOptions. Autofac.Core.Resolving.Middleware.ActivatorErrorHandlingMiddleware.Execute(ResolveRequestContext context, Action<ResolveRequestContext> next)

I tried the abp elsa demo example available at github after following this post.

Things look fine for the coded workflows defined within the workflows folder.

But then I created a simple workflow from the UI as follows. This did not work.

You can create the same workflow by exporting the json(pasted at the end below) file as follows.

After ensuring that it is published, when I run it, it simply shows the elsa workflow page instead of Hello Everyone text reponse.

I tried the same get requst with postman and the result is the same _Host page.

Note that the coded http workflow works fine.

I felt this has got to do with routing, and tried commenting out the following line.

app.UseConfiguredEndpoints(endpoints =>
{
    //endpoints.MapFallbackToPage("/_Host");
});

But this shows 404 not found.

I dont know what to do now. Can you please help me?

You can import the following Json to created the workflow in the ui.

{
  "$id": "1",
  "definitionId": "2d3efd5f41d54f1aafd6772fead4c916",
  "versionId": "73cad85d8a3044ccb21a80d7804c555d",
  "name": "SimpleHelloWorld",
  "displayName": "Simple Hello World",
  "description": "Simple Http workflow created from UI. For a http get request to elsa-hello-world, this returns a simple http text reponse",
  "version": 1,
  "variables": {
	"$id": "2",
	"data": {}
  },
  "customAttributes": {
	"$id": "3",
	"data": {}
  },
  "isSingleton": false,
  "persistenceBehavior": "WorkflowBurst",
  "deleteCompletedInstances": false,
  "isPublished": false,
  "isLatest": true,
  "activities": [
	{
	  "$id": "4",
	  "activityId": "c976ee95-cb57-4fd3-b586-0268cb134025",
	  "type": "HttpEndpoint",
	  "displayName": "HTTP Endpoint",
	  "persistWorkflow": false,
	  "loadWorkflowContext": false,
	  "saveWorkflowContext": false,
	  "persistOutput": false,
	  "properties": [
		{
		  "$id": "5",
		  "name": "Path",
		  "expressions": {
			"$id": "6",
			"Literal": "elsa-hello-world"
		  }
		},
		{
		  "$id": "7",
		  "name": "Methods",
		  "expressions": {
			"$id": "8",
			"Json": "[\"GET\"]"
		  }
		},
		{
		  "$id": "9",
		  "name": "ReadContent",
		  "expressions": {
			"$id": "10"
		  }
		},
		{
		  "$id": "11",
		  "name": "TargetType",
		  "expressions": {
			"$id": "12"
		  }
		}
	  ]
	},
	{
	  "$id": "13",
	  "activityId": "9c9faf81-febb-487b-a3c6-6aa87dc7c197",
	  "type": "WriteHttpResponse",
	  "displayName": "HTTP Response",
	  "persistWorkflow": false,
	  "loadWorkflowContext": false,
	  "saveWorkflowContext": false,
	  "persistOutput": false,
	  "properties": [
		{
		  "$id": "14",
		  "name": "StatusCode",
		  "expressions": {
			"$id": "15"
		  }
		},
		{
		  "$id": "16",
		  "name": "Content",
		  "expressions": {
			"$id": "17",
			"Literal": "Hello Everyone"
		  }
		},
		{
		  "$id": "18",
		  "name": "ContentType",
		  "expressions": {
			"$id": "19"
		  }
		}
	  ]
	}
  ],
  "connections": [
	{
	  "$id": "20",
	  "sourceActivityId": "c976ee95-cb57-4fd3-b586-0268cb134025",
	  "targetActivityId": "9c9faf81-febb-487b-a3c6-6aa87dc7c197",
	  "outcome": "Done"
	}
  ],
  "id": "73cad85d8a3044ccb21a80d7804c555d"
}

I created an asp.net mvc web app using abp suite with the following options.

Template Type: Application Template UI Framework: MVC Database provider: Entity Framework Core Database management system: SQLServer Public web site: Not checked Seperate tenant schema: Not checked Tiered: Not checked

Whenever an exception is thrown, it simply swallows it. Is there any setting that I am missing?

In contrast to this, ealier a few months back, I created an angular app with Abp Community, and whenever the code throws and exception, the UI shows a friendly message.

Is there any setting that I am missing in the asp.net mvc app?

The options choosen when creating asp.net mvc app with Abp suite are as follows.

I created an multi tenant application as per the options shown here in these images in this issue(closed now).

I created a new entity called Gender as per the steps explained in this section. I

I did not want mult-tenant feature on this, so ensured the multi-tenant check box is NOT Selected.

When I run the appication, every thing is working fine.

The host admin is now able to created objects of Gender.

Now I dont want the tenants to create such objects. I logged in as CompanyA/Admin(tenant - CompanyA) and I am able to create Gender.

I want to restrict this. Tenants should not be allowed to create Gender objects while the host should be allowed. How can I achieve that?

Looking at the code, it appears that this should be something to do with Permissions. But I have no clue what do with this.

public class Genders {
    public const string Default = GroupName + ".Genders";
    public const string Edit = Default + ".Edit";
    public const string Create = Default + ".Create";
    public const string Delete = Default + ".Delete";
}

One way I found is to ensure that the tenant id is null in the GenderAppService class. If the tenant id is not null, then it means that the user is from a tenant. Then in such a case throw some exception. But this is from the developers perspective. Can the end host admin do something himself to impose such a restriction?

I created a new application as per the steps here.

The options choosen during solution creation are as per the images shown in this issue(closed now)

I am not able to successifully login, able to create another admin also and login.

But when it comes to creating a new tenant, the login to the new tenant is always failing.

I tried three times, completely deleting the database and starting fresh everytime.

What am I missing?

From the commercial login, I created a mvc app as follows(see first 3 images below).

Next I created a database on localdb as shown in 4th image below and updated the connection strings.

Now when I run the app, I get the exception

SqlException: Invalid object name 'AbpLanguages'. Microsoft.Data.SqlClient.SqlCommand+<>c.<ExecuteDbDataReaderAsync>b__169_0(Task<SqlDataReader> result)

The full exception stack is pasted below the images. If you need the full solution as zipped file, let me know how to attach, I will do that. But there is nothing that I had done to it except for the connection strings updation.

So what am I missing?

Exception full Info

SqlException: Invalid object name 'AbpLanguages'. Microsoft.Data.SqlClient.SqlCommand+<>c.<ExecuteDbDataReaderAsync>b__169_0(Task<SqlDataReader> result)

Stack Query Cookies Headers Routing SqlException: Invalid object name 'AbpLanguages'. Microsoft.Data.SqlClient.SqlCommand+<>c.<ExecuteDbDataReaderAsync>b__169_0(Task<SqlDataReader> result) System.Threading.Tasks.ContinuationResultTaskFromResultTask<TAntecedentResult, TResult>.InnerInvoke() System.Threading.Tasks.Task+<>c.<.cctor>b__277_0(object obj) System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, object state) System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, object state) System.Threading.Tasks.Task.ExecuteWithThreadLocal(ref Task currentTaskSlot, Thread threadPoolThread) Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken) Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken) Microsoft.EntityFrameworkCore.Query.Internal.SplitQueryingEnumerable<T>+AsyncEnumerator.InitializeReaderAsync(DbContext _, bool result, CancellationToken cancellationToken) Microsoft.EntityFrameworkCore.SqlServer.Storage.Internal.SqlServerExecutionStrategy.ExecuteAsync<TState, TResult>(TState state, Func<DbContext, TState, CancellationToken, Task<TResult>> operation, Func<DbContext, TState, CancellationToken, Task<ExecutionResult<TResult>>> verifySucceeded, CancellationToken cancellationToken) Microsoft.EntityFrameworkCore.Query.Internal.SplitQueryingEnumerable<T>+AsyncEnumerator.MoveNextAsync() Microsoft.EntityFrameworkCore.EntityFrameworkQueryableExtensions.ToListAsync<TSource>(IQueryable<TSource> source, CancellationToken cancellationToken) Microsoft.EntityFrameworkCore.EntityFrameworkQueryableExtensions.ToListAsync<TSource>(IQueryable<TSource> source, CancellationToken cancellationToken) Volo.Abp.LanguageManagement.EntityFrameworkCore.EfCoreLanguageRepository.GetListByIsEnabledAsync(bool isEnabled, CancellationToken cancellationToken) Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous<TResult>(IInvocation invocation, IInvocationProceedInfo proceedInfo) Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapterWithReturnValue<TResult>.ProceedAsync() Volo.Abp.Uow.UnitOfWorkInterceptor.InterceptAsync(IAbpMethodInvocation invocation) Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter<TInterceptor>.InterceptAsync<TResult>(IInvocation invocation, IInvocationProceedInfo proceedInfo, Func<IInvocation, IInvocationProceedInfo, Task<TResult>> proceed) Volo.Abp.LanguageManagement.DatabaseLanguageProvider.d2bvcd7xA() Volo.Abp.Caching.DistributedCache<TCacheItem, TCacheKey>.GetOrAddAsync(TCacheKey key, Func<Task<TCacheItem>> factory, Func<DistributedCacheEntryOptions> optionsFactory, Nullable<bool> hideErrors, bool considerUow, CancellationToken token) Volo.Abp.LanguageManagement.DatabaseLanguageProvider.GetLanguagesAsync() Microsoft.AspNetCore.RequestLocalization.DefaultAbpRequestLocalizationOptionsProvider.GetLocalizationOptionsAsync() 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)

Show raw exception details Microsoft.Data.SqlClient.SqlException (0x80131904): Invalid object name 'AbpLanguages'. at Microsoft.Data.SqlClient.SqlCommand.<>c.<ExecuteDbDataReaderAsync>b__169_0(Task1 result) at System.Threading.Tasks.ContinuationResultTaskFromResultTask2.InnerInvoke() at System.Threading.Tasks.Task.<>c.<.cctor>b__277_0(Object obj) 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.SplitQueryingEnumerable1.AsyncEnumerator.InitializeReaderAsync(DbContext _, Boolean result, CancellationToken cancellationToken) at Microsoft.EntityFrameworkCore.SqlServer.Storage.Internal.SqlServerExecutionStrategy.ExecuteAsync[TState,TResult](TState state, Func4 operation, Func4 verifySucceeded, CancellationToken cancellationToken) at Microsoft.EntityFrameworkCore.Query.Internal.SplitQueryingEnumerable1.AsyncEnumerator.MoveNextAsync() at Microsoft.EntityFrameworkCore.EntityFrameworkQueryableExtensions.ToListAsync[TSource](IQueryable1 source, CancellationToken cancellationToken) at Microsoft.EntityFrameworkCore.EntityFrameworkQueryableExtensions.ToListAsync[TSource](IQueryable1 source, CancellationToken cancellationToken) at Volo.Abp.LanguageManagement.EntityFrameworkCore.EfCoreLanguageRepository.GetListByIsEnabledAsync(Boolean isEnabled, CancellationToken cancellationToken) at Castle.DynamicProxy.AsyncInterceptorBase.ProceedAsynchronous[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo) at Volo.Abp.Castle.DynamicProxy.CastleAbpMethodInvocationAdapterWithReturnValue1.ProceedAsync() at Volo.Abp.Uow.UnitOfWorkInterceptor.InterceptAsync(IAbpMethodInvocation invocation) at Volo.Abp.Castle.DynamicProxy.CastleAsyncAbpInterceptorAdapter1.InterceptAsync[TResult](IInvocation invocation, IInvocationProceedInfo proceedInfo, Func3 proceed) at Volo.Abp.LanguageManagement.DatabaseLanguageProvider.d2bvcd7xA() at Volo.Abp.Caching.DistributedCache2.GetOrAddAsync(TCacheKey key, Func1 factory, Func1 optionsFactory, Nullable`1 hideErrors, Boolean considerUow, CancellationToken token) at Volo.Abp.LanguageManagement.DatabaseLanguageProvider.GetLanguagesAsync() at Microsoft.AspNetCore.RequestLocalization.DefaultAbpRequestLocalizationOptionsProvider.GetLocalizationOptionsAsync() at Microsoft.AspNetCore.RequestLocalization.AbpRequestLocalizationMiddleware.InvokeAsync(HttpContext context, RequestDelegate next) at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass6_1.<

And the headers from the brwser are as follows.

Variable Value Accept text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,/;q=0.8,application/signed-exchange;v=b3;q=0.9 Accept-Encoding gzip, deflate, br Accept-Language en-US,en;q=0.9 Cache-Control no-cache Connection close Host localhost:44375 Pragma no-cache sec-ch-ua " Not;A Brand";v="99", "Google Chrome";v="91", "Chromium";v="91" sec-ch-ua-mobile ?0 sec-fetch-dest document sec-fetch-mode navigate sec-fetch-site none sec-fetch-user ?1 upgrade-insecure-requests 1 User-Agent Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.106 Safari/537.36

Showing 1 to 9 of 9 entries
Made with ❤️ on ABP v8.2.0-preview Updated on March 25, 2024, 15:11