repowiseopenmrs/openmrs-core

Code health of openmrs/openmrs-core

Repowise scores openmrs/openmrs-core at 7.4 out of 10 for code health, which reads as good, alongside maintainability 7.8 and static performance 9.5 on the same scale. There are 1,829 open findings across the three pillars, and the lowest-scoring file is ModuleUtil.java at 1.0. Scores are computed from complexity, duplication, churn and git fix history, not from a linter.

Findings by severity

103 critical, 252 high, 810 medium, 361 low.

Hotspots

2 files are flagged as hotspots. The top 2:

  • web/src/test/java/org/openmrs/web/filter/initialization/InitializationFilterE2ETest.java: 3 commits in the last 90 days from 3 contributors
  • web/src/main/java/org/openmrs/web/filter/initialization/InitializationFilter.java: 3 commits in the last 90 days from 6 contributors

Lowest-scoring files

  • api/src/main/java/org/openmrs/module/ModuleUtil.java: 1.0 out of 10 with 1 bug fix in the last 180 days
  • web/src/main/java/org/openmrs/web/filter/initialization/InitializationFilter.java: 1.0 out of 10 with 2 bug fixes in the last 180 days
  • api/src/main/java/org/openmrs/util/OpenmrsClassLoader.java: 1.0 out of 10
  • api/src/main/java/org/openmrs/api/context/Context.java: 1.0 out of 10 with 1 bug fix in the last 180 days
  • api/src/main/java/org/openmrs/Obs.java: 1.0 out of 10

Checked against bug fixes

Of the 20 files Repowise scores lowest, 8 had a bug fix in the last 180 days. Across all 1,345 scored files, 3.4% had a bug fix in that window.

Dead code and refactoring

Repowise found 65 unused exports. 143 refactoring targets across 143 files would raise the score.

More on openmrs-core: summary and FAQ, codebase overview, architecture.

Related guide: Best dead code detection tools by language