Skip to content

Debug console is not logging stdout and stderr immediately anymore, only once it encounters a newline #181785

Closed
microsoft/vscode-js-debug
#1768
@rotemdan

Description

Does this issue occur when all extensions are disabled?: Yes

Version info:

Version: 1.79.0-insider (user setup)
Commit: 2c73d2651cc525b27fc697b820743098a204ec01
Date: 2023-05-04T22:11:08.187Z
Electron: 22.4.8
Chromium: 108.0.5359.215
Node.js: 16.17.1
V8: 10.8.168.25-electron.0
OS: Windows_NT x64 10.0.19045
Sandboxed: Yes

No extensions installed. Default settings.

Steps to Reproduce:

test.js:

process.stdout.write("Hello")

setTimeout(() => {
	process.stdout.write(" World!\n")
}, 5000)

.vscode/launch.json:

{
	"version": "0.2.0",
	"configurations": [
		{
			"type": "node",
			"request": "launch",
			"name": "Launch Program",
			"skipFiles": [
				"<node_internals>/**"
			],
			"program": "${workspaceFolder}\\test.js",
			"outputCapture": "std"
		}
	]
}

Expected behavior: The debug console should print "Hello" immediately, and after 5 seconds, print " World!".

Observed behavior: The entire string "Hello World!" is printed after a 5 second delay.

Immediate logging of stdout and stderr used to work in the debug console as long as I remember it. I suspect the problem started on the April 2023 release (or slightly earlier?). I don't know what caused this.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Labels

bugIssue identified by VS Code Team member as probable bugdebugDebug viewlet, configurations, breakpoints, adapter issues

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions