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
MBS-11117: Create report for too long discIDs #1700
MBS-11117: Create report for too long discIDs #1700
Conversation
eab9a16
to
1e39e2a
Compare
5fec551
to
8e89e6d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is currently correctly creating and filling the report table but it fails to display it on error:
TypeError: Cannot read property 'total_entries' of undefined
at CDTocDubiousLength (webpack:///./root/report/CDTocDubiousLength.js?:113:18)
I suspect the code around inflate_rows
did not find the cause yet.
DiscIDs should be assigned to only CD format mediums and should not be above 80-something minutes. CDTOC above the cutoff (set to 100 minutes here) were probably created with a buggy version of foo_musicbrainz and can be removed.
Support for MediumCDTocT was added in 50ba95d
36fc4a9
to
686e18a
Compare
Pushed a rebased fix. Also changed the Perl files to use CDTOC as we do elsewhere :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works flawlessly. Thanks for having fixed the letter casing too.
|
||
with 'MusicBrainz::Server::Report::CDTOCReport'; | ||
|
||
sub table { 'cd_toc_dubious_length' } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess that was the missing bit.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the main issue was the link generated from the reports index was wrong, too :D But a bit of everything maybe :)
Problem
MBS-11117: new report about discid durations above 100 minutes, that should be fixed or removed.
cf https://community.metabrainz.org/t/sacd-types-and-discid/494807/8
Solution
cf screenshot on MBS-11117
Action
There are a few things that need a serious review and will probably need rework:
that just passes the parameters of the report SQL query. Not sure it would make more sense to pass the 'id' there, since we don't have gid on the cdtoc table.(Edit: I had to use "id" in the end in order to use CDTocLink)* CDTOCs are not defined with React yet. I didn't want to modify EntityLink so I just defined the href=/cdtoc/... link in root/report/components/CdTocList.js, but that should probably be changed for other conversions to React.I pass durations from SQL in seconds and convert to milliseconds in JS to use formatTrackLength. Exporting durations in millisecond in SQL would be over the 2**31 integer limit in postgres
I don't speak Perl so I just copy-pasted lib/MusicBrainz/Server/Report/CdTocReport.pm, I'm not sure what's inside is correct