Activities of "cangunaydin"

oh nice, thank you. I think there are also many problems with the profile page but I can create a new ticket for them. thanks for your help.

Thanks for the information. I have managed to fix it now. It works without autofac. here is the step by step what i did if somebody wants to do it.

1- Change all your dynamic client proxies to static ones. 2- Remove Autofac from the project solution

[DependsOn(
    typeof(AbpMauiClientModule),
    typeof(AbpHttpClientIdentityModelModule),
    typeof(DoohlinkHttpApiStaticClientModule), //your static client over here
    typeof(AbpAutoMapperModule)
)]
public class DoohlinkMauiModule : AbpModule
{

3- Remove Autofac from MauiProgram.cs it should be sth similar like this, I have created static methods to get the required service from dependency injection for the following steps.

 public static IAbpApplicationWithExternalServiceProvider? AbpApplication { get; private set; }

    public static MauiApp CreateMauiApp()
    {
        var builder = MauiApp.CreateBuilder();
        builder
            .UseMauiApp<App>()
            .UseMauiCommunityToolkit()
            .ConfigureSyncfusionCore()
            .ConfigureFonts(fonts =>
            {
                fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
                fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
                fonts.AddFont("Roboto-Regular.ttf", "Roboto");
                fonts.AddMaterialIconFonts();
            });

        builder.ConfigureMauiHandlers(handlers =>
        {
            handlers.AddHandler(typeof(Entry), typeof(EntryVisualEffectsRemoverHandler));
            handlers.AddHandler(typeof(Picker), typeof(PickerVisualEffectsRemoverHandler));
            handlers.AddHandler(typeof(DatePicker), typeof(DatePickerVisualEffectsRemoverHandler));
        });
        ConfigureConfiguration(builder);

        builder.Services.AddApplication<DoohlinkMauiModule>(options =>
        {
            options.Services.ReplaceConfiguration(builder.Configuration);
        });

#if DEBUG
        builder.Logging.AddDebug();
#endif
        var app = builder.Build();

        AbpApplication = app.Services.GetRequiredService<IAbpApplicationWithExternalServiceProvider>();
        AbpApplication.Initialize(app.Services);

        return app;
    }

    public static T? GetRequiredService<T>() where T : class
    {
        return AbpApplication?.Services.GetRequiredService<T>();
    }

    public static object? GetRequiredService(Type type)
    {
        return AbpApplication?.Services.GetRequiredService(type);
    }

4- ReplaceService for MauiCachedApplicationConfigurationClient. Add custom class

    [Volo.Abp.DependencyInjection.Dependency(ReplaceServices = true)]
[ExposeServices(typeof(ICachedApplicationConfigurationClient), typeof(MauiCachedApplicationConfigurationClient))]
public class DoohlinkMauiCachedApplicationConfigurationClient : MauiCachedApplicationConfigurationClient
{
    public DoohlinkMauiCachedApplicationConfigurationClient(
        AbpApplicationConfigurationClientProxy applicationConfigurationClientProxy,
        AbpApplicationLocalizationClientProxy applicationLocalizationClientProxy,
        ApplicationConfigurationCache cache,
        ICurrentTenantAccessor currentTenantAccessor) : base(applicationConfigurationClientProxy,
        applicationLocalizationClientProxy, cache, currentTenantAccessor)
    {
        ApplicationConfigurationClientProxy.LazyServiceProvider =
            MauiProgram.GetRequiredService<IAbpLazyServiceProvider>()!;
        ApplicationLocalizationClientProxy.LazyServiceProvider = MauiProgram.GetRequiredService<IAbpLazyServiceProvider>()!;
    }
}

5- Change ViewModelBase, so it doesn't need LazyServiceProvider anymore.

   public abstract partial class DoohlinkViewModelBase : ObservableObject
{

    public ICurrentTenant CurrentTenant { get; }
    
    public ICurrentUser CurrentUser { get; }

    public IAbpAuthorizationService AuthorizationService { get; }

    public LocalizationResourceManager L { get; }

    protected DoohlinkViewModelBase()
    {
        CurrentTenant = MauiProgram.GetRequiredService<ICurrentTenant>()!;
        CurrentUser = MauiProgram.GetRequiredService<ICurrentUser>()!;
        AuthorizationService = MauiProgram.GetRequiredService<IAbpAuthorizationService>()!;
        L = MauiProgram.GetRequiredService<LocalizationResourceManager>()!;
        
    }

    protected void HandleException(Exception exception, [CallerMemberName] string? methodName = null)
    {
        if (Application.Current is { MainPage: { } })
        {
            Application.Current.MainPage.DisplayAlert(L["Error"].Value, exception.Message, L["OK"].Value);
        }
    }
}

6- Change the MauiModule so lazyserviceprovider can be resolved when you call your app services.

 private void ConfigureServiceProviders(ServiceConfigurationContext context)
    {
        context.Services.Replace(ServiceDescriptor.Transient<IProfileAppService>(serviceProvider =>
        {
            var profileClientProxy = serviceProvider.GetRequiredService<ProfileClientProxy>();
            profileClientProxy.LazyServiceProvider = serviceProvider.GetRequiredService<IAbpLazyServiceProvider>();
            return profileClientProxy;
        }));

        context.Services.Replace(ServiceDescriptor.Transient<IIdentityUserAppService>(serviceProvider =>
        {
            var identityUserClientProxy = serviceProvider.GetRequiredService<IdentityUserClientProxy>();
            identityUserClientProxy.LazyServiceProvider = serviceProvider.GetRequiredService<IAbpLazyServiceProvider>();
            return identityUserClientProxy;
        }));
        context.Services.Replace(ServiceDescriptor.Transient<IAccountAppService>(serviceProvider =>
        {
            var accountClientProxy = serviceProvider.GetRequiredService<AccountClientProxy>();
            accountClientProxy.LazyServiceProvider = serviceProvider.GetRequiredService<IAbpLazyServiceProvider>();
            return accountClientProxy;
        }));

        context.Services.Replace(ServiceDescriptor.Transient<IScreenAppService>(serviceProvider =>
        {
            var screenClientProxy = serviceProvider.GetRequiredService<ScreenClientProxy>();
            screenClientProxy.LazyServiceProvider = serviceProvider.GetRequiredService<IAbpLazyServiceProvider>();
            return screenClientProxy;
        }));


        context.Services.Replace(ServiceDescriptor.Transient<ITenantAppService>(serviceProvider =>
        {
            var tenantClientProxy = serviceProvider.GetRequiredService<TenantClientProxy>();
            tenantClientProxy.LazyServiceProvider = serviceProvider.GetRequiredService<IAbpLazyServiceProvider>();
            return tenantClientProxy;
        }));
    }

you need to add whatever appservice you use over here. Maybe this can be automated for the future.

7- Add permissions manually.

    public override void PreConfigureServices(ServiceConfigurationContext context)
    {
        AddPermissions(context);
#if DEBUG
        PreConfigure<AbpHttpClientBuilderOptions>(options =>
        {
            options.ProxyClientBuildActions.Add((_, clientBuilder) =>
            {
                clientBuilder.ConfigurePrimaryHttpMessageHandler(GetInsecureHandler);
            });
        });
#endif
    }
    private void AddPermissions(ServiceConfigurationContext context)
    {
        Assembly[] assemblies = AppDomain.CurrentDomain.GetAssemblies();
        var permissionDefinitionTypes = assemblies.SelectMany(o => o.GetTypes()).Where(o =>
                typeof(IPermissionDefinitionProvider).IsAssignableFrom(o) &&
                o.Name != nameof(IPermissionDefinitionProvider) && o.Name != nameof(PermissionDefinitionProvider))
            .Distinct().ToList();

        context.Services.Configure<AbpPermissionOptions>(options =>
        {
            options.DefinitionProviders.AddIfNotContains(permissionDefinitionTypes);
        });
    }

And voila... I am gonna close this issue liangshiwei but one last question. How can I get the source code of AbpMauiClientModule? thank you for the help.

  • ABP Framework version: v8.0
  • UI Type: Maui
  • Database System: EF Core
  • Tiered (for MVC) or Auth Server Separated (for Angular): yes

Hello, I was trying to publish my maui app to appstore but it is rejected. The reason behind is app crashing on startup when it is on release. After I check it up, i understand that reason behind is autofac module. Since it uses reflections and ios doesn't allow it. If you are debugging your app in maui, useinterpreter property is on. So the app is not crashing. There is a discussion over here about the problem. https://github.com/dotnet/maui/issues/13019

But when you switch to release mode since it makes your app slow down, it is turned off and the problem arises. So at the end i decided to create all my httpclient projects as static and remove the autofac from maui app. I had a previous issue that i open a ticket. You can find it here. In that case it was avalonia app. https://support.abp.io/QA/Questions/6476/Problem-using-httpclient-module-in-avalonia-ios-or-xamarin-forms-ios-projects

I managed to fix the issue on almost all appservices. Only problem right now is with authorizationservice. In this line i am getting "no policy found" error.

probably in the background since i removed autofac module authorization service is trying to do the same thing on the web server. It is not intercepted anymore i guess. Is there any way to fix that problem? Also i think maui project shouldn't depend on autofac since intercepting is no no for ios.

thank you. I will do that.

thank you @maliming. this is what i was looking for. you are a life saviour. I have tried it and it works nicely. I am gonna close this issue, but just one last thing. Is it possible to override clientproxybase so i don't need to do the same for every service that i am injecting.

sampleAppService.As<SampleClientProxy>().LazyServiceProvider = AbpBootstrapper.GetRequiredService<IAbpLazyServiceProvider>();


I can write another static method to get the service, but mostly i use constructor injection on my projects. I didn't use it in this example cause of designer data context. any suggestion for that?

Hello, yes it works for desktop and android, but the problem is in ios. As i mentioned before in my previous posts. Did you try it with ios?

Hello again, the link was very useful. But i speak too soon. The problem persists still.

The platform not supported exception gone but when i do the call, then i got an exception below from clientproxybase.

System.AggregateException: One or more errors occurred. (Object reference not set to an instance of an object)
 ---> System.NullReferenceException: Object reference not set to an instance of an object
   at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase`1[[BookStore.Category.Samples.ISampleAppService, BookStore.Category.Application.Contracts, Version=0.1.0.0, Culture=neutral, PublicKeyToken=null]].get_ClientProxyApiDescriptionFinder()
   at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase`1[[BookStore.Category.Samples.ISampleAppService, BookStore.Category.Application.Contracts, Version=0.1.0.0, Culture=neutral, PublicKeyToken=null]].BuildHttpProxyClientProxyContext(String methodName, ClientProxyRequestTypeValue arguments)
   at Volo.Abp.Http.Client.ClientProxying.ClientProxyBase`1.&lt;RequestAsync&gt;d__33`1[[BookStore.Category.Samples.ISampleAppService, BookStore.Category.Application.Contracts, Version=0.1.0.0, Culture=neutral, PublicKeyToken=null],[BookStore.Category.Samples.SampleDto, BookStore.Category.Application.Contracts, Version=0.1.0.0, Culture=neutral, PublicKeyToken=null]].MoveNext()
   at BookStore.Category.Samples.SampleClientProxy.GetAsync() in /Users/cangunaydin/dev/samples/BookStore/aspnet-core/modules/BookStore.Category/src/BookStore.Category.HttpApi.Client/ClientProxies/BookStore/Category/Samples/SampleClientProxy.Generated.cs:line 22
   --- End of inner exception stack trace ---
   at UIKit.UIApplication.UIApplicationMain(Int32 argc, String[] argv, IntPtr principalClassName, IntPtr delegateClassName) in /Users/builder/azdo/_work/1/s/xamarin-macios/src/UIKit/UIApplication.cs:line 58

It gets nullreference exception. probably it can not resolve ClientProxyApiDescriptionFinder. Then i realized probably this is related with autofac module, which i can not depend on since ios kernel not allowing it. (Always getting platform not supported exception) https://github.com/abpframework/abp/issues/10929

It seems like i stucked with this. I am sending you the sample project that i use. If you have some solution, i would like to hear about it. Right now, i wrote my own http client calls with regular HttpClient object. Though it would be very helpful to use the abp client proxies.

As a note, I use jetbrains rider on mac. When i first created avalonia project it created with target framework as .net7.0. Before i change the framework to .net8.0 I managed to make it work if i wasn't hallucinating :) probably it took .net standard2.0 dlls. But i couldn't make it work after i try to change it back to .net7.0 it was giving me runtime error afterwards. Weird behavior.

you can check your email.

Hello, I have solved it while i am preparing a minimal project :) Sometimes it is better to create it from scratch. Here is my findings and some questions if you can answer. I can also send the sample test project if you do not understand the questions just let me know.

So my problem was with the namespace. When i expose my services from the module i create "Controller" folder under httpapi project then set all folders under it here is a screenshot from my folder structure.

so i was trying to inject the isampleappservice from the application service namespace instead of controller namespace. And static generation is creating the isampleappservice for the controller namespace.

So the first question is if do not put my controller class under controller folder and namespace, it becomes ambiguous namespace for isampleappservice. Cause it is gonna be two isampleappservice comes from application.contracts and from generated folder. How can you fix that? Second question is about "With Contracts and Without Contracts" (https://docs.abp.io/en/abp/latest/API/Static-CSharp-API-Clients#client-proxy-generation) if i create my proxies without contracts first problem is solved. But i want to know downsides of it. Why isampleappservice is created at the first place with contracts? isn't the project referencing to application.contracts anyway? when you create your proxies "with contracts" then shouldn't you reference to application.contracts project? if you do not reference it, as i see it, it doesn't generate the dtos? how it is gonna be functional then?

As you can see i am little bit confused how should it be used. I want to create a nuget package that can be shared on my private repository since different ui platforms needs to access the backend. Any advice to do that? with or without contracts?

one more thing about the problem. My HttpApi Client module consists of multiple HttpApi Client modules. After i posted the previous message, i have tried with only one of them, then the exception go away, but this time i got another exception message. "no service for type IScreenAppService has been registered". So somehow it can not get the service from ioc container. But i can see the generated service. I couldn't understand what i am doing wrong.

Hello i changed the client module to static api but i am getting the same error. And the exception is the same. Do i do sth wrong over here? Is there any specific config that i need to do? To state the app that i use static proxies? Here is an overview of what i have done.

you can see the folder structure here for static proxies.

here is the client module code.

using Doohlink.CampaignManagement;
using Doohlink.ClientManagement;
using Doohlink.CreativeManagement;
using Doohlink.FtpServerManagement;
using Doohlink.InventoryManagement;
using Doohlink.OccupancyManagement;
using Microsoft.Extensions.DependencyInjection;
using Volo.Abp.Account;
using Volo.Abp.AuditLogging;
using Volo.Abp.FeatureManagement;
using Volo.Abp.Gdpr;
using Volo.Abp.Identity;
using Volo.Abp.LanguageManagement;
using Volo.Abp.Modularity;
using Volo.Abp.OpenIddict;
using Volo.Abp.PermissionManagement;
using Volo.Abp.SettingManagement;
using Volo.Abp.TextTemplateManagement;
using Volo.Abp.VirtualFileSystem;
using Volo.Saas.Host;
using Doohlink.MagicInfo;
using Volo.Payment;
using Volo.Payment.Admin;
using Doohlink.AdzupPlayerManagement;

namespace Doohlink;

[DependsOn(
    typeof(DoohlinkApplicationContractsModule),
    typeof(AbpIdentityHttpApiClientModule),
    typeof(AbpPermissionManagementHttpApiClientModule),
    typeof(AbpFeatureManagementHttpApiClientModule),
    typeof(AbpSettingManagementHttpApiClientModule),
    typeof(SaasHostHttpApiClientModule),
    typeof(AbpAuditLoggingHttpApiClientModule),
    typeof(AbpOpenIddictProHttpApiClientModule),
    typeof(AbpAccountAdminHttpApiClientModule),
    typeof(AbpAccountPublicHttpApiClientModule),
    typeof(LanguageManagementHttpApiClientModule),
    typeof(AbpGdprHttpApiClientModule),
    typeof(TextTemplateManagementHttpApiClientModule)
)]
[DependsOn(typeof(CreativeManagementHttpApiClientModule))]
    [DependsOn(typeof(CampaignManagementHttpApiClientModule))]
    [DependsOn(typeof(InventoryManagementHttpApiClientModule))]
    [DependsOn(typeof(ClientManagementHttpApiClientModule))]
    [DependsOn(typeof(OccupancyManagementHttpApiClientModule))]
    [DependsOn(typeof(FtpServerManagementHttpApiClientModule))]
    [DependsOn(typeof(MagicInfoHttpApiClientModule))]
    [DependsOn(typeof(AbpPaymentHttpApiClientModule))]
    [DependsOn(typeof(AbpPaymentAdminHttpApiClientModule))]
    [DependsOn(typeof(AdzupPlayerManagementHttpApiClientModule))]
    public class DoohlinkHttpApiClientModule : AbpModule
{
    public const string RemoteServiceName = "Default";

    public override void ConfigureServices(ServiceConfigurationContext context)
    {
        context.Services.AddStaticHttpClientProxies(
            typeof(DoohlinkApplicationContractsModule).Assembly,
            RemoteServiceName
        );

        Configure<AbpVirtualFileSystemOptions>(options =>
        {
            options.FileSets.AddEmbedded<DoohlinkHttpApiClientModule>();
        });
    }
}

and here how it is implemented on avalonia ui.

using Adzup.Player.Services;
using Adzup.Player.Utils;
using Doohlink;
using Microsoft.Extensions.DependencyInjection;
using Volo.Abp.Http.Client;
using Volo.Abp.Modularity;

namespace Adzup.Player;

[DependsOn(
    typeof(AdzupPlayerUtilsModule),
    typeof(DoohlinkHttpApiClientModule))]
public class AdzupPlayerModule:AbpModule
{
    public override void PreConfigureServices(ServiceConfigurationContext context)
    {
#if DEBUG
        
        PreConfigure<AbpHttpClientBuilderOptions>(options =>
        {
            options.ProxyClientBuildActions.Add((_, clientBuilder) =>
            {
                clientBuilder.ConfigurePrimaryHttpMessageHandler(HttpClientHelper.GetInsecureHandler);
            });
        });
#endif
    }
    public override void ConfigureServices(ServiceConfigurationContext context)
    {
        var configuration=context.Services.GetConfiguration();
        Configure<PlayerOptions>(configuration.GetSection(PlayerOptions.Player));
    }
}

and here how abp is initialized for avalonia.

using System.IO;
using System.Reflection;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.FileProviders;
using Serilog;
using Serilog.Events;
using Volo.Abp;
using Volo.Abp.Modularity;

namespace Adzup.Player;

public static class AbpBootstrapper
{
    public static IAbpApplicationWithInternalServiceProvider? AbpApplication { get; private set; }
    public static bool IsInitialized => AbpApplication != null;

    public static void InitializeIfNeeds<T>()
        where T : AbpModule
    {
        if (IsInitialized)
        {
            return;
        }

        AbpApplication = CreateAbpApplication<T>().ConfigureInstallationId();
        AbpApplication?.Initialize();
    }

    private static IAbpApplicationWithInternalServiceProvider? CreateAbpApplication<T>() where T : AbpModule
    {
        Log.Logger = new LoggerConfiguration()
            .MinimumLevel.Information()
            .MinimumLevel.Override("Microsoft", LogEventLevel.Warning)
            .MinimumLevel.Override("Volo.Abp", LogEventLevel.Warning)
#if DEBUG
            .MinimumLevel.Override("AbpWithAvalonia", LogEventLevel.Debug)
#else
                .MinimumLevel.Override("AbpWithAvalonia", LogEventLevel.Information)
#endif
            .Enrich.FromLogContext()
            .WriteTo.Console()
            .CreateLogger();

        var assembly = typeof(App).GetTypeInfo().Assembly;
        var configuration = new ConfigurationBuilder()
            .SetBasePath(Directory.GetCurrentDirectory())
            .AddEnvironmentVariables()
#if DEBUG
            .AddJsonFile(new EmbeddedFileProvider(assembly), "appsettings.debug.json", optional: true, false)
#else
            .AddJsonFile(new EmbeddedFileProvider(assembly), "appsettings.json", optional: true, false)
#endif
            .Build();
        var application = AbpApplicationFactory.Create<T>(options =>
        {
            options.Services.ReplaceConfiguration(configuration);
            // options.UseAutofac();
            options.Services.AddLogging(c => c.AddSerilog());
        });

        return application;
    }

    public static T? GetRequiredService<T>() where T : class
    {
        return AbpApplication?.Services.GetRequiredService<T>();
    }

    public static void ShutDown()
    {
        AbpApplication?.ShutdownAsync().GetAwaiter().GetResult();
        AbpApplication?.Dispose();
        AbpApplication = null;
    }
}

and i have this exception again when i try to resolve the appservice.

System.PlatformNotSupportedException: Dynamic code generation is not supported on this platform.
   at System.Reflection.Emit.AssemblyBuilder.ThrowDynamicCodeNotSupported()
   at System.Reflection.Emit.AssemblyBuilder.EnsureDynamicCodeSupported()
   at System.Reflection.Emit.RuntimeAssemblyBuilder..ctor(AssemblyName n, AssemblyBuilderAccess access)
   at System.Reflection.Emit.AssemblyBuilder.DefineDynamicAssembly(AssemblyName name, AssemblyBuilderAccess access)
   at Castle.DynamicProxy.ModuleScope.CreateModule(Boolean signStrongName)
   at Castle.DynamicProxy.ModuleScope.ObtainDynamicModuleWithWeakName()
   at Castle.DynamicProxy.ModuleScope.ObtainDynamicModule(Boolean isStrongNamed)
   at Castle.DynamicProxy.ModuleScope.DefineType(Boolean inSignedModulePreferably, String name, TypeAttributes flags)
   at Castle.DynamicProxy.Generators.Emitters.ClassEmitter.CreateTypeBuilder(ModuleScope moduleScope, String name, Type baseType, IEnumerable`1 interfaces, TypeAttributes flags, Boolean forceUnsigned)
   at Castle.DynamicProxy.Generators.Emitters.ClassEmitter..ctor(ModuleScope moduleScope, String name, Type baseType, IEnumerable`1 interfaces, TypeAttributes flags, Boolean forceUnsigned)
   at Castle.DynamicProxy.Generators.Emitters.ClassEmitter..ctor(ModuleScope moduleScope, String name, Type baseType, IEnumerable`1 interfaces)
   at Castle.DynamicProxy.Generators.BaseProxyGenerator.BuildClassEmitter(String typeName, Type parentType, IEnumerable`1 interfaces)
   at Castle.DynamicProxy.Generators.BaseInterfaceProxyGenerator.Init(String typeName, ClassEmitter& emitter, Type proxyTargetType, FieldReference& interceptorsField, IEnumerable`1 allInterfaces)
   at Castle.DynamicProxy.Generators.BaseInterfaceProxyGenerator.GenerateType(String typeName, INamingScope namingScope)
   at Castle.DynamicProxy.Generators.BaseProxyGenerator.&lt;&gt;c__DisplayClass13_0.&lt;GetProxyType&gt;b__0(CacheKey cacheKey)
   at Castle.Core.Internal.SynchronizedDictionary`2[[Castle.DynamicProxy.Generators.CacheKey, Castle.Core, Version=5.0.0.0, Culture=neutral, PublicKeyToken=407dd0808d44fbdc],[System.Type, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].GetOrAdd(CacheKey key, Func`2 valueFactory)
   at Castle.DynamicProxy.Generators.BaseProxyGenerator.GetProxyType()
   at Castle.DynamicProxy.DefaultProxyBuilder.CreateInterfaceProxyTypeWithoutTarget(Type interfaceToProxy, Type[] additionalInterfacesToProxy, ProxyGenerationOptions options)
   at Castle.DynamicProxy.ProxyGenerator.CreateInterfaceProxyTypeWithoutTarget(Type interfaceToProxy, Type[] additionalInterfacesToProxy, ProxyGenerationOptions options)
   at Castle.DynamicProxy.ProxyGenerator.CreateInterfaceProxyWithoutTarget(Type interfaceToProxy, Type[] additionalInterfacesToProxy, ProxyGenerationOptions options, IInterceptor[] interceptors)
   at Castle.DynamicProxy.ProxyGenerator.CreateInterfaceProxyWithoutTarget(Type interfaceToProxy, IInterceptor[] interceptors)
   at Microsoft.Extensions.DependencyInjection.ServiceCollectionHttpClientProxyExtensions.&lt;&gt;c__DisplayClass4_0.&lt;AddHttpClientProxy&gt;b__1(IServiceProvider serviceProvider)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitFactory(FactoryCallSite factoryCallSite, RuntimeResolverContext context)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2[[Microsoft.Extensions.DependencyInjection.ServiceLookup.RuntimeResolverContext, Microsoft.Extensions.DependencyInjection, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].VisitCallSiteMain(ServiceCallSite callSite, RuntimeResolverContext argument)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitDisposeCache(ServiceCallSite transientCallSite, RuntimeResolverContext context)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2[[Microsoft.Extensions.DependencyInjection.ServiceLookup.RuntimeResolverContext, Microsoft.Extensions.DependencyInjection, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].VisitCallSite(ServiceCallSite callSite, RuntimeResolverContext argument)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.Resolve(ServiceCallSite callSite, ServiceProviderEngineScope scope)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.RuntimeServiceProviderEngine.&lt;&gt;c__DisplayClass4_0.&lt;RealizeService&gt;b__0(ServiceProviderEngineScope scope)
   at Microsoft.Extensions.DependencyInjection.ServiceProvider.GetService(ServiceIdentifier serviceIdentifier, ServiceProviderEngineScope serviceProviderEngineScope)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.ServiceProviderEngineScope.GetService(Type serviceType)
   at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType)
   at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService[IScreenAppService](IServiceProvider provider)
   at Microsoft.Extensions.DependencyInjection.ServiceCollectionCommonExtensions.GetRequiredService[IScreenAppService](IServiceCollection services)
   at Adzup.Player.AbpBootstrapper.GetRequiredService[IScreenAppService]()
   at Adzup.Player.ViewModels.ConfigurationViewModel..ctor() in /Users/cangunaydin/projects/Adzup.Player/Adzup.Player/Adzup.Player/ViewModels/ConfigurationViewModel.cs:line 36
   at System.Reflection.MethodBaseInvoker.InterpretedInvoke_Constructor(Object obj, IntPtr* args)
   at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)
   at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitConstructor(ConstructorCallSite constructorCallSite, RuntimeResolverContext context)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2[[Microsoft.Extensions.DependencyInjection.ServiceLookup.RuntimeResolverContext, Microsoft.Extensions.DependencyInjection, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].VisitCallSiteMain(ServiceCallSite callSite, RuntimeResolverContext argument)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitRootCache(ServiceCallSite callSite, RuntimeResolverContext context)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2[[Microsoft.Extensions.DependencyInjection.ServiceLookup.RuntimeResolverContext, Microsoft.Extensions.DependencyInjection, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].VisitCallSite(ServiceCallSite callSite, RuntimeResolverContext argument)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.Resolve(ServiceCallSite callSite, ServiceProviderEngineScope scope)
   at Microsoft.Extensions.DependencyInjection.ServiceProvider.CreateServiceAccessor(ServiceIdentifier serviceIdentifier)
   at System.Collections.Concurrent.ConcurrentDictionary`2[[Microsoft.Extensions.DependencyInjection.ServiceLookup.ServiceIdentifier, Microsoft.Extensions.DependencyInjection, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60],[Microsoft.Extensions.DependencyInjection.ServiceProvider.ServiceAccessor, Microsoft.Extensions.DependencyInjection, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60]].GetOrAdd(ServiceIdentifier key, Func`2 valueFactory)
   at Microsoft.Extensions.DependencyInjection.ServiceProvider.GetService(ServiceIdentifier serviceIdentifier, ServiceProviderEngineScope serviceProviderEngineScope)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.ServiceProviderEngineScope.GetService(Type serviceType)
   at Volo.Abp.DependencyInjection.ConventionalRegistrarBase.&lt;&gt;c__DisplayClass10_0.&lt;CreateServiceDescriptor&gt;b__0(IServiceProvider provider)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitFactory(FactoryCallSite factoryCallSite, RuntimeResolverContext context)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2[[Microsoft.Extensions.DependencyInjection.ServiceLookup.RuntimeResolverContext, Microsoft.Extensions.DependencyInjection, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].VisitCallSiteMain(ServiceCallSite callSite, RuntimeResolverContext argument)
   at 

appservice is resolve like this in view model.

_screenAppService = AbpBootstrapper.GetRequiredService<IScreenAppService>()!;

hope you can point me into the right direction. thank you.

Showing 41 to 50 of 111 entries
Made with ❤️ on ABP v9.0.0-preview Updated on September 19, 2024, 10:13