repowisemicrosoft/tokeneconomizer

microsoft / tokeneconomizer

pythonmain12468f443.7K linessynced on Nov 18, 2026

Code health

6.5out of 10Fair

Hotspots average 5.0, the place fixes pay off most.

Explore this codebase

Do next · 5

5 things worth doing in the week to Nov 17, the last indexed commit.

Worth planning

  • Start breaking up update (CCN 124, 212 lines): first lift lines 397-422

    tokeneconomizer/microskills/envfacts.py:397

    update has many paths; easier to read and change once split; function changed in 5 commits; its file is imported by 8 files, changed 8 times in 90 days.

    gain
    up to +1.8 health on this file(inferred)
    finding
    Complex method
    size
    CCN 124, 212 lines, nests 4 deep
    severity
    high
    worth a check
  • Tidy the code shape this week's commits left: 8 findings in 6 files

    7 commits in the last 7 days added or worsened long, complex or deeply nested code, still open. Start with tokeneconomizer/microskills/distiller.py (2 findings): tidying it while the change is fresh costs less than after the next one.

    code-shape findings
    8
    files
    6
    commits
    7
  • Start breaking up observe_task (CCN 74, 90 lines): first lift lines 699-709

    tokeneconomizer/microskills/observe.py:699

    observe_task has many paths; easier to read and change once split; function changed in 4 commits; its file is imported by 9 files, changed 12 times in 90 days.

    gain
    up to under +0.1 health on this file(inferred)
    finding
    Complex method
    size
    CCN 74, 90 lines, nests 5 deep
    severity
    high
    worth a check
  • Review why fixes keep landing in tokeneconomizer/microskills/distiller.py: tests reach it

    Changed 17 times in 90 days, and 4 of those commits were bug fixes.

    commits in 90 days
    17
    bug-fix commits
    4
    line coverage
    Unknown, no report
    tests that reach it
    7 test files, call graph(inferred)
    worth a check
  • Start breaking up _merge_host (CCN 53, 76 lines): first lift lines 367-375

    tokeneconomizer/plugin/repos.py:367

    _merge_host has many paths; easier to read and change once split; function changed in 2 commits; its file is imported by 7 files, changed 8 times in 90 days.

    gain
    up to +0.2 health on this file(inferred)
    finding
    Complex method
    size
    CCN 53, 76 lines
    severity
    high
    worth a check

Everything we found

5 areas