vscode: contributes.breakpoints support providing language as a document selector

Hi,

I’m developing a debug adapter for assembler files. I have a contribute section in package.json which allows to set breakpoint in various files (extensions). Everything is working as expected when I debug the debug-adapter. I.e. I can set breakpoints in .asm files. But when I create a package (vsix) and install it in vscode I’m not able to set breakpoints anymore in .asm files.

Here is the json:

"contributes": {
		"languages": [
			{
				"id": "asm-collection",
				"extensions": [
					".list",
					".a80",
					".asm",
					".inc",
					".s"
				],
				"aliases": [
					"Assembler file"
				]
			}
		],
		"breakpoints": [
			{
				"language": "asm-collection"
			}
		],
		"commands": [],

I’m still able to set breakpoints in .list files but not in .asm files.

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Comments: 16 (10 by maintainers)

Most upvoted comments

Sorry to hear that. Please re-consider your decision. The reason why this does not get so many upvotes is that the current way of selection seems to work unless you install another extension which uses similar file extensions. And the other problem is that there is no language defined for assembler and the developer has to do it himself. So for all the other extension provider developers there is no problem. Only for the assembler extensions. And the real bad thing is: there is not any usable workaround. The one described here works only partly and disables functionality in the other extension which is also not a good idea. The simplest way would be to provide a language ID for assembler. This, I guess, shouldn’t be too much effort.

It simply does not make sense to me to develop for vscode (and I love to do that) if the extension cannot be used by anyone afterwards. It’s very common to install several extensions for one language, e.g. I need another extension for highlighting. Now I have to decide: Do I want to have syntax highlighting or do I want to use my debug-adapter.