We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Given the following csproj,
<Project> <Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk" /> <PropertyGroup> <OutputType>Exe</OutputType> <TargetFramework>net9.0</TargetFramework> <ImplicitUsings>enable</ImplicitUsings> <Nullable>enable</Nullable> </PropertyGroup> <Import Project="Sdk.targets" Sdk="Microsoft.NET.Sdk" /> </Project>
Autobuild only looks at the root <Project> node and sees that it does not have an Sdk attribute, and subsequently incorrectly identifying that it is not compatible and switches to building using Mono. This way of writing SDK-style projects, specifically using <Import /> explicitly, is documented here https://learn.microsoft.com/en-us/visualstudio/msbuild/how-to-use-project-sdk?view=vs-2022#use-the-import-element-anywhere-in-your-project
<Project>
Sdk
<Import />
I believe that the code which identifies whether a project is compatible is located here https://github.com/github/codeql/blob/main/csharp/autobuilder/Semmle.Autobuild.Shared/Project.cs#L50
I have set up a repository which reproduces this issue https://github.com/Arthri/NonStdSdkAutobuild/
The text was updated successfully, but these errors were encountered:
Thank you for reporting this! And thank you for the entry points - this is much appreciated! I will look into this!
Sorry, something went wrong.
Issue will be fixed here: #19289
PR merged.
Thank you for looking into the issue and fixing it!
michaelnebel
No branches or pull requests
Given the following csproj,
Autobuild only looks at the root
<Project>
node and sees that it does not have anSdk
attribute, and subsequently incorrectly identifying that it is not compatible and switches to building using Mono. This way of writing SDK-style projects, specifically using<Import />
explicitly, is documented here https://learn.microsoft.com/en-us/visualstudio/msbuild/how-to-use-project-sdk?view=vs-2022#use-the-import-element-anywhere-in-your-projectI believe that the code which identifies whether a project is compatible is located here
https://github.com/github/codeql/blob/main/csharp/autobuilder/Semmle.Autobuild.Shared/Project.cs#L50
I have set up a repository which reproduces this issue https://github.com/Arthri/NonStdSdkAutobuild/
The text was updated successfully, but these errors were encountered: