Skip Menu |

This queue is for tickets about the MP3-Tag CPAN distribution.

Report information
The Basics
Id: 13527
Status: new
Priority: 0/
Queue: MP3-Tag

People
Owner: Nobody in particular
Requestors: nandhp
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.97
Fixed in: (no value)



Subject: Cannot unset genre in ID3v2
I'm using the very latest MP3::Tag and I cannot unset the genre in ID3v2. It works fine for ID3v1 though. I tried several methods: $mp3->{ID3v2}->genre(''); $mp3->{ID3v2}->remove_frame('TCON'); $mp3->{ID3v2}->remove_frame('vTCON'); But the genre keeps going back to whatever it was before.
Date: Mon, 4 Jul 2005 21:55:37 -0700
From: Ilya Zakharevich <nospam-abuse [...] ilyaz.org>
To: Guest via RT <bug-MP3-Tag [...] rt.cpan.org>
Subject: Re: [cpan #13527] Cannot unset genre in ID3v2
RT-Send-Cc:
On Mon, Jul 04, 2005 at 02:56:20PM -0400, Guest via RT wrote: Show quoted text
> I'm using the very latest MP3::Tag and I cannot unset the genre in > ID3v2. It works fine for ID3v1 though.
What version of MP3::Tag (i released about 4 in the last couple of days)? Did it work with older versions? Thanks, Ilya
Date: Mon, 4 Jul 2005 22:11:49 -0700
From: Ilya Zakharevich <nospam-abuse [...] ilyaz.org>
To: Guest via RT <bug-MP3-Tag [...] rt.cpan.org>
CC: undisclosed-recipients: ;
Subject: Re: [cpan #13527] Cannot unset genre in ID3v2
RT-Send-Cc:
On Mon, Jul 04, 2005 at 02:56:20PM -0400, Guest via RT wrote: Show quoted text
> > This message about MP3-Tag was sent to you by guest <> via rt.cpan.org > > Full context and any attached attachments can be found at: > <URL: https://rt.cpan.org/Ticket/Display.html?id=13527 > > > I'm using the very latest MP3::Tag and I cannot unset the genre in ID3v2. It works fine for ID3v1 though. > > I tried several methods: > $mp3->{ID3v2}->genre(''); > $mp3->{ID3v2}->remove_frame('TCON'); > $mp3->{ID3v2}->remove_frame('vTCON'); > > But the genre keeps going back to whatever it was before.
I tried it with mp3info2: touch xxx.mp3 mp3info2 -a aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -g Rock -u xxx.mp3 mp3info2 -g '' xxx.mp3 TCON comes and goes fine. Did you update_tags()? Hope this helps, Ilya
[nospam-abuse@ilyaz.org - Tue Jul 5 01:11:58 2005]: Show quoted text
> I tried it with mp3info2: > > touch xxx.mp3 > mp3info2 -a aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -g Rock -u > xxx.mp3 > mp3info2 -g '' xxx.mp3 >
mp3info2 does only seems to set the ID3v1 tags (according to my other tagging applications) and this is only a problem with ID3v2. I have, however written a simple test program which will get/set the ID3v2 genre to demonstrate this issue. touch foo.mp3 genretest.pl foo.mp3 # No genre genretest.pl foo.mp3 'Foo' # Set genre to Foo genretest.pl foo.mp3 # Genre is Foo genretest.pl foo.mp3 'Bar' # Set genre to Bar genretest.pl foo.mp3 # Genre is Bar genretest.pl foo.mp3 '' # Unset genre <-- This doesn't work. genretest.pl foo.mp3 # Genre is Bar I'm using MP3-Tag 0.97, I haven't tried any other versions. Thank you.
#!/usr/bin/perl use MP3::Tag; use strict; my ($file,$setgenre) = @ARGV; # Command-line arguments my $mp3 = MP3::Tag->new($file) or die "Can't open (1): $!"; # Look for existing genre my $has_tags_already = 0; foreach ( $mp3->get_tags() ) { $has_tags_already ++ if $_ eq 'ID3v2' } my $genre = $has_tags_already ? $mp3->{'ID3v2'}->genre() : ''; print "Genre: $genre\n"; if ( defined $setgenre ) { # Set genre? $mp3->new_tag('ID3v2') unless $has_tags_already; print "New Genre: $setgenre\n"; $mp3->{'ID3v2'}->genre($setgenre); $mp3->{'ID3v2'}->write_tag(); $mp3->close(); } __END__
Date: Tue, 9 Aug 2005 10:36:04 -0700
From: Ilya Zakharevich <nospam-abuse [...] ilyaz.org>
To: Guest via RT <bug-MP3-Tag [...] rt.cpan.org>
CC: undisclosed-recipients: ;
Subject: Re: [cpan #13527] Cannot unset genre in ID3v2
RT-Send-Cc:
On Wed, Jul 13, 2005 at 08:01:07AM -0400, Guest via RT wrote: Show quoted text
> > touch xxx.mp3 > > mp3info2 -a aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -g Rock -u > > xxx.mp3 > > mp3info2 -g '' xxx.mp3 > >
> > mp3info2 does only seems to set the ID3v1 tags (according to my other > tagging applications)
Apparently, you did not try the command line above. Show quoted text
> genretest.pl foo.mp3 # Genre is Bar > genretest.pl foo.mp3 '' # Unset genre <-- This doesn't work. > genretest.pl foo.mp3 # Genre is Bar
As you saw, this is not reproduced with mp3info2. Yours, Ilya