#beets

/

      • NOTICE: [beets] kooimens opened issue #1173: Scrubbing/removing tags from files with empty musicbrainz fields? https://github.com/sampsyo/beets/issues/1173
      • Agoldfish has quit
      • MaynardWaters has quit
      • nickn_ joined the channel
      • thunderrd has quit
      • thunderrd joined the channel
      • nickn_ has quit
      • Vacuity_ joined the channel
      • Vacuity has quit
      • marcaddeo
        bpd doesn't work with ncmpcpp? :o
      • Joschasa has quit
      • sinonick joined the channel
      • Joschasa joined the channel
      • tuxiano joined the channel
      • tuxiano has quit
      • lazka joined the channel
      • lazka has quit
      • laarmen
        marcaddeo: it works on the Debian ncmpcpp
      • but IIRC it implements an old version of the protocol.
      • Vacuity_ has quit
      • Vacuity_ joined the channel
      • Vacuity_ is now known as Vacuity
      • Revenant joined the channel
      • Revenant
        Hi all, I'm getting the following error message when trying to import a new album; Error: "caused by: <urlopen error [Errno -2] Name or service not known>" in release search with query {'release': u'monstercat 019 - endeavour', 'tracks': '32', 'artist': u'various artists'}
      • I've tried updating beets from 1.3.8 to 1.3.9 but I get another error; No distributions at all found for beets in /usr/local/lib/python2.7/dist-packages
      • Are these these two errors related?
      • Ignore me. My machine didn't have a valid DNS server. :(
      • NOTICE: [beets] etomm opened issue #1174: Windows long paths are not managed correctly https://github.com/sampsyo/beets/issues/1174
      • untitaker joined the channel
      • tuxiano joined the channel
      • tuxiano has quit
      • Revenant has quit
      • tuxiano joined the channel
      • tuxiano has quit
      • Agoldfish joined the channel
      • Exposure has quit
      • Exposure joined the channel
      • fredmorcos joined the channel
      • NOTICE: [beets] sampsyo closed issue #1174: Windows long paths are not managed correctly https://github.com/sampsyo/beets/issues/1174
      • NOTICE: [beets] sampsyo closed issue #1173: Scrubbing/removing tags from files with empty musicbrainz fields? https://github.com/sampsyo/beets/issues/1173
      • Freso
        It would be nice to pull in work-rels though.
      • Also for TLAN.
      • fredmorcos has quit
      • sampsyo: Ping?
      • sampsyo
        Hi! I'm on a flaky connection (traveling) so be aware that I might disappear.
      • Freso
        sampsyo: Fair enough.
      • Are https://github.com/sampsyo/beets/commit/63803a9... and R110 the ones causing the additional ftintitle printing?
      • sampsyo
        It's not that commit per se, but you're on the right track.
      • It should be using `logging` rather than `print_`
      • Freso still isn't totally sure how the beets plugins interface with beet, so is kind of fumbling about trying to figure out the order of execution :)
      • Ah cool.
      • Freso
        Is that a "global" thing? That all the ui_print_()'s should be logging()'s?
      • (Well, "global" for ftintitle anyway.)
      • sampsyo
        Yes, basically, at least for any code that is not just a CLI command.
      • Here's a little orientation:
      • The `ft_in_title` function in that plugin does all the actual work.
      • Freso
        I can't figure out if it's calling something different during import than during `beet ftintitle`.
      • Yep. I figured that much. :)
      • sampsyo
        It is called in two places: inside a closure inside `commands` (i.e., the CLI command), and inside `imported` (i.e., as an import hook)
      • This is a common pattern in plugins (e.g., lyrics, lastgenre).
      • There, the typical solution is to add some parameter to the "do the actual work" function that tells it how verbose to be.
      • Freso
        Right.
      • Alright. That should be doable.
      • sampsyo
        The same thing should work fine here. You can choose between putting all the logging statements under `if`s, or passing in a logging level to be passed to `log.log`.
      • (This is so common that I'd like to add it to the plugin interface so that everybody doesn't have to reinvent it every time.)
      • Soon!
      • Freso
        Soon!™
      • ;)
      • sampsyo
        :)
      • Freso
        Is there something in the environment one could use to figure out whether it's running a command or an import? (Apart from parsing argv...)
      • sampsyo
        Not currently, no. But that's exactly what I want to add. :)
      • Freso
        Ie., does beet set a global variable "I am not importing stuff".
      • Heh. Alright then. :p
      • *now
      • Where would you place this? beets/plugins.py? Ie., the logging function?
      • Should it be a method of BeetsPlugin?
      • sampsyo
        Well, what I'm imagining would actually be part of a slightly larger refactoring.
      • I want to provide every BeetsPlugin with its own `log` member, which would cascade to the global beets logger.
      • It would automatically prefix the plugin name, and it could also adjust its verbosity level depending on whether an import was running.
      • Freso should make something half-assed to provoke you to do it properly ;)
      • :)
      • Perhaps so.
      • Freso
        Or maybe I should just hack ftintitle for now. :p
      • sampsyo
        I would be happy either way. :)
      • The_Freso joined the channel
      • Freso has quit
      • The_Freso is now known as Freso
      • Freso
        So.
      • It seems like other plugins call log.info to just log stuff, and log.debug to actually print it?
      • Eh.
      • The other way around, obviously.
      • sampsyo
        Yes, info is the default threshold. `-v` enables debug.
      • Freso
        Cool.
      • Wasn't there a guide somewhere for how to set up virtualenv and stuff for beets?
      • Or am I mixing it up with mopidy now?
      • I probably am. :|
      • ThomW
        Freso: you could use virtualenv if you don't want beets installed globally
      • virtualenv <folder>, pip install beets any-other-dependencies
      • and ofc use ./folder/bin/activate to later activate that virtualenv
      • Freso
        ThomW: I know.
      • Already did that.
      • Mopidy just has a special setup.py command to use rather than just install: https://docs.mopidy.com/en/develop/contributing...
      • `python2 setup.py test` seems to be broken here?
      • *.
      • zeltak has quit
      • zeltak joined the channel
      • NOTICE: [beets] Freso opened issue #1175: `setup.py test` currently broken https://github.com/sampsyo/beets/issues/1175
      • Is there a way to `beet ls` everything that hasn't got a given value set?
      • NOTICE: [beets] Freso opened pull request #1176: ftintitle: use log.log() for outputting (master...issue-1172-ftintitle-less-import-verbosity) https://github.com/sampsyo/beets/pull/1176
      • marcaddeo
        am i incorrect in thinking ftintitle should fix this? http://pastie.org/private/polbgpcun25pq0tssutcg
      • Freso
        marcaddeo: Define "fix"? What do you expect (or want) to happen?
      • marcaddeo
        well, i'd like the featured artist to be in the track title as opposed to being in the artist field
      • Freso
        marcaddeo: Did you run ls again after ftintitle?
      • marcaddeo
        yes, it's the same
      • Freso
        Try using -v?
      • marcaddeo
      • Freso
        marcaddeo: What happens if you do a more general query?
      • marcaddeo
        such as?
      • Freso
        E.g., have it run on "the roots"?
      • (Instead of "the roots feat talib phren".)
      • marcaddeo
      • Freso
        That looks like an `ls` output?
      • (Eh, `beet ls`)
      • marcaddeo
        oh did you want me to run ftintitle on 'the roots'
      • that makes sense.
      • Freso
        :)
      • marcaddeo
        do you prefer with or without -v
      • Freso
        I don't know if ftintitle maybe trips over itself because it's a single track.
      • marcaddeo
        lol
      • Freso
        Just without.
      • https://github.com/sampsyo/beets/pull/1176 hasn't been merged yet, so ftintitle is plenty verbose without -v :p
      • marcaddeo
      • i wonder if it's tripping up the regular expression because the artist is showing as:
      • The Roots feat. Talib Kweli / The Roots
      • Freso
        Ah. Yeah, possibly.
      • File a report, probably.
      • marcaddeo
        so i'm pretty sure it's because the artist is in there twice
      • playing with the code
      • it seems the problem is with albumartist_split = artist.split(albumartist)
      • and then it assumes that there will only be two elements in the list
      • and only compares the last and first elements of the array
      • or, list
      • when in reality the middle element of the array albumartist_split[1] = feat. Talib Kweli /
      • the slash is a whole nother problem
      • wait maybe it's not
      • if there were a case that just looked for the first non blank element instead of left-hand side this would work, but there would still be an extraneous / at the end of the track title
      • NOTICE: [beets] kelvinhammond opened issue #1177: Importer fails to copy Folder.jpg to cover.jpg when Folder.jpg is a directory https://github.com/sampsyo/beets/issues/1177
      • NOTICE: [beets] Kraymer opened issue #1178: config: need to use explicit list notation when using star character https://github.com/sampsyo/beets/issues/1178
      • NOTICE: [beets] marcaddeo opened issue #1179: ftintitle: does not gracefully handle duplicate artist name https://github.com/sampsyo/beets/issues/1179