microsoft / microsoft/vscode-java-debug
Refactor: Extract common code from LaunchRequestHandler's delegate
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 591
- Forks
- 429
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 19
Description
See ILaunchDelegate.java#L25-L27
CompletableFuture<Response> launchInTerminal(LaunchArguments launchArguments, Response response, IDebugAdapterContext context);
CompletableFuture<Response> launchInternally(LaunchArguments launchArguments, Response response, IDebugAdapterContext context);
There is common logic in implementation for both interfaces. The main differences in implementation for debug/noDebug are:
- launchInTerminal: It constructs different command string, and then take different actions according to response.
- launchInternally: It starts debuggee process in different ways.
Refactor work should be done to make code clean and readable.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with ILaunchDelegate.java at lines 25-27, then inspect the implementations of launchInTerminal and launchInternally in LaunchRequestHandler's delegate. Compare the shared logic and the debug/noDebug differences described in the issue; done means the common behavior is consolidated and the delegate remains readable without changing those distinct launch behaviors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- devtools
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100