#metabrainz

/

      • akshaaatt
        Hi aerozol! I finally fixed your PR.
      • Now in your terminal hit `git reset --hard origin/master` to get your local git coherent with remote
      • aerozol
        Thank you so much T_T
      • MRiddickW joined the channel
      • MRiddickW has quit
      • leonardo has quit
      • Clint has quit
      • Clint joined the channel
      • leonardo joined the channel
      • yyoung[m] has quit
      • Lorenzo[m] has quit
      • kepstin has quit
      • ijc has quit
      • ijc joined the channel
      • kepstin joined the channel
      • Lorenzo[m] joined the channel
      • yyoung[m] joined the channel
      • riksucks
        hi monkey, are you up?
      • riksucks uploaded an image: (37KiB) < https://libera.ems.host/_matrix/media/r0/download/matrix.org/GswUOxlnOWSxiUqjNOttlEIu/image.png >
      • riksucks uploaded an image: (14KiB) < https://libera.ems.host/_matrix/media/r0/download/matrix.org/npGawqwKuhXAxSJsiIaHDrVB/image.png >
      • do these mockups look good?
      • akshaaatt
        aerozol I believe you need to run `git fetch origin` first and then run `git reset --hard origin/master`
      • BrainzGit
        [bookbrainz-site] 14Asymmentric opened pull request #840 (03master…remove-dashes-from-ISBNs): Remove hyphen from isbns https://github.com/metabrainz/bookbrainz-site/p...
      • PrathameshG[m]
        Hey is there any basic AcousticBrainz related Machine Learning stuff that I can look at?
      • Admittedly, I am a noob at ML. So advice accordingly
      • ijc has left the channel
      • q3lont joined the channel
      • MRiddickW joined the channel
      • q3lont has quit
      • alastairp
        morning
      • hi PrathameshG[m], what kind of machine learning tasks are you interested in looking at?
      • PrathameshG[m]: for genre recognition you might be interested in something like this: https://github.com/jordipons/sklearn-audio-tran... which works a bit better, and is easier to set up
      • mayhem
        moooin!
      • strider has quit
      • q3lont joined the channel
      • strider joined the channel
      • adhawkins has quit
      • kLambda joined the channel
      • kLambda has quit
      • PrathameshG[m]
        alastairp: thanks for sharing!
      • That's exactly what I needed!
      • q3lont has quit
      • Morning everyone :)
      • q3lont joined the channel
      • monkey
        Looks good riksucks ! :)
      • MRiddickW has quit
      • BrainzGit
        [brainzutils-python] 14alastair merged pull request #85 (03master…remove-locks): Remove unused locks module https://github.com/metabrainz/brainzutils-pytho...
      • q3lont has quit
      • riksucks
        hi lucifer are you up?
      • alastairp
        riksucks: lucifer has guests this week, so might not be around as much. can I help?
      • reosarevok: hi, I'm trying to find the bit in the MB API which filters release group types - specifically the bit that checks if a given type is valid, and the bit which uses this provided filter to restrict the list of rgs. Are these values checked directly against the release_group_primary_type table, or are they hard-coded in the server?
      • riksucks
        ohh I see, my bad. alastairp, I was also gonna ping you regarding one discussion. So I was working on a PR where I implemented hiding of user feed events in the backend. And in the code, I had implemented a Bad Request, if user tried to hide an already hidden event
      • do you think it should be that way? or do you think that we should return {"status": "ok"} if user tries to hide event that has already been hidden
      • alastairp
        riksucks: hmm, good question. this is similar to a few other places that we have in the API - such as our delete API, where I believe we don't notify the user if they try and delete something that doesn't already exist
      • TOPIC: MetaBrainz Community and Development channel | MusicBrainz non-development: #musicbrainz | BookBrainz: #bookbrainz | Channel is logged; see https://musicbrainz.org/doc/IRC for details | Agenda: Reviews, Securing MeB infrastructure - part 3 | Telegram-bridge and #musicbrainz, catquest (freso/jwlory)
      • TOPIC: MetaBrainz Community and Development channel | MusicBrainz non-development: #musicbrainz | BookBrainz: #bookbrainz | Channel is logged; see https://musicbrainz.org/doc/IRC for details | Agenda: Reviews, Securing MeB infrastructure - part 3 | Telegram-bridge and #musicbrainz, catquest (freso/jwflory)
      • riksucks
        alastairp: I see, so I should remove the bad request when user tries to hide it twice, right? Apart from that, do you think the PR needs any more changes, or any other feedbacks that you might have in your mind? Thanks :)
      • alastairp
        yes, at the moment I think we should remove bad request
      • in fact, I don't think it's quite the correct code according to the strict definition: https://datatracker.ietf.org/doc/html/rfc7231#s..., in my understanding repeating this query multiple times should always result in the same error (maybe this was a definition in an older version of the RFC)
      • technically, this query could fail some times and then succeed (because elsewhere someone un-hid the event)
      • 412 Precondition Failed could be an option here, but I don't think that's important
      • riksucks
        that makes sense
      • alastairp
        one other option is that we could return HTTP 200, with status: ok, but also with a log message - saying either "event hidden" if it was hidden, or "event was already hidden" if it had already been done. However, can you think of any cases where a client would want to know the difference between if they hid the event, or someone else hid it?
      • see the 2nd comment on this answer: https://stackoverflow.com/a/19671511
      • > However, 400 is appropriate because "The request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications."
      • it's interesting. that last sentence appears to have been removed in the new version of the HTTP RFC
      • riksucks
        you know I was thinking just the same, does the client need to know that the event was already hidden, and that we tried to hide it again, because these hiding/unhiding would be done by the same user across multiple devices.
      • only case I can think of is, suppose someone browses the feed from device A, and hides events in B, then he may go back to device A and wonder why the events aren't hidden
      • maybe we can send "The event was already hidden" message when the user tries to re-hide the same events from new device?
      • alastairp
        yes, right. I think that this is probably quite an uncommon event, in which case I wouldn't worry too much about it. We also have a system for sending messages back to the client from the server (the websockets system, we use it to push new listens to a user's listens page). So a better solution to this problem would probably be to add events to the websockets system
      • however, my recommendation would be to not worry about this for now - just implement your current PR without any extra checks, and then we could add a new feature to add the websockets to the feeed page
      • riksucks
        I see, makes sense, so a new feature can be added to JIRA for real time feed, with both hiding and deleting happening in real time
      • alastairp
        yes, perfect
      • I'll open your PR and put it on my todo list to review, though if lucifer has already looked at it then that might be enough.
      • riksucks
        I see thanks :), I will create the JIRA ticket and update the bad request bit rn.
      • yyg7g76g joined the channel
      • mayhem
      • alastairp: lucifer ^^ you might like this concept.
      • +from
      • tangentially related is a philosophy I've been slowly cultivating with my data processing containers... the idea of not keeping explicit state of a process, but have the state of the process be discoverable by the process when it gets restarted.
      • yyg7g76g has quit
      • odnes joined the channel
      • q3lont joined the channel
      • q3lont has quit
      • BrainzGit
        [listenbrainz-server] 14chinmaykunkikar opened pull request #1977 (03master…lb-1085-trackduration): LB-1085: Show track duration in ListenCard https://github.com/metabrainz/listenbrainz-serv...
      • reosarevok
        alastairp: lemme see
      • alastairp
      • so it looks like you are explictly loading the types from the db on each request
      • reosarevok
        Yeah
      • alastairp
        for validation
      • reosarevok
        A bit surprised that's not cached somehow - maybe it is in the background, dunn
      • alastairp
        I haven't found something where you join against that table and filter. does it match against release_group_primary_type.name directly in the query?
      • reosarevok
        *dunno
      • alastairp
        reosarevok: a follow up question to these kinds of filters -
      • Ansh is currently implementing "list release-groups for a label" and "list events for a place" in CB, in the same was as we list RGs for an artist: https://critiquebrainz.org/artist/763cf642-45ad...
      • note that we have a type filter up the top (this is why we need the validation, we're adding it to BU)
      • a question: if an RG has no type, where do you think it should show?
      • q3lont joined the channel
      • reosarevok
        Well, we have a specific materialized table to make the RG type filtering easier: https://github.com/metabrainz/musicbrainz-serve...
      • q3lont
        is there a way to configure musicbrainz-docker to exclude some tables completely from replication?
      • chinmay joined the channel
      • reosarevok
        It seems we use that in RG browses (https://github.com/metabrainz/musicbrainz-serve...)
      • But we don't have that for labels and places
      • We show no-type RGs first to make people fix them, but that probably doesn't make sense for CB, so under other would make sense for you I guess?
      • alastairp
        but "other" is actually a legit RG type, right?
      • I just noticed that this means that we don't actually show any no-type RGs on CB
      • anyway, the same question goes for events at a place - where would we add events with no type?
      • (I note that you don't show events without a type first, I guess - https://musicbrainz.org/place/4352063b-a833-421... - see 5 up from the bottom (Later 25))
      • reosarevok
        Well, IMO "other" is bullshit, see STYLE-504
      • BrainzBot
        STYLE-504: Replace/remove "Other" types https://tickets.metabrainz.org/browse/STYLE-504
      • alastairp
        right
      • reosarevok
        It's just so people with OCD have something to pick if they don't know what to use
      • But I guess it provides some degree of "someone looked at this already" vs empty
      • alastairp
        for me it seems a bit weird to say "if you specify other, then look for items with type=11, _but also_ items with type=null"
      • but anyway, we can look into that
      • reosarevok
        Well, IMO both are "other", as in, not the other options
      • So it fits :)
      • alastairp
        sure
      • hmm. is artist_release_group new?
      • reosarevok
        I don't think we order events by type at all, just by date
      • Fairly
      • Newer than CB, for sure
      • alastairp
        at the very least, it doesn't appear to be in our replica
      • is populated in mirrors?
      • reosarevok
        It is, but not via replication, but via triggers, and you need to set it up first, IIRC?
      • It's all documented somewhere, give me a min
      • alastairp
        right
      • reosarevok
        For events, I'm honestly not sure I'd even bother to have more than at most "Concert", "Festival" and "Other"
      • When splitting them for filtering in CB
      • Maaybe stage performance
      • alastairp
        good point
      • reosarevok
        Since for classical venues a fair amount would end up under other if not
      • admin/BuildMaterializedTables
      • "If you’re using the web interface or web service, run ./admin/BuildMaterializedTables --database=MAINTENANCE all to build new materialized tables. These will take several additional gigabytes of spaces and be kept up-to-date automatically via triggers. For more information, see INSTALL.md."
      • alastairp
        I see it
      • interesting - the release notes for musicbrainz-docker explains this too - https://github.com/metabrainz/musicbrainz-docke..., but our mirror was set up only a few months ago. so I wonder why this table isn't populated, maybe it's not set up by default? I'll double-check
      • my other question was "how do you order release groups?" but it looks like the answer is here: https://github.com/metabrainz/musicbrainz-serve...
      • type, secondary type, release date, name
      • reosarevok
        q3lont: I just saw your mb-docker issue (assuming it's you since it's the same topic) - I'm not sure it's doable, others might be better at answering that, but
      • Unless you are not using release / release group / track artists at all, you'd certainly need to keep artist_credit at the very least
      • The other tables do not store an artist name
      • If you want anything else than an artist string you'd also need more tables, but :)
      • alastairp: the order is slightly different with slow vs fast
      • (fast sorts by unofficial first)
      • But yeah
      • q3lont
        reosarevok, yeah I need artist_credit too
      • reosarevok
        If you want release events you'll need release_country and area, etc