Skip to content

fix: prevent monthly schedule stream accumulation#561

Merged
jjoonleo merged 2 commits into
mainfrom
feature/issue-527-monthly-subscription
Jun 28, 2026
Merged

fix: prevent monthly schedule stream accumulation#561
jjoonleo merged 2 commits into
mainfrom
feature/issue-527-monthly-subscription

Conversation

@jjoonleo

Copy link
Copy Markdown
Contributor

Summary

  • Replaced repeatable emit.forEach month-range listeners in MonthlySchedulesBloc with one owned, cancellable schedule stream subscription.
  • Added request-id guarded private stream events so stale range emissions cannot overwrite the newer Calendar Month Range.
  • Added glossary terms for Schedule, Monthly Calendar, and Calendar Month Range in CONTEXT.md.

Tests

  • dart run build_runner build --delete-conflicting-outputs
  • flutter test test/presentation/calendar/bloc/monthly_schedules_bloc_test.dart --plain-name "adjacent Calendar Month Range changes keep one active schedule listener"
  • flutter test test/presentation/calendar/bloc/monthly_schedules_bloc_test.dart --plain-name "stale schedule stream cannot overwrite newer Calendar Month Range"
  • flutter test test/presentation/calendar/bloc/monthly_schedules_bloc_test.dart --plain-name "schedule stream update refreshes schedule fields in monthly state"
  • flutter test test/presentation/calendar/bloc/monthly_schedules_bloc_test.dart
  • flutter test test/presentation/calendar/bloc/monthly_schedules_bloc_test.dart test/presentation/calendar/screens/calendar_screen_test.dart test/presentation/home/components/month_calendar_test.dart test/presentation/home/screens/home_screen_tmp_test.dart
  • flutter analyze
  • flutter test

Closes #527

@jjoonleo jjoonleo marked this pull request as ready for review June 28, 2026 05:35
@jjoonleo jjoonleo merged commit 5f414ac into main Jun 28, 2026
1 of 4 checks passed
@jjoonleo jjoonleo deleted the feature/issue-527-monthly-subscription branch June 28, 2026 12:35
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.

Prevent MonthlySchedulesBloc from accumulating month stream subscriptions

1 participant