You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the file does not exist on disk it is an untitled:// file in our system. Since it has an associated path, it is save to save it without user interaction (we just take the path the user wanted). Not sure about having an untitled file open without associated path (saving here would trigger a dialog).
In both cases, it is an interesting scenario to allow to debug from an untitled file.
Benjamin Pasero (@bpasero) so I can easily change the textFileService to saveAll including untitled files here
However this uncovers some weird issue in the workbench. Namely follow Sean's steps and after the change to save all untitled files now debugging nicely starts but the workbench hides the file and it can not be seen anywhere.
Gif attached, no errors in console, notice how the program is successfully ran in the debug console
Isidor Nikolic (@isidorn) maybe better to not save all but just the current active file? what about executing the command workbench.action.files.save and then starting debug?
Benjamin Pasero (@bpasero) executing 'workbench.action.files.save ' did the trick.
However in the untitiled file the save dialog appears and no debug is started, this is because the promise probably does not nicely flow from the save dialog. Though the experience is still fine, when the user hits f5 for the second time he starts debugging.
Activity
bpasero commentedon Jan 26, 2017
If the file does not exist on disk it is an
untitled://file in our system. Since it has an associated path, it is save to save it without user interaction (we just take the path the user wanted). Not sure about having an untitled file open without associated path (saving here would trigger a dialog).In both cases, it is an interesting scenario to allow to debug from an untitled file.
isidorn commentedon Feb 1, 2017
Benjamin Pasero (@bpasero) so I can easily change the textFileService to saveAll including untitled files here
However this uncovers some weird issue in the workbench. Namely follow Sean's steps and after the change to save all untitled files now debugging nicely starts but the workbench hides the file and it can not be seen anywhere.
Gif attached, no errors in console, notice how the program is successfully ran in the debug console

bpasero commentedon Feb 1, 2017
Isidor Nikolic (@isidorn) maybe better to not save all but just the current active file? what about executing the command
workbench.action.files.saveand then starting debug?isidorn commentedon Feb 1, 2017
Benjamin Pasero (@bpasero) executing
'workbench.action.files.save 'did the trick.However in the untitiled file the save dialog appears and no debug is started, this is because the promise probably does not nicely flow from the save dialog. Though the experience is still fine, when the user hits f5 for the second time he starts debugging.
Sean's use case works perfectly now
bpasero commentedon Feb 1, 2017
Yeah, its a bit fragile. Let's see how it goes and wait for bugs.
isidorn commentedon Mar 8, 2017
After discussions we have decided to revert this behavior since it introduced some unexpected consequences - as seen by the issues linked
debug: before starting debug save all files via workbench command