repowisetemporalio/temporal

Code health of temporalio/temporal

Repowise scores temporalio/temporal at 6.7 out of 10 for code health, which reads as fair, alongside maintainability 7.1 and static performance 9.9 on the same scale. There are 7,577 open findings across the three pillars, and the lowest-scoring file is workflow.go at 1.6. Scores are computed from complexity, duplication, churn and git fix history, not from a linter.

Findings by severity

539 critical, 1,574 high, 2,481 medium, 2,808 low.

Hotspots

140 files are flagged as hotspots. The top 5:

  • api/historyservice/v1/request_response.pb.go: 7 commits in the last 90 days from 41 contributors with 1 recent bug fix
  • api/persistence/v1/executions.pb.go: 8 commits in the last 90 days from 37 contributors with 2 recent bug fixes
  • service/history/workflow/mutable_state_impl.go: 28 commits in the last 90 days from 73 contributors with 14 recent bug fixes
  • api/matchingservice/v1/request_response.pb.go: 4 commits in the last 90 days from 21 contributors
  • service/frontend/workflow_handler.go: 28 commits in the last 90 days from 87 contributors with 8 recent bug fixes

Lowest-scoring files

  • service/frontend/admin_handler_test.go: 1.3 out of 10 with 2 bug fixes in the last 180 days
  • service/worker/workerdeployment/workflow.go: 1.6 out of 10
  • tests/schedule_test.go: 1.6 out of 10 with 11 bug fixes in the last 180 days
  • tests/xdc/stream_based_replication_test.go: 1.7 out of 10
  • service/frontend/admin_handler.go: 1.7 out of 10 with 2 bug fixes in the last 180 days

Checked against bug fixes

Of the 20 files Repowise scores lowest, 13 had a bug fix in the last 180 days. Across all 2,826 scored files, 10.3% had a bug fix in that window.

Dead code and refactoring

Repowise found 89 unused exports. 372 refactoring targets across 372 files would raise the score.

More on temporal: summary and FAQ, codebase overview, architecture.

Related guide: Best dead code detection tools by language