Skip to content

Conversation

@gokuma
Copy link

@gokuma gokuma commented Sep 11, 2024

Issue

Overview (Required)

The instability of the internalDay value is the cause of the issue, and the reason is likely because a new request is being made before the asynchronous stream of streamTimetable() inside the for loop has completed. As a result, the same streamTimetable result is processed multiple times, potentially overwriting the expected value of internalDay.

  • added cancellation handling for each request, ensuring that a new request is not executed until the previous one has completed.

The issue may have been improved with #1036, but it still seems to occur, especially when adding/removing favorites quickly.

Links

Screenshot (Optional if screenshot test is present or unrelated to UI)

Before After

Movie (Optional)

Before After
before.mp4
after.mp4

@gokuma gokuma force-pushed the fix-ios-favorite-session-timetable-bug branch from 96cc527 to 63ba4a3 Compare September 11, 2024 21:57
Copy link
Member

@ry-itto ry-itto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch! Thanks!

@gokuma gokuma requested a review from ry-itto September 12, 2024 00:48
@gokuma
Copy link
Author

gokuma commented Sep 17, 2024

CI is failing in a place that is not related to the fix.

Error: This request has been automatically failed because it uses a deprecated version of actions/upload-artifact: v2. Learn more: https://github.blog/changelog/2024-02-13-deprecation-notice-v1-and-v2-of-the-artifact-actions/

same error:
#1028 (comment)

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.

When we favorite sessions on day 13 in the iOS app, the session list resets to day 12.

2 participants