Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WinUi3: protocol activation will result in app being listed twice within application picker #3658

Open
TomPMoleman opened this issue Jun 1, 2023 · 0 comments

Comments

@TomPMoleman
Copy link

TomPMoleman commented Jun 1, 2023

Describe the bug

Upon trying to use protocol activation, the registered application will be listed twice within the application picker:

image

Please note, that (like the screenshot above depicts this behaviour as well) the app will be listed twice (I'd even expect the app to open directly if no other app would be registered to foo-URIs).
Also selecting the first entry will result in the app crashing (attached you may find the coresponding event viewer entry):

<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
  <System>
    <Provider Name="Application Error" Guid="{a0e9b465-b939-57d7-b27d-95d8e925ff57}" /> 
    <EventID>1000</EventID> 
    <Version>0</Version> 
    <Level>2</Level> 
    <Task>100</Task> 
    <Opcode>0</Opcode> 
    <Keywords>0x8000000000000000</Keywords> 
    <TimeCreated SystemTime="2023-06-01T11:56:29.5562202Z" /> 
    <EventRecordID>27204</EventRecordID> 
    <Correlation /> 
    <Execution ProcessID="38224" ThreadID="23432" /> 
    <Channel>Application</Channel> 
    <Computer>[...]</Computer> 
    <Security UserID="S-1-5-21-4151127132-1348399775-1926067535-1906" /> 
  </System>
  <EventData>
    <Data Name="AppName">CsWinUiDesktopActivation.exe</Data> 
    <Data Name="AppVersion">1.0.0.0</Data> 
    <Data Name="AppTimeStamp">641cef7e</Data> 
    <Data Name="ModuleName">KERNELBASE.dll</Data> 
    <Data Name="ModuleVersion">10.0.22621.1635</Data> 
    <Data Name="ModuleTimeStamp">61869dd2</Data> 
    <Data Name="ExceptionCode">e0434352</Data> 
    <Data Name="FaultingOffset">000000000006536c</Data> 
    <Data Name="ProcessId">0x4604</Data> 
    <Data Name="ProcessCreationTime">0x1d99480196e1093</Data> 
    <Data Name="AppPath">[...]\CsWinUiDesktopActivation\CsWinUiDesktopActivation\bin\x64\Debug\net6.0-windows10.0.22621.0\win10-x64\AppX\CsWinUiDesktopActivation.exe</Data> 
    <Data Name="ModulePath">C:\Windows\System32\KERNELBASE.dll</Data> 
    <Data Name="IntegratorReportId">91a04720-c552-4b42-839e-902acfcdd259</Data> 
    <Data Name="PackageFullName">3db72dc6-275d-4a24-a650-d6df0eb69cbe_1.0.0.0_x64__s9y1p3hwd5qda</Data> 
    <Data Name="PackageRelativeAppId">App</Data> 
  </EventData>
</Event>

Steps to reproduce the bug

Can easily be reproduced using the linked sample.
Simply deploy app (in my case i was exchanging it for a single-project-with-included-packaging self-contained app) and try to open a foo://test link (since sample is registering itself to be listening to URIs using the foo-protocol).

Expected behavior

The app should not be listed twice (I would not bother much if BOTH entries would actually work though!) and just for other activation types (e.g. file activation) the app should automatically start if it is the only one registered to that URI protocol.

Screenshots

No response

NuGet package version

Windows App SDK 1.3.1: 1.3.230502000

Packaging type

Packaged (MSIX)

Windows version

Windows 11 version 22H2 (22621, 2022 Update)

IDE

Visual Studio 2022

Additional context

Tested with 'self-contained' app.
Also, the version does not matter (while porting the UWP app to WinUi3, misc. WindowsAppSdk versions (ranging from 1.1/1.2 to 1.3.1) had been used, all exposed the very same error behaviour).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants