C
cyclocomp
ANALYTICS
Velocity0.0
Cyclomatic Complexity of R Code
A cyclomatic complexity checker that ships once every couple of years, and lands when it does.
static-analysiscode-complexitylintingr-packagecontributor-driven
◆Current state
cyclocomp measures cyclomatic complexity of R functions and packages, and is best known as the engine behind lintr's complexity rule. It has three releases in the visible window spread across nearly three years. The current one, 1.1.2, adds a quiet argument to cyclocomp_package_dir(); the two before it, shipped a day apart in 2023, added a large speedup and the package-directory entry point itself.
◆Where it's heading
This is a small tool that reached feature-complete and now moves only when a downstream consumer needs something. Every change in the window is externally contributed, and each addresses a concrete integration need: a function that works on a local package tree rather than an installed one, complexity results sorted so the worst offenders come first, and output suppression for programmatic callers. The 2023 pair shipped a day apart because the new entry point immediately exposed a performance problem on long linear code.
◆Prediction
Expect the next change to arrive the same way, as a contributed patch serving a linting or CI workflow rather than as planned development.
◆Recent moves
- 5mo ago
cyclocomp_package_dir() gains a quiet argument
Adds output suppression to the package-directory entry point, a contributed change of the kind that makes the function usable inside other tooling. The first release in two and a half years.
View source ↗ - 2y ago
Large speedup on long linear code
A performance fix shipped one day after 1.1.0, addressing the case the new package-directory function would hit most often. The pairing suggests the speedup was found while exercising the new entry point.
View source ↗ - 2y ago
Complexity checks run against a local package tree
Adds cyclocomp_package_dir() for uninstalled source trees, cyclocomp_q() for quoted expressions, and sorts package results by descending complexity. The release that made the package practical to run inside CI.
View source ↗