Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

T263584 T263544 Fix bug from gallery row #68

Merged
merged 3 commits into from
Sep 28, 2020
Merged

Conversation

hueitan
Copy link
Member

@hueitan hueitan commented Sep 23, 2020

Phabricator Ticket 1 : https://phabricator.wikimedia.org/T263584
Phabricator Ticket 2 : https://phabricator.wikimedia.org/T263544

Problem

The gallery sometimes show duplicate or show empty row

Solution

Reorder the method calling and remove the empty row when nothing from the media list API

Note

Task different but Code are relevant, so one fix for both.

medied
medied previously approved these changes Sep 23, 2020
Copy link
Contributor

@medied medied left a comment

Choose a reason for hiding this comment

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

LGTM

stephanebisson
stephanebisson previously approved these changes Sep 23, 2020
@jpita
Copy link
Contributor

jpita commented Sep 24, 2020

repeated gallery in popup
image

@hueitan
Copy link
Member Author

hueitan commented Sep 24, 2020

To reproduce this, follow this case

  1. on Desktop browser,
  2. Go to https://wikimedia.github.io/wikipedia-preview/articles/demo/spanish.html
  3. Set your internet speed to be very slow
  4. Hover Smiljan
  5. Leave it immediately (when it is in loading animation)
  6. Hover Smiljan back immediately and wait
  7. You should see the first gallery comes up, after a while the second gallery comes

This is due to the race condition that we didn't clear the previous api request; or the loading state shouldn't have the onshow event to load gallery.

@hueitan
Copy link
Member Author

hueitan commented Sep 24, 2020

Another case

  1. on Desktop browser,
  2. Go to https://wikimedia.github.io/wikipedia-preview/articles/demo/swahili.html
  3. (Optional Step) Set your internet speed to be very slow
  4. Hover Roma ya Kale
  5. Leave it immediately (when it is in loading animation)
  6. Hover Bahari immediately and wait
  7. You will see the gallery from btoh Bahari and Roma ya Kale

@hueitan hueitan dismissed stale reviews from stephanebisson and medied September 24, 2020 14:44

Dismiss approval

@hueitan
Copy link
Member Author

hueitan commented Sep 25, 2020

The latest commit fix the specific edge case, a better solution can be a better management for the popup status (loading, article, error, disambiguation), but it's out of scope right now.

Copy link
Collaborator

@stephanebisson stephanebisson left a comment

Choose a reason for hiding this comment

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

@jpita ready for more testing

@jpita jpita merged commit ab7dcd9 into master Sep 28, 2020
@jpita jpita deleted the T263584-T263544-fix branch September 28, 2020 23:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

4 participants