Skip to content

Extend ISourceLookUpProvider to be able to specify whether the source is Local (VSCode) or Remote(DAP Server) - #515

Merged
Jinbo Wang (testforstephen) merged 2 commits into
microsoft:mainfrom
VladimirMakaev:remote-and-local-sources
Jan 8, 2024
Merged

Extend ISourceLookUpProvider to be able to specify whether the source is Local (VSCode) or Remote(DAP Server) #515
Jinbo Wang (testforstephen) merged 2 commits into
microsoft:mainfrom
VladimirMakaev:remote-and-local-sources

Conversation

@VladimirMakaev

Copy link
Copy Markdown
Contributor

Context

I'm building a DAP server based on core package. I.e. without eclipse plugin. Currently it's impossible to set "sourceReference" when returning types in "stacktrace" request.

Having a distinction between Local and Remote sources allows an implementation of ISourceLookUpProvider to instruct the underlying request handlers whether a follow up with "source" request and have it served via getSourceContents

This is also ABI compatible with whoever could implement ISourceLookUpProvider already as current logic is identical to SourceType.Local

Test Plan

I've tested this works with my DAP server

@VladimirMakaev

Copy link
Copy Markdown
Contributor Author

This should address #259 without breaking changes in current extension, allowing to have a custom implementation of ISourceLookUpProvider as a solution

@testforstephen
Jinbo Wang (testforstephen) merged commit f8da9e2 into microsoft:main Jan 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants