-
Notifications
You must be signed in to change notification settings - Fork 3.3k
Adding code changes to integrate codeQL tool into pipeline #769
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
Changes from all commits
c75c83e
fc38338
11feafa
854c3a5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,49 @@ | ||||||
| name: "CodeQL Analysis" | ||||||
|
|
||||||
| on: | ||||||
| workflow_dispatch: | ||||||
| push: | ||||||
| branches: [ "main", "release/*" ] | ||||||
| pull_request: | ||||||
| branches: [ "main", "release/*" ] | ||||||
|
|
||||||
| jobs: | ||||||
| analyze: | ||||||
| name: Analyze (C#) | ||||||
| runs-on: windows-latest | ||||||
| timeout-minutes: 120 | ||||||
|
|
||||||
| permissions: | ||||||
| actions: read | ||||||
| contents: read | ||||||
| security-events: write | ||||||
|
|
||||||
| strategy: | ||||||
| fail-fast: false | ||||||
|
|
||||||
| steps: | ||||||
| - name: Checkout repository | ||||||
| uses: actions/checkout@v4 | ||||||
|
|
||||||
| - name: Setup .NET SDK | ||||||
| uses: actions/setup-dotnet@v4 | ||||||
| with: | ||||||
| global-json-file: global.json | ||||||
|
|
||||||
| - name: Initialize CodeQL | ||||||
| uses: github/codeql-action/init@v4 | ||||||
| with: | ||||||
|
Comment on lines
+25
to
+35
|
||||||
| languages: csharp | ||||||
| queries: security-extended | ||||||
|
|
||||||
| - name: Restore NuGet packages | ||||||
| run: | | ||||||
| dotnet restore WPFSamples.sln | ||||||
laxmikanth-msft marked this conversation as resolved.
Show resolved
Hide resolved
|
||||||
|
|
||||||
| - name: Build solution | ||||||
| run: dotnet build WPFSamples.sln --configuration Release --no-restore /p:Platform="Any CPU" /p:LangVersion=latest /p:TreatWarningsAsErrors=false | ||||||
|
||||||
| run: dotnet build WPFSamples.sln --configuration Release --no-restore /p:Platform="Any CPU" /p:LangVersion=latest /p:TreatWarningsAsErrors=false | |
| run: dotnet build WPFSamples.sln --configuration Release --no-restore /p:Platform="Any CPU" /p:TreatWarningsAsErrors=false |
Copilot
AI
Feb 18, 2026
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.
The build step is marked continue-on-error: true, which can allow the workflow to succeed even when the solution fails to compile. For compiled-language CodeQL analysis this can result in an incomplete/empty database and misleading “successful” security scanning. Consider removing continue-on-error, or explicitly handling build failures (e.g., fail the job or gate analysis on a successful build).
| continue-on-error: true |
Uh oh!
There was an error while loading. Please reload this page.