51 lines
1.3 KiB
Markdown
51 lines
1.3 KiB
Markdown
|
|
# Cyclomatic Complexity Analysis Report
|
||
|
|
## Calendar Plantempus TypeScript Codebase
|
||
|
|
|
||
|
|
**Generated:** 2025-10-06
|
||
|
|
**Analyzer:** Roo AI Assistant
|
||
|
|
**Total Files Analyzed:** 40+
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## Executive Summary
|
||
|
|
|
||
|
|
### Complexity Distribution
|
||
|
|
|
||
|
|
| Complexity Range | Risk Level | Count | Percentage |
|
||
|
|
|-----------------|------------|-------|------------|
|
||
|
|
| 1-10 | ✅ Low | TBD | TBD% |
|
||
|
|
| 11-20 | ⚠️ Medium | TBD | TBD% |
|
||
|
|
| 21-50 | 🔴 High | TBD | TBD% |
|
||
|
|
| 50+ | 💀 Critical | TBD | TBD% |
|
||
|
|
|
||
|
|
### Key Metrics
|
||
|
|
- **Total Functions:** TBD
|
||
|
|
- **Average Complexity:** TBD
|
||
|
|
- **Highest Complexity:** TBD
|
||
|
|
- **Files Needing Refactoring:** TBD
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## Methodology
|
||
|
|
|
||
|
|
### Cyclomatic Complexity Calculation
|
||
|
|
For each function, we count:
|
||
|
|
- **+1** for the function itself
|
||
|
|
- **+1** for each `if`, `else if`, `while`, `for`, `case`
|
||
|
|
- **+1** for each `&&`, `||` in conditions
|
||
|
|
- **+1** for each `catch` block
|
||
|
|
- **+1** for each ternary operator `? :`
|
||
|
|
- **+1** for each `return` statement (except the last one)
|
||
|
|
|
||
|
|
### Risk Assessment
|
||
|
|
- **1-10:** Simple, easy to test and maintain
|
||
|
|
- **11-20:** Moderate complexity, acceptable
|
||
|
|
- **21-50:** Complex, should be refactored
|
||
|
|
- **50+:** Very complex, high maintenance risk
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## Analysis in Progress...
|
||
|
|
|
||
|
|
This report is being generated. Please wait for the complete analysis.
|