Skip to content

fix(dashboard): clean up temp recording directory on close#40751

Merged
pavelfeldman merged 1 commit intomicrosoft:mainfrom
SebTardif:fix/dashboard-recording-dir-cleanup
May 9, 2026
Merged

fix(dashboard): clean up temp recording directory on close#40751
pavelfeldman merged 1 commit intomicrosoft:mainfrom
SebTardif:fix/dashboard-recording-dir-cleanup

Conversation

@SebTardif
Copy link
Copy Markdown
Contributor

@SebTardif SebTardif commented May 9, 2026

Summary

  • DashboardConnection creates a temp directory for recordings via mkdtempSync but never removes it when the connection closes
  • Clean up the directory in onclose to avoid orphaned temp files

Failure scenario: Each dashboard WebSocket connection creates a playwright-recordings-* temp directory. When the connection closes, individual stream files are cleaned up but the directory itself persists. On long-running servers with many dashboard sessions, this accumulates orphaned directories in the system temp folder.

Origin: The recording directory was introduced in #40279 (2026-04-17) by Pavel Feldman.

DashboardConnection creates a temp directory for recordings via
mkdtempSync but never removes it when the connection closes. Clean
up the directory in onclose to avoid orphaned temp files.

Signed-off-by: Sebastien Tardif <sebtardif@ncf.ca>
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 9, 2026

Test results for "MCP"

1 failed
❌ [webkit] › mcp/annotate.spec.ts:137 › should abort MCP annotation when last screenshot is removed @mcp-windows-latest-webkit

7043 passed, 1068 skipped


Merge workflow run.

@pavelfeldman pavelfeldman merged commit 4d09792 into microsoft:main May 9, 2026
16 of 17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants