After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 355256 - Poor path parsing in FileTrackInfo
Poor path parsing in FileTrackInfo
Status: RESOLVED OBSOLETE
Product: banshee
Classification: Other
Component: Metadata
unspecified
Other Linux
: Normal normal
: 0.13.x
Assigned To: Banshee Maintainers
Banshee Maintainers
Depends on:
Blocks:
 
 
Reported: 2006-09-10 10:31 UTC by Juri Pakaste
Modified: 2007-08-18 13:51 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
a patch to FileTrackInfo.ParsePath to make it work on /Artist/Album/Number - Title.extension and /Artist/Album/Title.extension (2.42 KB, patch)
2006-09-10 10:33 UTC, Juri Pakaste
rejected Details | Review

Description Juri Pakaste 2006-09-10 10:31:25 UTC
Banshee's path parsing for untagged files acts silly. Example:

/The Herbaliser/Blow Your Headphones/03 - Another Mother.mp3

Banshee thinks the artist is Blow Your Headphones, title is Another Mother.mp3 and  album is 03 - Another Mother.mp3.

I'm attaching a patch that makes it work correctly for this case and also if there's no track number in the file name. I hope it's not breaking anything else.
Comment 1 Juri Pakaste 2006-09-10 10:33:26 UTC
Created attachment 72492 [details] [review]
a patch to FileTrackInfo.ParsePath to make it work on /Artist/Album/Number - Title.extension and /Artist/Album/Title.extension
Comment 2 Aaron Bockover 2006-09-11 20:09:52 UTC
The poor path parsing is just in FileTrackInfo... in LibraryTrackInfo (used for importing files), there should be really solid path parsing that would handle your case. 

I'd rather move that path parsing to FileTrackInfo instead of this patch (there's nothing wrong with this patch, but the version in LibraryTrackInfo is more extensive and has been tested for well over a year).

Actually, I'd rather make path parsing static to the base TrackInfo class or something, so it can be reused cleanly wherever necessary. I'm going to reject your patch for that reason, but thanks for the effort and report.

Also moving to the metadata component as this isn't strictly related to importing. Path parsing should be seen as a supplementary/fallback to tag reading.
Comment 3 Josiah Ritchie - flickerfly 2007-01-18 21:06:57 UTC
Is this still a problem in the latest 0.11.4 or SVN?
Comment 4 Josiah Ritchie - flickerfly 2007-08-18 13:51:19 UTC
I'm going to close this since there hasn't been any activity for a very long time.