Skip to content

fix(deps): restore toml-eslint-parser for CI deploy#2576

Open
waynesun09 wants to merge 1 commit into
mainfrom
fix-toml-dep
Open

fix(deps): restore toml-eslint-parser for CI deploy#2576
waynesun09 wants to merge 1 commit into
mainfrom
fix-toml-dep

Conversation

@waynesun09

Copy link
Copy Markdown
Member

Summary

Test plan

  • site-deploy workflow passes the "Patch wrangler.toml for CI" step

The CI deploy workflow (site-deploy.yml) runs
patch-wrangler-rate-limit-namespace-ids.mjs which imports
toml-eslint-parser. Commit 758ce3e removed it as "unused"
but only checked application/lint code, not CI scripts.

Assisted-by: Claude
Signed-off-by: Wayne Sun <gsun@redhat.com>
@qodo-code-review

Copy link
Copy Markdown

PR Summary by Qodo

Restore toml-eslint-parser dependency required by site-deploy CI script
🐞 Bug fix ⚙️ Configuration changes 🕐 Less than 10 minutes

Grey Divider

Description

• Restore toml-eslint-parser devDependency required by the wrangler.toml patch script.
• Unblock the site-deploy workflow step that patches wrangler.toml during deploys.
Diagram

graph TD
  A[["site-deploy.yml"]] --> B(("Patch wrangler.toml script")) --> C["wrangler.toml"]
  B --> D["toml-eslint-parser"]
  subgraph Legend
    direction LR
    _wf[["Workflow"]] ~~~ _scr(("Script")) ~~~ _cfg["Config/Dep"]
  end
Loading
High-Level Assessment

The following are alternative approaches to this PR:

1. Move parser to runtime dependencies
  • ➕ Avoids future CI breakage if tooling/scripts are overlooked during dependency pruning
  • ➕ Clarifies that deploy workflows rely on this package
  • ➖ Slightly expands runtime dependency surface even though it’s only used in CI/script paths
2. Replace with a simpler TOML library (e.g., @iarna/toml)
  • ➕ Potentially smaller dependency surface
  • ➕ More common TOML parsing API
  • ➖ Likely loses source-range preservation, risking formatting/comment churn in wrangler.toml edits
  • ➖ Would require script changes and additional testing
3. Vendor a minimal TOML patcher (regex/range-less)
  • ➕ No external parser dependency
  • ➖ Fragile against formatting changes and comments; higher maintenance burden
  • ➖ Higher risk of corrupting wrangler.toml in CI

Recommendation: Keep the current approach: restoring toml-eslint-parser is the smallest, lowest-risk fix that preserves the script’s source-range editing behavior. Consider adding a brief comment or CI check to prevent dependency pruning from removing packages imported by cloudflare_site/scripts/*.

Files changed (1) +1 / -0

Other (1) +1 / -0
package.jsonRe-add toml-eslint-parser devDependency for CI wrangler.toml patching +1/-0

Re-add toml-eslint-parser devDependency for CI wrangler.toml patching

• Adds 'toml-eslint-parser' back to 'devDependencies'. This restores the dependency required by 'cloudflare_site/scripts/patch-wrangler-rate-limit-namespace-ids.mjs', which runs during the site deploy workflow.

package.json

@qodo-code-review

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)

Grey Divider

Great, no issues found!

Qodo reviewed your code and found no material issues that require review

Grey Divider

Qodo Logo

@fullsend-ai-review

fullsend-ai-review Bot commented Jun 23, 2026

Copy link
Copy Markdown

🤖 Finished Review · ✅ Success · Started 5:12 PM UTC · Completed 5:15 PM UTC
Commit: 6fa766e · View workflow run →

@codecov

codecov Bot commented Jun 23, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@fullsend-ai-review

Copy link
Copy Markdown

Looks good to me


Labels: Restores a devDependency required by the CI site-deploy workflow.

@fullsend-ai-review fullsend-ai-review Bot added ready-for-merge All reviewers approved — ready to merge dependencies Pull requests that update a dependency file component/ci CI pipelines and checks labels Jun 23, 2026
@waynesun09 waynesun09 requested a review from ralphbean June 23, 2026 17:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

component/ci CI pipelines and checks dependencies Pull requests that update a dependency file ready-for-merge All reviewers approved — ready to merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant