-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Fix incorrect apphost being used when publishing for self-contained single-file with NoBuild=true
#45159
Fix incorrect apphost being used when publishing for self-contained single-file with NoBuild=true
#45159
Conversation
Workaround for SDK 9.0.100 users from @am11 in #45060 (comment) - add to the project file: <Target Name="_WorkaroundIncorrectAppHost" BeforeTargets="_GetComHostPaths">
<CallTarget Targets="_GetAppHostCreationConfiguration" />
</Target> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great, thanks a lot!
@dsplaisted The build analysis check is red, but only showing a known test error (the linked timeout issue). Is there something I'm missing here that is being flagged as failing / needing investigation? |
@elinor-fung No, we have a bunch of 9.0.2xx PRs that are failing due to this issue, which we are trying to investigate and fix. Right now I don't think 9.0.2xx changes are too urgent to merge. If we have to, we will either start merging on red or disable the CI leg that's failing. Thanks! |
Because this impacts source-build users pretty significantly I think we should request a backported servicing fix once this is merged. |
Rerunning to see if that timeout goes away for now. I dont think its related to your change. |
@marcpopMSFT I think this is pretty important and I would approve to merge on red if I had permission. We still have some time in Jan (like 2 weeks) so it's probably not necessary yet, but we should keep an eye out on this PR. |
Failures are known issues and want to prep this for customer feedback |
/backport to release/9.0.1xx |
Started backporting to release/9.0.1xx: https://github.com/dotnet/sdk/actions/runs/12262753536 |
The
_GetAppHostCreationConfiguration
target sets the_UseSingleFileHostForPublish
property, which determines if we (re-)create the app usingsinglefilehost
on publish. When publishing withNoBuild=true
, the target was not being run, so we bundled usingapphost
, resulting in an app that was configured to be self-contained but did not actually have the runtime as part of itself.This change chains the target into the computation for output paths to ensure that the target runs when publishing without building, so that the correct host is used.
See https://developercommunity.visualstudio.com/t/Single-file-self-contained-failing-after/10794374