Skip to content

Fix period logging: always show Flow/Symptoms, save all tracked categories with defaults#163

Merged
mapgie merged 2 commits into
mainfrom
claude/period-tracking-auto-sync-xfsz2g
Jun 29, 2026
Merged

Fix period logging: always show Flow/Symptoms, save all tracked categories with defaults#163
mapgie merged 2 commits into
mainfrom
claude/period-tracking-auto-sync-xfsz2g

Conversation

@mapgie

@mapgie mapgie commented Jun 28, 2026

Copy link
Copy Markdown
Owner

Summary

  • Flow and Symptoms always appear on the Log Period screen. Previously guarded by showInLogPeriod, which is not user-controllable for system categories (the toggle is hidden in the UI). Removing the guard makes the behaviour unconditional: these sections show as long as the category exists and is not archived.

  • Editing a period now correctly saves the selected flow level. The previous call to syncFlowLogsForPeriod skipped any date that already had a flow log, so changing flow while editing a period was silently ignored. Switched to saveLog (upsert), consistent with how symptoms are already saved.

  • All pinned categories record an entry on save, even with default values. numeric_slider categories now fall back to numericMin when the user has not moved the slider (matching the value already displayed in the UI). increment categories now always write an entry including a count of 0, since a zero is meaningful data for a category the user chose to track alongside periods. Chip and free-text categories are unchanged — they still require an explicit selection.

Changed files

  • ui/screens/log/LogPeriodScreen.kt — removed showInLogPeriod guard from Flow and Symptoms sections.
  • ui/screens/log/LogPeriodViewModel.ktsyncFlowToTrackingLog uses saveLog (upsert) instead of syncFlowLogsForPeriod (insert-only); syncSymptomsToTrackingLog has the showInLogPeriod guard removed; computePinnedValues saves slider minimum and zero-counts instead of skipping.
  • changelog/unreleased/period-tracking-auto-sync.json — patch changelog fragment.

claude added 2 commits June 28, 2026 17:58
Flow and Symptoms now show unconditionally on the Log Period screen as
long as the category exists and is not archived — the showInLogPeriod
flag is not user-controllable for system categories, so the guard was
unnecessary and created a silent no-show risk.

syncFlowToTrackingLog now calls saveLog (upsert) instead of
syncFlowLogsForPeriod (insert-only). This means editing an existing
period correctly updates the flow level rather than silently keeping
the previous value.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DYPputv2ksYiiz79HNgQ1T
numeric_slider categories now fall back to numericMin when the user
has not moved the slider, matching the value the UI displays.
increment categories now always write an entry (including 0) since a
zero count is meaningful data for a category pinned to period logging.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DYPputv2ksYiiz79HNgQ1T
@mapgie mapgie changed the title Fix period logging: always show Flow/Symptoms, upsert flow on save Fix period logging: always show Flow/Symptoms, save all tracked categories with defaults Jun 28, 2026
@mapgie mapgie marked this pull request as ready for review June 29, 2026 07:58
@mapgie mapgie merged commit c0252f4 into main Jun 29, 2026
4 checks passed
@mapgie mapgie deleted the claude/period-tracking-auto-sync-xfsz2g branch June 29, 2026 07:58
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