Open agneszitte opened 1 month ago
@agneszitte can you try running Windows as Packaged instead
@agneszitte can you try running Windows as Packaged instead
@nickrandolph I am having this when trying to run Windows as Packaged
But it is not specific to the options used for this issue, I can reproduce it with a simple blank maui embedding app as well. So I entered a separate issue for it: https://github.com/unoplatform/uno.extensions/issues/2244
@agneszitte can you try running Windows as Packaged instead
@nickrandolph I am having this when trying to run Windows as Packaged !
But it is not specific to the options used for this issue, I can reproduce it with a simple blank maui embedding app as well. So I entered a separate issue for it: #2244
@Darsh0307 now that https://github.com/unoplatform/uno.extensions/issues/2244#top is supposed to be fixed, can you re-test for this issue with latest stable packages + latest stable template to see if you are still able to reproduce the issue for Windows (Unpackaged) and to test Windows (Packaged) please.
Message
System.InvalidOperationException: 'Operation is not valid due to the current state of the object.
Inner exception :- None
Exception :- stack trace
at WinRT.ExceptionHelpers.<ThrowExceptionForHR>g__Throw|39_0(Int32 hr)
at WinRT.ExceptionHelpers.ThrowExceptionForHR(Int32 hr)
at ABI.Windows.Storage.IApplicationDataStaticsMethods.get_Current(IObjectReference _obj)
at Windows.Storage.ApplicationData.get_Current()
at Uno.Extensions.Storage.KeyValueStorage.ApplicationDataKeyValueStorage..ctor(ILogger`1 Logger, InMemoryKeyValueStorage InMemoryStorage, KeyValueStorageSettings Settings, ISerializer Serializer)
at Uno.Extensions.Storage.KeyValueStorage.EncryptedApplicationDataKeyValueStorage..ctor(ILogger`1 EncryptedLogger, InMemoryKeyValueStorage InMemoryStorage, KeyValueStorageSettings Settings, ISerializer Serializer)
at Uno.Extensions.ServiceCollectionExtensions.<>c.<AddKeyedStorage>b__2_3(ILogger`1 l, InMemoryKeyValueStorage inmem, KeyValueStorageSettings settings, ISerializer s)
at Uno.Extensions.ServiceCollectionExtensions.CreateKeyValueStorage[TKeyValueStorage](IServiceProvider sp, String name, Func`5 creator)
at Uno.Extensions.ServiceCollectionExtensions.<>c.<AddKeyedStorage>b__2_1(IServiceProvider sp)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitFactory(FactoryCallSite factoryCallSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitDisposeCache(ServiceCallSite transientCallSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.Resolve(ServiceCallSite callSite, ServiceProviderEngineScope scope)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.DynamicServiceProviderEngine.<>c__DisplayClass2_0.<RealizeService>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[T](IServiceProvider provider)
at Uno.Extensions.DependencyInjection.NamedInstance`2.GetRequired()
at Uno.Extensions.ServiceCollectionExtensions.GetRequiredNamedService[TService](IServiceProvider sp, String Name)
at Uno.Extensions.DependencyInjection.NamedInstanceReference`1.GetRequired()
at Uno.Extensions.ServiceCollectionExtensions.GetRequiredNamedService[TService](IServiceProvider sp, String Name)
at Uno.Extensions.ServiceCollectionExtensions.GetRequiredDefaultInstance[TService](IServiceProvider sp)
at Uno.Extensions.HostBuilderExtensions.<>c.<UseAuthentication>b__3_1(IServiceProvider sp)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitFactory(FactoryCallSite factoryCallSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitRootCache(ServiceCallSite callSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitConstructor(ConstructorCallSite constructorCallSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitDisposeCache(ServiceCallSite transientCallSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.Resolve(ServiceCallSite callSite, ServiceProviderEngineScope scope)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.DynamicServiceProviderEngine.<>c__DisplayClass2_0.<RealizeService>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[T](IServiceProvider provider)
at Uno.Extensions.HostBuilderExtensions.<>c__DisplayClass2_0`2.<AddAuthentication>b__1(IServiceProvider sp)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitFactory(FactoryCallSite factoryCallSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitRootCache(ServiceCallSite callSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitIEnumerable(IEnumerableCallSite enumerableCallSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitRootCache(ServiceCallSite callSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitConstructor(ConstructorCallSite constructorCallSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitRootCache(ServiceCallSite callSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitConstructor(ConstructorCallSite constructorCallSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitDisposeCache(ServiceCallSite transientCallSite, RuntimeResolverContext context)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.Resolve(ServiceCallSite callSite, ServiceProviderEngineScope scope)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.DynamicServiceProviderEngine.<>c__DisplayClass2_0.<RealizeService>b__0(ServiceProviderEngineScope scope)
at Microsoft.Extensions.DependencyInjection.ServiceProvider.GetService(ServiceIdentifier serviceIdentifier, ServiceProviderEngineScope serviceProviderEngineScope)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.ServiceProviderEngineScope.GetService(Type serviceType)
at Uno.Extensions.Navigation.Navigators.ControlNavigator.<>c__DisplayClass8_0.<<CreateViewModel>b__0>d.MoveNext()
at Uno.Extensions.Navigation.Navigators.ControlNavigator.<CreateViewModel>d__8.MoveNext()
at Uno.Extensions.Navigation.Navigators.ControlNavigator`1.<InitializeCurrentView>d__9.MoveNext()
at Uno.Extensions.Navigation.Navigators.ControlNavigator`1.<ExecuteRequestAsync>d__8.MoveNext()
at Uno.Extensions.Navigation.Navigators.ControlNavigator.<ControlNavigateAsync>d__6.MoveNext()
at Uno.Extensions.Navigation.Navigators.ControlNavigator.<>c__DisplayClass4_0.<<ControlCoreNavigateAsync>b__0>d.MoveNext()
at System.Threading.Tasks.ValueTask`1.get_Result()
at Uno.Extensions.DispatcherExtensions.<>c__DisplayClass2_0`1.<<ExecuteAsync>b__0>d.MoveNext()
at System.Threading.Tasks.ValueTask`1.get_Result()
at Uno.Extensions.Dispatcher.<ExecuteAsync>d__4`1.MoveNext()
at System.Threading.Tasks.ValueTask`1.get_Result()
at Uno.Extensions.Navigation.Navigators.ControlNavigator.<ControlCoreNavigateAsync>d__4.MoveNext()
at Uno.Extensions.Navigation.Navigators.ControlNavigator.<CoreNavigateAsync>d__3.MoveNext()
at Uno.Extensions.Navigation.Navigator.<RegionNavigateAsync>d__37.MoveNext()
at Uno.Extensions.Navigation.Navigator.<NavigateAsync>d__22.MoveNext()
at Uno.Extensions.Navigation.FrameworkElementExtensions.<>c__DisplayClass1_1.<<HostAsync>b__6>d.MoveNext()
at Uno.Extensions.Navigation.FrameworkElementExtensions.<Startup>d__2.MoveNext()
at Uno.Extensions.ServiceProviderExtensions.<BuildAndInitializeHostAsync>d__5.MoveNext()
at Uno.Extensions.ApplicationBuilderExtensions.<NavigateAsync>d__0`1.MoveNext()
at TestCustomApp530dev19.App.<OnLaunched>d__9.MoveNext() in C:\Users\DarshPatel\Desktop\finalQA\TestCustomApp530dev19\TestCustomApp530dev19\App.xaml.cs:line 100
Enviournment :-
Templates :- Uno.Templates.5.3.0-dev.31.nupkg
"Uno.Sdk": "5.3.0-dev.315"
<UnoExtensionsVersion>4.2.0-dev.13</UnoExtensionsVersion>
<UnoToolkitVersion>5.2.0-dev.56</UnoToolkitVersion>
<UnoThemesVersion>4.2.0-dev.30</UnoThemesVersion>
<UnoCSharpMarkupVersion>5.3.0-dev.11</UnoCSharpMarkupVersion>
<!-- <WindowsSdkPackageVersion>10.0.22621.28</WindowsSdkPackageVersion> -->
The exception error is still same , even in the newest versions of 5.2 version. @agneszitte since the errorr message is same , should i add the exception error again ?
Uno.Templates.5.2.28
"Uno.Sdk": "5.2.83"
<UnoExtensionsVersion>4.1.14</UnoExtensionsVersion>
<UnoToolkitVersion>6.0.18</UnoToolkitVersion>
<UnoThemesVersion>5.0.13</UnoThemesVersion>
<UnoCSharpMarkupVersion>5.2.13</UnoCSharpMarkupVersion>
@agneszitte / @Darsh0307 what's the status on this?
@agneszitte / @Darsh0307 what's the status on this?
@Darsh0307 I moved this to your list last week. Can you re-test it with latest dev versions to give us an update, please
Sure @agneszitte , i will test this one. :)
The error is still there with same exception mentioned and all.
The App was created using CLi , The cli was
dotnet new unoapp -o TestCustomApp530dev19 -preset "recommended" -platforms "android" -platforms "ios" -platforms "maccatalyst" -platforms "windows" -auth "oidc" -theme-service -pwa False -maui -theme "material" -presentation "mvvm" -config -di -log "serilog" -nav "regions" -http -loc -tests "unit" -tests "ui" -toolkit -dsp -id "com.companyname.TestCustomApp530dev19" -pub "O=TestCustomApp530dev19"
Current behavior
Operation is not valid due to the current state of the object
occurs when launching the app for Windows when creating an app with latest template 5.3.0-dev.19 and using:Equivalent to these options in the wizard: (expand to see)
![image](https://github.com/unoplatform/uno.extensions/assets/16295702/0fecb06d-87ff-44a8-992e-2c10bf897b43)Exception details to expand:
``` e.Exception.Message: Operation is not valid due to the current state of the object. ``` ``` e.Exception.InnerException: null ``` ``` e.Exception.StackTrace: at WinRT.ExceptionHelpers.Expected behavior
No exception
How to reproduce it (as minimally and precisely as possible)
Create an app using these options with cli with latest template 5.3.0-dev.19:
Equivalent to these options in the wizard: (expand to see)
![image](https://github.com/unoplatform/uno.extensions/assets/16295702/0fecb06d-87ff-44a8-992e-2c10bf897b43)Try to launch the application for Windows
Notice the exception
Sample app used for the tests: TestCustomApp530dev19.zip
Environment
Affected platform(s):
Visual Studio: