mirror of
https://github.com/zed-industries/zed.git
synced 2026-11-19 06:59:22 +01:00
debugger: Fix CodeLLDB schema validation for build-inferred configurations (#64133)
## Summary Fix the false CodeLLDB schema warnings reported in the linked issue. - Allow configurations with `build` to omit `request`. - Apply launch/attach target checks only when `request` is present, preserving target requirements for explicit requests even when `build` is provided. No debugger runtime behavior changes. Closes #64132 ## Validation I created a tiny project with debug configuration following the guidance, and turns out the build with the fix does not report issues any more. Thus I consider that the fix is working properly. ### Before: Zed reports 3 issues <img width="1022" height="720" alt="Image" src="https://github.com/user-attachments/assets/d42e5656-0b6c-4c25-b3ce-c991305902ba" /> ### After: Zed reports no issues <img width="1500" height="642" alt="Image" src="https://github.com/user-attachments/assets/0bf4d05f-6e58-410e-8ae6-450763a2a48c" /> Release Notes: - Fixed false missing-property warnings for CodeLLDB debug configurations using build-based target inference. --------- Co-authored-by: dino <dinojoaocosta@gmail.com>
This commit is contained in:
@@ -280,10 +280,14 @@ impl DebugAdapter for CodeLldbDebugAdapter {
|
||||
"default": false
|
||||
}
|
||||
},
|
||||
"required": ["request"],
|
||||
"anyOf": [
|
||||
{ "required": ["request"] },
|
||||
{ "required": ["build"] }
|
||||
],
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
"required": ["request"],
|
||||
"properties": {
|
||||
"request": {
|
||||
"enum": ["launch"]
|
||||
@@ -303,6 +307,7 @@ impl DebugAdapter for CodeLldbDebugAdapter {
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"required": ["request"],
|
||||
"properties": {
|
||||
"request": {
|
||||
"enum": ["attach"]
|
||||
|
||||
Reference in New Issue
Block a user