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

morituri crashes if disc not found on MusicBrainz #89

Open
nitro322 opened this issue Aug 27, 2014 · 19 comments
Open

morituri crashes if disc not found on MusicBrainz #89

nitro322 opened this issue Aug 27, 2014 · 19 comments

Comments

@nitro322
Copy link

morituri 0.2.3 crashes when attempting to rip a CD that does not exist in MusicBrainz, even if the -U option is provided. Eg.:

$ rip cd -d /dev/sr0 rip -O /tmp --track-template="track-%t" --disc-template="disc" --profile=wav -U
Using configured read offset 6
Checking device /dev/sr0
CDDB disc id: 1e028c03                        
MusicBrainz disc id UTJbn6KfaALRft1AjUIucLYnND4-
MusicBrainz lookup URL http://mm.musicbrainz.org/bare/cdlookup.html?toc=1+3+49097+182+19820+46457&tracks=3&id=UTJbn6KfaALRft1AjUIucLYnND4-
Disc duration: 00:10:52.200, 3 audio tracks
Error: NotFoundException(ResponseError(),)
Continuing without metadata
Submit this disc to MusicBrainz at the above URL.

Traceback (most recent call last):
  File "/usr/bin/rip", line 41, in <module>
    sys.exit(main.main(sys.argv[1:]))
  File "/usr/lib64/python2.7/site-packages/morituri/rip/main.py", line 45, in main
    ret = c.parse(argv)
  File "/usr/lib64/python2.7/site-packages/morituri/rip/main.py", line 123, in parse
    logcommand.LogCommand.parse(self, argv)
  File "/usr/lib64/python2.7/site-packages/morituri/extern/command/command.py", line 401, in parse
    return self.subCommands[command].parse(args[1:])
  File "/usr/lib64/python2.7/site-packages/morituri/extern/command/command.py", line 401, in parse
    return self.subCommands[command].parse(args[1:])
  File "/usr/lib64/python2.7/site-packages/morituri/extern/command/command.py", line 363, in parse
    ret = self.do(args)
  File "/usr/lib64/python2.7/site-packages/morituri/rip/cd.py", line 126, in do
    self.program.metadata.discid = self.ittoc.getMusicBrainzDiscId()
AttributeError: 'NoneType' object has no attribute 'discid'

Ripping works fine with the same options with any other disc that is included in MusicBrainz. Would appreciate if you could look into this. I haven't been able to find a way to workaround it so far.

Also, could you please consider adding an option to make MusicBrainz optional? I've never been a big fan of that service, and I'm currently writing a wrapper script around morituri to let me use freedb data instead. However, it's a little annoying that it's still dependent on MusicBrainz data and embeds all of that data in the cue/log files even when I don't want it, and a bit more annoying when it crashes entirely because of a bug with MusicBrainz support. :-) Not all that big a deal if you don't want to make it optional, but since I was posting here I thought I'd ask.

Thanks. Aside from this issue, morituri has been fantastic, and finally got me to switch away from EAC.

@Camisa
Copy link

Camisa commented Nov 7, 2014

I'm running into this same error while trying to retag an image using v2.0.3.

The 'NoneType' object has no attribute 'discid' comes up for me on all .cue in my collection and the paste below is just one example.

rip image retag /.cue
Retagging image 'Bloodhound Gang - The Bad Touch/Bloodhound Gang - The Bad Touch.cue'
** Message: pygobject_register_sinkfunc is deprecated (GstObject)
MusicBrainz disc id is 4NGMoSEUSDev9k5jR0MIGISYVKo-
MusicBrainz lookup URL http://mm.musicbrainz.org/bare/cdlookup.html?toc=1+2+32832+150+16650&tracks=2&id=4NGMoSEUSDev9k5jR0MIGISYVKo-
Disc duration: 00:07:15.760, 2 audio tracks

Matching releases:

Artist : Bloodhound Gang
Title : The Bad Touch
Duration: 00:07:15.000
URL : http://musicbrainz.org/release/2ad91b5c-29d4-4ba5-a495-524d1a150dad
Release : 2ad91b5c-29d4-4ba5-a495-524d1a150dad
Type : Single

Traceback (most recent call last):
File "/usr/bin/rip", line 41, in
sys.exit(main.main(sys.argv[1:]))
File "/usr/lib64/python2.7/site-packages/morituri/rip/main.py", line 45, in main
ret = c.parse(argv)
File "/usr/lib64/python2.7/site-packages/morituri/rip/main.py", line 123, in parse
logcommand.LogCommand.parse(self, argv)
File "/usr/lib64/python2.7/site-packages/morituri/extern/command/command.py", line 401, in parse
return self.subCommands[command].parse(args[1:])
File "/usr/lib64/python2.7/site-packages/morituri/extern/command/command.py", line 401, in parse
return self.subCommands[command].parse(args[1:])
File "/usr/lib64/python2.7/site-packages/morituri/extern/command/command.py", line 363, in parse
ret = self.do(args)
File "/usr/lib64/python2.7/site-packages/morituri/rip/image.py", line 143, in do
taglist = prog.getTagList(track.number)
File "/usr/lib64/python2.7/site-packages/morituri/common/program.py", line 450, in getTagList
mbDiscId = self.metadata.discid
AttributeError: 'DiscMetadata' object has no attribute 'discid'

@aereaux
Copy link

aereaux commented Jan 21, 2015

I'm still seeing this bug on Arch Linux with morituri 0.2.3 while trying to rip a disc:

> rip cd rip --offset 48 -U
Checking device /dev/sr0
CDDB disc id: 430b8805                        
MusicBrainz disc id xQcAguyRUe0JOz9T.UEpVKVNZTs-
MusicBrainz lookup URL http://mm.musicbrainz.org/bare/cdlookup.html?toc=1+5+221598+183+46418+94363+122193+164603&tracks=5&id=xQcAguyRUe0JOz9T.UEpVKVNZTs-
Disc duration: 00:49:12.200, 5 audio tracks
Error: NotFoundException(ResponseError(),)
Continuing without metadata
Submit this disc to MusicBrainz at the above URL.

FreeDB identifies disc as Anton�n Dvor�k / Symphony No.8 in G major - Scherzo capriccioso
Traceback (most recent call last):                 
  File "/usr/bin/rip", line 41, in <module>
    sys.exit(main.main(sys.argv[1:]))
  File "/usr/lib/python2.7/site-packages/morituri/rip/main.py", line 45, in main
    ret = c.parse(argv)
  File "/usr/lib/python2.7/site-packages/morituri/rip/main.py", line 123, in parse
    logcommand.LogCommand.parse(self, argv)
  File "/usr/lib/python2.7/site-packages/morituri/extern/command/command.py", line 401, in parse
    return self.subCommands[command].parse(args[1:])
  File "/usr/lib/python2.7/site-packages/morituri/extern/command/command.py", line 401, in parse
    return self.subCommands[command].parse(args[1:])
  File "/usr/lib/python2.7/site-packages/morituri/extern/command/command.py", line 363, in parse
    ret = self.do(args)
  File "/usr/lib/python2.7/site-packages/morituri/rip/cd.py", line 126, in do
    self.program.metadata.discid = self.ittoc.getMusicBrainzDiscId()
AttributeError: 'NoneType' object has no attribute 'discid'

Is there a fix for this yet?

@aereaux
Copy link

aereaux commented Jan 21, 2015

OK, it looks like this issue has been fixed in git. Is there any plan to do a release any time soon?

@Freso
Copy link
Contributor

Freso commented Jan 21, 2015

There's a morituri-git package in the AUR you can use until the next release.

@aereaux
Copy link

aereaux commented Jan 21, 2015

Yeah, that's what I'm using now, thanks.

@mwpow3ll
Copy link

Is a MusicBrainz entry required in order to rip? I have a CD that is not found in Musicbrainz and Morituri just ejects the disc? Why can't it rip the disk as unknown?

@ArchangeGabriel
Copy link

You can use CDDB else. But yes, it’s needed AFAIK. And when I encounter a CD that’s not found in Musicbrainz, then I add it there, it’s a collaborative database, you’re welcome to contribute!

@mwpow3ll
Copy link

Ok, Morituri can be forced to rip a disc unknown to MusicBrainz by passing the -U option and I am seeing this issue as well. I just patched my local cd.py to workaround...

@toolforger
Copy link

Same problem here, version 0.2.3.
@mwpow3ll can you post your patch?

@mwpow3ll
Copy link

This has already been submitted upstream: 01f07c5

@toolforger
Copy link

Thanks!
Now I can fix this without having to replicate the debugging, and without having to wait for an official bug fix release.

@toolforger
Copy link

I'm getting crashes for %s and %S in templates.
Might be related to the fix or not.

@thomasvs
Copy link
Owner

@toolforger file separate issues for those please with the traceback.

@toolforger
Copy link

Done, see #126

@robotmaxtron
Copy link

Still running into this issue with the copr repo from https://copr.fedorainfracloud.org/coprs/snuxoll/morituri/

Applied @mwpow3ll manually as a workaround.

@NicoHood
Copy link

I still see this in morituri 0.2.3-1 on arch x64.

@mwpow3ll
Copy link

0.2.3 is two years old. 01f07c5 is in master or you can manually apply.

Just for clarification, I did not create 01f07c5 :)

@NicoHood
Copy link

I tried the git PKGBUILD on AUR which also does not work. Same error.

@NicoHood
Copy link

NicoHood commented Jul 30, 2016

Looking at this again:
Maybe I missunderstood the bugreport. I still get this error, but no python backtraces. Is it expected that the program will stop ripping if the cd is not in the database? Is the only way to add the disk to musicbrainz? Or can I somehow skip it? (looks like you can with -U)?

And why is no further version tagged if it got fixed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

10 participants