From c21e9498d43637d14b50aa662cb8501363860f53 Mon Sep 17 00:00:00 2001 From: David Rogers Date: Thu, 6 Jun 2024 18:14:47 -0500 Subject: [PATCH] respond to "source" requests with "MethodNotFound" --- luceedebug/src/main/java/luceedebug/DapServer.java | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/luceedebug/src/main/java/luceedebug/DapServer.java b/luceedebug/src/main/java/luceedebug/DapServer.java index 24fb1ce..4539daa 100644 --- a/luceedebug/src/main/java/luceedebug/DapServer.java +++ b/luceedebug/src/main/java/luceedebug/DapServer.java @@ -183,6 +183,17 @@ public CompletableFuture initialize(InitializeRequestArguments arg return CompletableFuture.completedFuture(c); } + /** + * https://github.com/softwareCobbler/luceedebug/issues/50 + */ + @Override + public CompletableFuture source(SourceArguments args) { + final var exceptionalResult = new CompletableFuture(); + final var error = new ResponseError(ResponseErrorCode.MethodNotFound, "'source' requests are not supported", null); + exceptionalResult.completeExceptionally(new ResponseErrorException(error)); + return exceptionalResult; + } + private IPathTransform mungeOnePathTransform(Map map) { var maybeIdePrefix = map.get("idePrefix");