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 728330 - Crash when the name of the new playlist contains special characters
Crash when the name of the new playlist contains special characters
Status: RESOLVED FIXED
Product: gnome-music
Classification: Applications
Component: general
3.12.x
Other Linux
: Normal normal
: 3.14
Assigned To: gnome-music-maint
gnome-music-maint
available
Depends on:
Blocks:
 
 
Reported: 2014-04-16 10:11 UTC by Arnel Borja
Modified: 2014-06-08 16:32 UTC
See Also:
GNOME target: ---
GNOME version: 3.11/3.12



Description Arnel Borja 2014-04-16 10:11:31 UTC
When we open the Add to Playlists dialog then create a new playlist with a slash in the name, gnome-music crashes:

Traceback (most recent call last):
  • File "/usr/lib/python3.3/site-packages/gnomemusic/__init__.py", line 44 in wrapped
    retval = fn(*v, **k)
  • File "/usr/lib/python3.3/site-packages/gnomemusic/widgets.py", line 745 in _on_editing_done
    playlist.create_playlist(editable.get_text())
  • File "/usr/lib/python3.3/site-packages/gnomemusic/__init__.py", line 44 in wrapped
    retval = fn(*v, **k)
  • File "/usr/lib/python3.3/site-packages/gnomemusic/playlists.py", line 45 in create_playlist
    parser.save(playlist, pl_file, name, TotemPlParser.ParserType.PLS)
gi._glib.GError: Error opening file '/home/kyoushuu/.local/share/gnome-music/playlists/Slash / Test.pls': No such file or directory

We should strip or escape GLib.DIR_SEPARATOR ("/").
Comment 1 Vadim Rutkovsky 2014-04-16 10:16:42 UTC
Agreed, though we should make it generic, I'm sure there a glib-compatible way to make nice filenames for our playlists
Comment 2 Arnel Borja 2014-05-01 07:02:11 UTC
We could also use Tracker instead to save playlists, which removes restrictions for filenames.
Comment 3 Arnel Borja 2014-06-08 16:32:32 UTC
Fixed by porting playlists to Tracker (bug 729311).