-
Notifications
You must be signed in to change notification settings - Fork 0
refactor: Refactor SQL project detection to prioritize SDK attribute over MSBuild properties #58
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Co-authored-by: JerrettDavis <2610199+JerrettDavis@users.noreply.github.com>
Co-authored-by: JerrettDavis <2610199+JerrettDavis@users.noreply.github.com>
Co-authored-by: JerrettDavis <2610199+JerrettDavis@users.noreply.github.com>
Co-authored-by: JerrettDavis <2610199+JerrettDavis@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Refactor SQL project detection logic
Refactor SQL project detection to prioritize SDK attribute over MSBuild properties
Jan 5, 2026
JerrettDavis
approved these changes
Jan 5, 2026
Contributor
Code Coverage |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #58 +/- ##
==========================================
+ Coverage 79.94% 87.01% +7.07%
==========================================
Files 50 51 +1
Lines 3350 3373 +23
Branches 455 459 +4
==========================================
+ Hits 2678 2935 +257
+ Misses 487 438 -49
+ Partials 185 0 -185
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The documentation stated that SQL project detection relied on MSBuild properties (
$(DSP),$(SqlServerVersion)). Modern SDK-based projects declare their SDK in the project file'sSdkattribute, making property-based detection indirect and fragile.Changes
New
DetectSqlProjectMSBuild task:Microsoft.Build.SqlandMSBuild.Sdk.SqlProjSqlProjectDetectorclass with proper XML parsingUpdated
_EfcptDetectSqlProjecttarget:BeforeCleantrigger (detection unnecessary during clean)UsingTaskdeclarationUpdated documentation:
Example
Before (property-only detection):
After (SDK-first detection):
Both SDK formats are detected:
<Project Sdk="MSBuild.Sdk.SqlProj/3.3.0"><Sdk Name="Microsoft.Build.Sql" Version="2.0.0" />Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
invalid/usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/work/JD.Efcpt.Build/JD.Efcpt.Build/tests/JD.Efcpt.Build.Tests/bin/Debug/net10.0/JD.Efcpt.Build.Tests.runtimeconfig.json --depsfile /home/REDACTED/work/JD.Efcpt.Build/JD.Efcpt.Build/tests/JD.Efcpt.Build.Tests/bin/Debug/net10.0/JD.Efcpt.Build.Tests.deps.json /home/REDACTED/work/JD.Efcpt.Build/JD.Efcpt.Build/tests/JD.Efcpt.Build.Tests/bin/Debug/net10.0/testhost.dll --port 33389 --endpoint 127.0.0.1:033389 --role client --parentprocessid 4526 --telemetryoptedin false(dns block)/usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/work/JD.Efcpt.Build/JD.Efcpt.Build/tests/JD.Efcpt.Build.Tests/bin/Debug/net10.0/JD.Efcpt.Build.Tests.runtimeconfig.json --depsfile /home/REDACTED/work/JD.Efcpt.Build/JD.Efcpt.Build/tests/JD.Efcpt.Build.Tests/bin/Debug/net10.0/JD.Efcpt.Build.Tests.deps.json /home/REDACTED/work/JD.Efcpt.Build/JD.Efcpt.Build/tests/JD.Efcpt.Build.Tests/bin/Debug/net10.0/testhost.dll --port 41845 --endpoint 127.0.0.1:041845 --role client --parentprocessid 11451 --telemetryoptedin false --log-format eacc1a72d25a6053/var/lib/postgresql/data b26/log.json(dns block)www.example.com/opt/oracle/product/21c/dbhomeXE/bin/oracle oracleXE (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq))) ace/log.json d-dispatcher/offfsync=off 622d�� 6b728eb90c5e6445full_page_writes=off e398e5f38a8fc3be-c e398e5f38a8fc3besynchronous_commit=off e398e5f38a8fc3bebash(dns block)/opt/oracle/product/21c/dbhomeXE/bin/oracle oracleXE (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq))) json a2b/log.json /usr�� ntime.v2.task/mo/run/containerd/io.containerd.runtime.v2.task/moby/51e1ad50ae6855ebae4b471671583xe_mz02_XE y 025db50685ac056e152a6df3bf00347dce7/log.json 5ebae4b471671583ln --log-format json 445/log.json a2b/��(dns block)/opt/oracle/product/21c/dbhomeXE/bin/oracle oracleXE (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq))) 445/log.json es(dns block)If you need me to access, download, or install something from one of these locations, you can either:
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.