Skip to content

[lint-monster] Reduce custom lint function-length hotspots in pkg/workflow builders #49250

Description

@github-actions

Summary

Daily make golint-custom reports a concentrated largefunc backlog in pkg/workflow builders, parsers, and engine-step generation code. This issue tracks a narrow execution slice focused on the highest-signal workflow hotspots, distinct from the shared tracker.

Root cause group

Large workflow-construction and parsing functions combine multiple phases inline and should be decomposed into smaller helpers with stable behavior.

Affected files

  • pkg/workflow/awf_helpers.go
  • pkg/workflow/safe_outputs_config_extraction.go
  • pkg/workflow/codex_engine.go
  • pkg/workflow/awf_config.go
  • pkg/workflow/safe_outputs_config_global.go
  • pkg/workflow/unified_prompt_step.go
  • pkg/workflow/tools_parser.go
  • pkg/workflow/filters.go

Representative diagnostics

  • pkg/workflow/awf_helpers.go:229 — BuildAWFCommand is 377 lines long
  • pkg/workflow/safe_outputs_config_extraction.go:45 — extractSafeOutputsConfig is 366 lines long
  • pkg/workflow/codex_engine.go:207 — GetExecutionSteps is 315 lines long
  • pkg/workflow/awf_config.go:469 — BuildAWFConfigJSON is 294 lines long
  • pkg/workflow/safe_outputs_config_global.go:12 — extractGlobalConfigFields is 285 lines long
  • pkg/workflow/unified_prompt_step.go:266 — generateUnifiedPromptCreationStep is 259 lines long

Expected outcome

Reduce the assigned pkg/workflow largefunc findings by extracting helper functions while preserving compiler behavior and generated output.

Remediation checklist

  • Keep changes scoped to the listed pkg/workflow files and largefunc findings only
  • Prefer minimal, targeted helper extraction over broad rewrites
  • Preserve generated YAML/output and existing validation behavior
  • Avoid unrelated cleanup or API redesign
  • Validate with make golint-custom

Generated by 🧌 LintMonster · gpt54 · 39 AIC · ⌖ 9.81 AIC · ⊞ 5.3K · ◷

  • expires on Aug 6, 2026, 7:49 PM UTC-08:00

No activity

Activity on this issue will appear here.

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