Skip to content

[WIP] Refactor parser infrastructure to eliminate excessive function line length#32709

Closed
Copilot wants to merge 1 commit into
mainfrom
copilot/lint-remediation-parser-infrastructure
Closed

[WIP] Refactor parser infrastructure to eliminate excessive function line length#32709
Copilot wants to merge 1 commit into
mainfrom
copilot/lint-remediation-parser-infrastructure

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 16, 2026

  • Fix rawloginlib violations in production code (add/rename logger vars)
    • pkg/parser/content_extractor.go - rename log.* → contentExtractorLog.*
    • pkg/parser/frontmatter_content.go - add logger var, replace log.*
    • pkg/parser/import_bfs.go - add logger var, replace log.*
    • pkg/parser/import_field_extractor.go - add logger var, replace log.*
    • pkg/parser/schedule_cron_detection.go - add logger var, replace log.*
    • pkg/parser/schema_errors.go - add logger var, replace log.*
    • pkg/parser/tools_merger.go - rename log.* → toolsMergerLog.*
    • pkg/actionpins/actionpins.go - rename log → actionPinsLog
  • Fix largefunc violations in production code (extract helper functions)
    • import_bfs.go - processImportsFromFrontmatterWithManifestAndSource (492 lines)
    • schedule_fuzzy_scatter.go - ScatterSchedule (441 lines)
    • mcp.go - ParseMCPConfig (253), processBuiltinMCPTool (225), ExtractMCPConfigurations (193)
    • schedule_parser.go - parseBase (207), parseInterval (203)
    • include_processor.go - processIncludedFileWithVisited (166), processIncludesWithVisited (112)
    • schema_compiler.go - validateWithSchemaAndLocation (165)
    • import_topological.go - topologicalSortImports (157)
    • github_urls.go - ParseGitHubURL (134)
    • import_field_extractor.go - prepareFrontmatter (123), extractActivationFields (93), more
    • include_expander.go - ExpandIncludesWithManifest (87), processIncludesForField (62)
    • remote_fetch.go - downloadIncludeFromWorkflowSpec (101), ResolveIncludePath (85), more
    • frontmatter_content.go - ExtractFrontmatterFromContent (97)
    • yaml_import.go - processYAMLWorkflowImport (95)
    • json_path_locator.go - findAdditionalPropertyInNestedContext (77), findNestedSection (71)
    • frontmatter_hash.go - extractImportsFromText (74), marshalSorted (69)
    • schedule_time_utils.go - parseTime (82)
    • schema_suggestions.go - generateSchemaBasedSuggestions (81), generateExampleFromSchema (79)
    • tools_merger.go - MergeTools (80), mergeToolsFromJSON (62)
    • schema_errors.go - appendKnownFieldValidValuesHint (77)
    • sub_agent_extractor.go - ExtractInlineSubAgents (63)
    • actionpins/actionpins.go - ResolveActionPin (105)
  • Fix largefunc violations in test files
  • Run make golint-custom to confirm zero errors in pkg/parser/ and pkg/actionpins/
  • Run tests to confirm no regressions

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[lint-monster] Lint Remediation: Parser Infrastructure (Group 2/3)

3 participants