Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

A staging folder that fails to delete is reused by the next update

Open
#170 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
75/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
javascript, node.js
Domain
backend, testing

Research direction

Start with packages/builder-server/src/services/themeUpdateService.js, especially recoverInterruptedUpdate and the prepare failure, language-folder refusal, and post-swap cleanup paths around the referenced lines. Trace how the staging folder is removed and prepared, then inspect the relevant tests and add one that makes stage removal fail. Done means a run never prepares into a stage it did not create, and cleanup failure on the refusal path is reported.

Written by the indexing model from the issue text.

Description

bug

If a theme update can't delete its temporary folder, the next update can pick up stale files from it.


Every removal of .theme-update-stage/ swallows its error (themeUpdateService.js ~263 in recoverInterruptedUpdate, ~436/~442 in the prepare failure and the language-folder refusal, ~491/~502 after the swap). If one fails, the next run's ensureDir reuses the folder and fs.copy merges into it, so leftover staged files (an old collection folder, a stale asset) can be swapped into the project or cause a false refusal; the refusal also returns its 409 as if the stage were gone. Pre-existing pattern; found by reading the code, not reproduced.

Suggested: at the start of a run, remove the stage without swallowing the error and refuse with the usual "could not be prepared" message if it is still there; on the refusal path, report a cleanup failure instead of the clean 409.

Done when: A run never prepares into a stage it did not create, with a test that makes the stage removal fail.

Start: themeUpdateService.js. Source: 2026-10-18 Codex review of 29289f67..6344ab5c.

Dominant language
JavaScript
Stars
162
Forks
6
Avg merge
12h 55m
Merged PRs (30d)
2

Getting set up

  • Ships a Dockerfile or Docker Compose file
  • No pull request template
  • No 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.

More from tsiger/widgetizer

All issues in tsiger/widgetizer

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.