_WATCH_ section does not display values for variables available in the scope.
To Reproduce Steps to reproduce the behavior:
Scala program with some values definedscala program in _DEBUG_ modeVariables added in the _WATCH_ section should have values.
Screenshots

The same program in Intellij IDEA

Installation:
metals.serverVersion) 0.8.0Additional context
Maybe it is related to App usage in program.
Search terms
metals, debug, watch
@vadeg watch is currently not implemented and is connected to the DAP extension here: https://microsoft.github.io/debug-adapter-protocol/specification#Requests_Evaluate
Value from the object can be seen inside the this value, but it should also be outside, which I believe is a bug.
To summarize: "watch" functionality is not yet implemented so the watch expressions won't be evaluated, hence the an implementation is missing log. What we probably should do is to provide more informative information like evaluation of expression is not implemented.
As to the other part:
Value from the object can be seen inside the this value, but it should also be outside, which I believe is a bug.
It is not a bug, but rather a reflection of how the App is implemented. We can see the same behavior in IntelliJ on the screenshot above: only this variable is in scope (and two watches but they are not related) - we could probably provide some custom handling to "extract" the variables to the outer scope for Apps but I don't think it is worth the effort. Once we have expression evaluation, user will be able to "watch" the fields of interest.
Thanks @marek1840 ! I will close it since it's working as intended.
Most helpful comment
To summarize: "watch" functionality is not yet implemented so the watch expressions won't be evaluated, hence the
an implementation is missinglog. What we probably should do is to provide more informative information likeevaluation of expression is not implemented.As to the other part:
It is not a bug, but rather a reflection of how the
Appis implemented. We can see the same behavior inIntelliJon the screenshot above: onlythisvariable is in scope (and two watches but they are not related) - we could probably provide some custom handling to "extract" the variables to the outer scope forApps but I don't think it is worth the effort. Once we have expression evaluation, user will be able to "watch" the fields of interest.