Skip to content

[lint-monster] lint-monster: function-length refactoring backlog #42880

Description

@github-actions

Summary

Custom lint scan found 654 shared function-length findings under pkg/workflow and pkg/cli from make golint-custom.

This is the single authoritative lint-monster tracking issue for the shared function-length refactoring backlog. Do not split this backlog into separate workflow/cli or part-numbered issues.

Current count

  • Total shared function-length findings: 654
  • pkg/workflow: 281
  • pkg/cli: 373

Representative diagnostics

  • pkg/workflow/action_resolver.go:93: ResolveSHA is 67 lines long
  • pkg/workflow/compiler_main_job.go:26: buildMainJob is 420 lines long
  • pkg/workflow/maintenance_workflow_yaml.go:34: buildMaintenanceWorkflowYAML is 968 lines long
  • pkg/cli/actionlint.go:223: runActionlintOnFilesWithOptions is 184 lines long
  • pkg/cli/audit_report_render.go:24: renderConsole is 310 lines long

Expected outcome

Reduce the shared backlog by extracting helpers and simplifying control flow while preserving behavior.

Remediation checklist

  • Pick a small slice of functions from this backlog and refactor only those functions.
  • Prefer minimal, targeted code edits over broad rewrites.
  • Keep helper extraction local to the affected package unless a shared abstraction is clearly justified.
  • Preserve tests and behavior; add or update tests only when needed for the chosen slice.
  • Validate the slice by running make golint-custom.
  • Report which functions were removed from the backlog and any follow-up slices still recommended.

Suggested next slices

  • pkg/workflow/action_resolver.go, pkg/workflow/antigravity_tools.go, pkg/workflow/build_input_schema.go
  • pkg/cli/access_log.go, pkg/cli/actions_build_command.go, pkg/cli/add_interactive_schedule.go
  • pkg/workflow/command.go, pkg/workflow/compiler_activation_job.go, pkg/workflow/compiler_jobs.go

Notes for the agent

Scope work to the selected slice only. Use make golint-custom to confirm the assigned functions no longer trigger largefunc findings.

Generated by 🧌 LintMonster · 31.5 AIC · ⌖ 22.3 AIC · ⊞ 4.4K ·

  • expires on Jul 8, 2026, 7:50 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