Calling GetService in Package constructors is a common place for failures - there's no guarantee that the service provider will be properly set up by the time the Package is created.
Instead, the GetService call should be done in Initialize (or InitializeAsync, after switching to the main thread).
Calling GetService in Package constructors is a common place for failures - there's no guarantee that the service provider will be properly set up by the time the Package is created.
Instead, the GetService call should be done in Initialize (or InitializeAsync, after switching to the main thread).