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

LB-617: Fix empty fields in release stats #901

Merged
merged 2 commits into from Jun 5, 2020

Conversation

ishaanshah
Copy link
Collaborator

@ishaanshah ishaanshah commented Jun 4, 2020

Problem

The release page shows blank entries for listens not having release name present. We should filter out listens not having the release page to solve the issue.

Example-
https://listenbrainz.org/user/marc2k3/history?page=3&range=month&entity=release
https://api.listenbrainz.org/1/stats/user/marc2k3/releases?offset=50&range=month&count=25

Solution

Adding a WHERE clause for listens not having release name in it fixes the issue

Copy link
Collaborator

@paramsingh paramsingh left a comment

Choose a reason for hiding this comment

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

Can we add a test to make sure this doesn't regress?

@ishaanshah
Copy link
Collaborator Author

ishaanshah commented Jun 5, 2020

Can we add a test to make sure this doesn't regress?

I have modified the test-data so that we test this too.

@ishaanshah ishaanshah closed this Jun 5, 2020
@ishaanshah ishaanshah reopened this Jun 5, 2020
@paramsingh paramsingh merged commit 5be896c into metabrainz:master Jun 5, 2020
@ishaanshah ishaanshah deleted the empty_release branch June 12, 2020 04:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants