You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Files Analyzed: compiler.go, compiler_jobs.go, compiler_yaml_main_job.go Status: ⚠️ 2 of 3 files meet the 75-point quality threshold
Executive Summary
Two of the three files analyzed today (compiler.go at 86/100, compiler_jobs.go at 78/100) meet the human-written quality threshold. compiler_yaml_main_job.go scores 70/100 (Acceptable) due to sparse error wrapping, oversized functions, and a below-average test ratio. The single most urgent finding is buildCustomJobs in compiler_jobs.go at 365 lines — a significant outlier warranting refactoring.
Summary Table
File
Score
Rating
Lines
Top Issue
compiler.go
86/100
✅ Good
539
CompileWorkflowData 157 lines
compiler_jobs.go
78/100
✅ Good
1,040
buildCustomJobs 365 lines
compiler_yaml_main_job.go
70/100
⚠️ Acceptable
1,077
Sparse error wrapping
Average: 78/100 · Test ratios: 2.03×, 3.66×, 0.87×
Dimension Scores
Dimension (max)
compiler.go
compiler_jobs.go
compiler_yaml_main_job.go
Structure (25)
22
14
16
Readability (20)
17
14
14
Error Handling (20)
15
18
13
Testing (20)
19
20
14
Patterns (15)
13
12
13
Total
86
78
70
Top 3 Issues
buildCustomJobs is 365 lines (compiler_jobs.go) — Handles dependency injection, condition resolution, and step insertion in one function. Suggested splits: resolveCustomJobDependencies, injectAgentStepsIntoCustomJob, applyCustomJobConditions. Effort: ~3–4 hrs.
Sparse error wrapping in compiler_yaml_main_job.go — Only 5 fmt.Errorf calls in 1,077 lines; most errors propagate as bare return err with no phase context. Apply fmt.Errorf("phase context: %w", err) at each phase boundary. Effort: ~2–3 hrs.
Two 140+ line functions in compiler_yaml_main_job.go: generateEngineInstallAndPreAgentSteps (148 lines) mixes engine-specific setup for 4 engines + MCP init; generateInitialAndCheckoutSteps (143 lines) covers OTLP masking, pre-steps, checkout, app tokens, and imports. Both should be decomposed. Effort: ~2 hrs each.
📋 Per-File Details
compiler.go — 86/100 ✅
8 functions · avg 64 lines · max 157 (CompileWorkflowData)
Both exported entry points have thorough godoc blocks
Comment density 10.6% · test ratio 2.03×
The single fmt.Errorf call does not use %w — minor fix
compiler_jobs.go — 78/100 ✅
23 functions · avg 44 lines · max 365 (buildCustomJobs)
Error wrapping: 28/32 (87.5%) use %w — strong discipline
Comment density 6.1% — low for a 1,040-line file
Test ratio 3.66× — best in batch; robust regression safety net
compiler_yaml_main_job.go — 70/100 ⚠️
15 functions · avg 71 lines · max 148 (generateEngineInstallAndPreAgentSteps)
Phase-based naming (generateInitial..., generateRuntime..., generateEngine...) is excellent
fmt.Errorf count: 5 total, all use %w when present — but 5 is too few for 1,077 lines
Test ratio 0.87× — lowest; engine-install branching paths likely under-tested
💾 Cache & Next Schedule
Cache: /tmp/gh-aw/cache-memory/compiler-quality/ (first run — baseline established)
Next rotation (6 files remaining):
compiler_orchestrator_workflow.go (668 lines)
compiler_orchestrator_frontmatter.go (264 lines)
compiler_orchestrator_tools.go (508 lines)
compiler_orchestrator_engine.go (483 lines)
compiler_safe_outputs_job.go (885 lines)
compiler_yaml.go (1,023 lines)
Recommended Action
Highest priority: Add fmt.Errorf("...: %w", err) wrapping at phase boundaries in compiler_yaml_main_job.go (~2–3 hrs, purely additive, safe to merge without risk of behaviour change).
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
🔍 Compiler Code Quality Analysis — 2026-06-03
Files Analyzed:⚠️ 2 of 3 files meet the 75-point quality threshold
compiler.go,compiler_jobs.go,compiler_yaml_main_job.goStatus:
Executive Summary
Two of the three files analyzed today (
compiler.goat 86/100,compiler_jobs.goat 78/100) meet the human-written quality threshold.compiler_yaml_main_job.goscores 70/100 (Acceptable) due to sparse error wrapping, oversized functions, and a below-average test ratio. The single most urgent finding isbuildCustomJobsincompiler_jobs.goat 365 lines — a significant outlier warranting refactoring.Summary Table
compiler.goCompileWorkflowData157 linescompiler_jobs.gobuildCustomJobs365 linescompiler_yaml_main_job.goAverage: 78/100 · Test ratios: 2.03×, 3.66×, 0.87×
Dimension Scores
Top 3 Issues
buildCustomJobsis 365 lines (compiler_jobs.go) — Handles dependency injection, condition resolution, and step insertion in one function. Suggested splits:resolveCustomJobDependencies,injectAgentStepsIntoCustomJob,applyCustomJobConditions. Effort: ~3–4 hrs.Sparse error wrapping in
compiler_yaml_main_job.go— Only 5fmt.Errorfcalls in 1,077 lines; most errors propagate as barereturn errwith no phase context. Applyfmt.Errorf("phase context: %w", err)at each phase boundary. Effort: ~2–3 hrs.Two 140+ line functions in
compiler_yaml_main_job.go:generateEngineInstallAndPreAgentSteps(148 lines) mixes engine-specific setup for 4 engines + MCP init;generateInitialAndCheckoutSteps(143 lines) covers OTLP masking, pre-steps, checkout, app tokens, and imports. Both should be decomposed. Effort: ~2 hrs each.📋 Per-File Details
compiler.go— 86/100 ✅CompileWorkflowData)fmt.Errorfcall does not use%w— minor fixcompiler_jobs.go— 78/100 ✅buildCustomJobs)%w— strong disciplinecompiler_yaml_main_job.go— 70/100generateEngineInstallAndPreAgentSteps)generateInitial...,generateRuntime...,generateEngine...) is excellentfmt.Errorfcount: 5 total, all use%wwhen present — but 5 is too few for 1,077 lines💾 Cache & Next Schedule
Cache:
/tmp/gh-aw/cache-memory/compiler-quality/(first run — baseline established)Next rotation (6 files remaining):
compiler_orchestrator_workflow.go(668 lines)compiler_orchestrator_frontmatter.go(264 lines)compiler_orchestrator_tools.go(508 lines)compiler_orchestrator_engine.go(483 lines)compiler_safe_outputs_job.go(885 lines)compiler_yaml.go(1,023 lines)Recommended Action
Highest priority: Add
fmt.Errorf("...: %w", err)wrapping at phase boundaries incompiler_yaml_main_job.go(~2–3 hrs, purely additive, safe to merge without risk of behaviour change).References: §26862174037
Beta Was this translation helpful? Give feedback.
All reactions