Skip to content

[eslint-monster] actions/setup/js regex and API-safety mechanical lint slice #54637

Description

@github-actions

Summary

Daily npm run lint:setup-js surfaced a concentrated regex, duplication, and API-safety cleanup slice across actions/setup/js. This group clusters repeated interpolation hygiene, HTTP callback safety, redundant core.error() usage, and a few contained mechanical fixes.

Affected files

  • actions/setup/js/add_mask_redaction.cjs
  • actions/setup/js/add_reaction.cjs
  • actions/setup/js/add_reaction_and_edit_comment.cjs
  • actions/setup/js/daily_aic_workflow_helpers.cjs
  • actions/setup/js/frontmatter_hash_pure.cjs
  • actions/setup/js/fuzz_template_substitution_harness.cjs
  • actions/setup/js/generate_safe_outputs_tools.cjs
  • actions/setup/js/git_auth_helpers.cjs
  • actions/setup/js/interpolate_prompt.cjs
  • actions/setup/js/mcp_cli_bridge.cjs
  • actions/setup/js/merge_pull_request.cjs
  • actions/setup/js/model_aliases.cjs
  • actions/setup/js/mount_mcp_as_cli.cjs
  • actions/setup/js/patch_path_helpers.cjs
  • actions/setup/js/resolve_model_alias.cjs
  • actions/setup/js/safe_output_type_validator.cjs
  • actions/setup/js/safe_outputs_tools_loader.cjs
  • actions/setup/js/sanitize_content_core.cjs
  • actions/setup/js/start_mcp_gateway.cjs

Representative diagnostics

  • add_mask_redaction.cjs:89gh-aw-custom/require-escaped-regexp-interpolation
  • add_reaction.cjs:184gh-aw-custom/no-core-error-then-setfailed
  • mcp_cli_bridge.cjs:240gh-aw-custom/require-http-response-error-listener
  • git_auth_helpers.cjs:207gh-aw-custom/require-error-cause-in-rethrow
  • generate_safe_outputs_tools.cjs:320gh-aw-custom/prefer-structured-clone
  • patch_path_helpers.cjs:28gh-aw-custom/no-math-minmax-array-spread

Expected outcome

Make the repeated mechanical fixes needed for regex interpolation safety, response-stream error listeners, error rethrow causes, and small API cleanup patterns so this lint slice is resolved without broad refactoring.

Remediation checklist

  • Keep work scoped to actions/setup/js regex/API-safety cleanup only.
  • Escape or restructure dynamic new RegExp(...) construction to satisfy interpolation-safety rules.
  • Remove redundant core.error() calls immediately before matching core.setFailed().
  • Add missing HTTP response error listeners and preserve current request behavior.
  • Apply the contained mechanical replacements (structuredClone, reduce-based min/max, { cause: err }, error-code prefix where required).
  • Run npm run lint:setup-js as the final validation.

Copilot instructions

  1. Group edits by repeated lint rule to keep changes reviewable.
  2. Favor import-free/local helpers unless a shared helper already exists nearby.
  3. Avoid mixing in unrelated parsing or error-handling fixes from other groups.
  4. Keep the final validation command exactly npm run lint:setup-js.

Generated by 🧹 ESLint Monster · gpt54 · 17 AIC · ⌖ 6.58 AIC · ⊞ 5.5K ·

  • expires on Aug 28, 2026, 2:03 PM UTC-08:00

Activity

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

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions