Skip to content

Accuracy check: re-score finished checks once when the scoring rules change - #45

Merged
gabrielbr merged 1 commit into
mainfrom
ccr-67ccb970-dqwwqd
Oct 23, 2026
Merged

gabrielbr merged 1 commit into
mainfrom
ccr-67ccb970-dqwwqd

Conversation

@gabrielbr

Copy link
Copy Markdown
Owner

This follows up #44. That PR's wear-coverage rule only reached finished checks if someone opened the report and pressed "Recompute". Finished checks otherwise keep their stored result forever.

What changes

  • AccuracyScorer.SCORING_VERSION (now 2) is recorded per check on every successful score, in SharedPreferences accuracy_scoring.
  • rescoreOutdated scores every finished check that was last scored under an older version, oldest first. Passes run one at a time behind a mutex.
  • It runs:
    • once per process, 10 s after startup, in the process scope, so it doesn't compete with connecting the ring;
    • whenever the Accuracy check screen opens.
  • Health Connect reads need the app in the foreground, so a check that can't be read now is retried on a later launch.
  • The report screen also forces a re-score when it opens an outdated check.
  • Accepted corrections are not touched.

AGENTS.md now says to bump the version whenever a rule change alters a finished check's result.


Generated by Claude Code

@gabrielbr
gabrielbr merged commit b0140f4 into main Oct 23, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants