posit-dev / posit-dev/positron

R debugger: Restart from debug controls disables breakpoints

Open
#15,533 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area: debugger bug lang: r support
Dominant language
TypeScript
Stars
4.3k
Forks
184
Avg merge
1d 11h
Merged PRs (30d)
206

Description

System details:

Positron and OS details:

Positron Version: 2026.08.1 (user setup) build 2
Code - OSS Version: 1.124.0
Commit: 48dc4cee686939f35fe4a714d34375f67fd62082
Date: 2026-08-09T13:35:16-06:00
Electron: 42.2.0
Chromium: 148.0.7778.97
Node.js: 24.15.0
V8: 14.8.178.14-electron.0
OS: Windows_NT x64 10.0.26200

Session details:

R 4.6.1

Describe the issue:

Breakpoints do not work after the Restart button in the debug mode controls is clicked

Steps to reproduce the issue:

  1. Add a breakpoint to any R script
  2. Go into debugging mode
  3. Click Restart in Debug controls
  4. R Session restarts
  5. Breakpoints are no longer activated -- both current and new breakpoints are ignored

Expected or desired behavior:

Breakpoints should work normally after restart.

The expected behavior does happen when I click the Restart button in the Console tab.

Were there any error messages in the UI, Output panel, or Developer Tools console?

This error appears when I click Restart in the Debug controls:

workbench.desktop.main.js:243747 Error: Cannot call write after a stream was destroyed
at _write (node:internal/streams/writable:489:11)
at Writable.write (node:internal/streams/writable:508:10)
at c:\Users\Charlie\AppData\Local\Programs\Positron\resources\app\extensions\positron-r\dist\extension.js:31:14061
at new Promise ()
at Gd.write (c:\Users\Charlie\AppData\Local\Programs\Positron\resources\app\extensions\positron-r\dist\extension.js:31:13982)
at ic.doWrite (c:\Users\Charlie\AppData\Local\Programs\Positron\resources\app\extensions\positron-r\dist\extension.js:3:1625)
at c:\Users\Charlie\AppData\Local\Programs\Positron\resources\app\extensions\positron-r\dist\extension.js:3:1524
$onExtensionRuntimeError @ workbench.desktop.main.js:243747
_doInvokeHandler @ workbench.desktop.main.js:935421
_invokeHandler @ workbench.desktop.main.js:935407
_receiveRequest @ workbench.desktop.main.js:935350
_receiveOneMessage @ workbench.desktop.main.js:935279
(anonymous) @ workbench.desktop.main.js:935151
_deliver @ workbench.desktop.main.js:4511
fire @ workbench.desktop.main.js:4536
fire @ workbench.desktop.main.js:253331
(anonymous) @ workbench.desktop.main.js:938874

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the failure with an R script breakpoint, using the Debug controls Restart button rather than the Console restart. Start by tracing the R debugger restart path around the reported stream error in the Positron R extension, then verify that existing and newly added breakpoints work after restart without the stream-destroyed error.

Written by the indexing model from the issue text.

Assessment

Tech stack
r, typescript
Domain
developer-experience, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.