# Failed to add some tracks in Iris - what could be the reason?

**URL:** <https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839>\
**Category:** Misc\
**Created:** [March 25, 2021, 9:06pm UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839 "2021-03-25T21:06:15Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![m-hoefling](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.mopidy.com/m-hoefling/32/1899_2.png) [@m-hoefling](https://discourse.mopidy.com/u/m-hoefling)\
**Post date:** [March 25, 2021, 9:06pm UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/1 "2021-03-25T21:06:15Z")

</div>

Hey there,  
after migrating my music to mopidy and one of my last steps is to take over my playlists.  
For 90% of the titles in my playlists everything works fine. But for some entries i do not yet understand whats going wrong.  
In mopidy iris these “bad” entries are only shown as an uri like:  
local:track:The%20Prodigy/Invaders%20Must%20Die/02%20Omen.mp3  
and when i try to play them i get the message “Failed to add some tracks”.  
I also tried to verify all these bad uris in my playlists via e g.  
os.path.isfile(file) but the files are existing/known/visible.  
Also setting mopidy verbosity to 4 sadly did not show anything when reproducing the issue.

Has somebody experienced simliar behaviour with playlists or has an idea what to check next/what could mopidy/iris make failing to add these tracks?

Looking forward to your replies,  
thanks!

General infos:  
mopidy is running as a service.  
Music folder is owned (rwx) by mopidy user  
running on RasPi4 with Buster

---

<div class="post-metadata">

**Author:** ![kingosticks](https://avatars.discourse-cdn.com/v4/letter/k/858c86/32.png) [@kingosticks](https://discourse.mopidy.com/u/kingosticks)\
**Post date:** [March 25, 2021, 10:46pm UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/2 "2021-03-25T22:46:48Z")

</div>

Is this problem isolated to Iris? There have been a bunch of urlencoding issues lately (one is [Unable to play local media Album/Artist from playlist · Issue #708 · jaedb/Iris · GitHub](https://github.com/jaedb/Iris/issues/708)). If you can reproduce the issue with other web clients / MPD clients then we can investigate here. Otherwise I am going to suggest you use the Iris issue tracker.

---

<div class="post-metadata">

**Author:** ![m-hoefling](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.mopidy.com/m-hoefling/32/1899_2.png) [@m-hoefling](https://discourse.mopidy.com/u/m-hoefling)\
**Post date:** [March 27, 2021, 10:18am UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/3 "2021-03-27T10:18:28Z")

</div>

thanks for the quick response.  
I tried with mpd, Mopidy Muse and Mopidy Mobile app on android - looks like problem is NOT isolated to iris. mpd just does not show the “bad” tracks at all, in mobile app also just the uris are shown and its not possible to play them.

Would you mind to sketch up the chain whats happening in the background when “play track/play now/…” is pressed so that we can find out which part is actually not working?

---

<div class="post-metadata">

**Author:** ![kingosticks](https://avatars.discourse-cdn.com/v4/letter/k/858c86/32.png) [@kingosticks](https://discourse.mopidy.com/u/kingosticks)\
**Post date:** [March 27, 2021, 10:55am UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/4 "2021-03-27T10:55:18Z")

</div>

I’d prefer you provided the debug log while reproducing the problem. And the output from `sudo mopidyctl config` and `sudo mopidyctl deps`. Details available at the troubleshooting page in our documentation.

---

<div class="post-metadata">

**Author:** ![kingosticks](https://avatars.discourse-cdn.com/v4/letter/k/858c86/32.png) [@kingosticks](https://discourse.mopidy.com/u/kingosticks)\
**Post date:** [March 27, 2021, 11:06am UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/5 "2021-03-27T11:06:32Z")

</div>

You can see what happens in Mopidy’s core library and tracklist components. It takes the uri,does a `lookup` using the backend identified by the uri scheme to get a `Track`, adds that to the tracklist. The debug log should show anything going wrong there preventing certain tracks not being displayed.

How did you “take over” your playlists, what does that mean?

---

<div class="post-metadata">

**Author:** ![m-hoefling](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.mopidy.com/m-hoefling/32/1899_2.png) [@m-hoefling](https://discourse.mopidy.com/u/m-hoefling)\
**Post date:** [March 27, 2021, 11:45am UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/6 "2021-03-27T11:45:00Z")

</div>

Here is the log

**Log using Mopidy Mobile App**

> Mar 27 12:36:57 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Received WebSocket message from 192.168.178.20: ‘{“method”:“core.playback.get\_current\_tl\_track”,“jsonrpc”:“2.0”,“id”:48}’  
> Mar 27 12:36:57 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Sent WebSocket message to 192.168.178.20: ‘{“jsonrpc”: “2.0”, “id”: 48, “result”: null}’  
> Mar 27 12:36:57 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Received WebSocket message from 192.168.178.20: ‘{“method”:“core.tracklist.add”,“params”:{“uris”:[“local:track:Foreigner/Unknown%20Album/Cold%20as%20Ice.mp3”]},“jsonrpc”:“2.0”,“id”:49}’  
> Mar 27 12:36:57 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Sent WebSocket message to 192.168.178.20: ‘{“jsonrpc”: “2.0”, “id”: 49, “result”: }’  
> Mar 27 12:36:57 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Received WebSocket message from 192.168.178.20: ‘{“method”:“core.playback.play”,“params”:{},“jsonrpc”:“2.0”,“id”:50}’  
> Mar 27 12:36:57 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Sent WebSocket message to 192.168.178.20: ‘{“jsonrpc”: “2.0”, “id”: 50, “result”: null}’

**Log using Iris**

> – Logs begin at Sat 2021-03-27 12:40:27 CET. –  
> Mar 27 12:40:46 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Sent WebSocket message to 192.168.178.29: ‘{“jsonrpc”: “2.0”, “id”: 131, “result”: {“local:track:Foo%20Fighters/Greatest%20Hits/14%20Wheels.mp3”: [{“ **model** ”: “Track”, “uri”: “local:track:Foo%20Fighters/Greatest%20Hits/14%20Wheels.mp3”, “name”: “Wheels”, “artists”: [{“ **model** ”: “Artist”, “uri”: “local:artist:md5:e98da64289c09eec2fea1c288319de39”, “name”: “Foo Fighters”}], “album”: {“ **model** ”: “Album”, “uri”: “local:album:md5:a2a26b92cab067bf0ebc7a8d0ac924c0”, “name”: “Greatest Hits”, “date”: “2009-06-08”}, “genre”: “Pop”, “track\_no”: 14, “date”: “2009-06-08”, “length”: 271386, “bitrate”: 127993, “comment”: “[www.radio-fx.de](http://www.radio-fx.de)”, “last\_modified”: 1306675224000}], “local:track:GEORGE%20MICHAEL/Unknown%20Album/FAITH%201.mp3”: , “local:track:Foreigner/Unknown%20Album/Cold%20as%20Ice.mp3”: }}’  
> Mar 27 12:41:04 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Received WebSocket message from 192.168.178.29: ‘{“method”:“core.tracklist.add”,“params”:{“uris”:[“local:track:Foreigner/Unknown%20Album/Cold%20as%20Ice.mp3”],“at\_position”:0},“jsonrpc”:“2.0”,“id”:132}’  
> Mar 27 12:41:04 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Sent WebSocket message to 192.168.178.29: ‘{“jsonrpc”: “2.0”, “id”: 132, “result”: }’  
> Mar 27 12:41:08 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Received WebSocket message from 192.168.178.29: ‘{“method”:“core.tracklist.add”,“params”:{“uris”:[“local:track:GEORGE%20MICHAEL/Unknown%20Album/FAITH%201.mp3”],“at\_position”:0},“jsonrpc”:“2.0”,“id”:133}’  
> Mar 27 12:41:08 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Sent WebSocket message to 192.168.178.29: ‘{“jsonrpc”: “2.0”, “id”: 133, “result”: }’
> 
> ## LAST TRACK WORKS:
> 
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Received WebSocket message from 192.168.178.29: ‘{“method”:“core.tracklist.add”,“params”:{“uris”:[“local:track:Foo%20Fighters/Greatest%20Hits/14%20Wheels.mp3”],“at\_position”:0},“jsonrpc”:“2.0”,“id”:134}’  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [Core-6] mopidy.core.tracklist Triggering event: tracklist\_changed()  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [Core-6] mopidy.listener Sending tracklist\_changed to CoreListener: {}  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [MpdFrontend-9] mopidy.listener Sending playlist to MpdSession: {}  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Sent WebSocket message to 192.168.178.29: ‘{“jsonrpc”: “2.0”, “id”: 134, “result”: [{“ **model** ”: “TlTrack”, “tlid”: 1, “track”: {“ **model** ”: “Track”, “uri”: “local:track:Foo%20Fighters/Greatest%20Hits/14%20Wheels.mp3”, “name”: “Wheels”, “artists”: [{“ **model** ”: “Artist”, “uri”: “local:artist:md5:e98da64289c09eec2fea1c288319de39”, “name”: “Foo Fighters”}], “album”: {“ **model** ”: “Album”, “uri”: “local:album:md5:a2a26b92cab067bf0ebc7a8d0ac924c0”, “name”: “Greatest Hits”, “date”: “2009-06-08”}, “genre”: “Pop”, “track\_no”: 14, “date”: “2009-06-08”, “length”: 271386, “bitrate”: 127993, “comment”: “asdf”, “last\_modified”: 1306675224000}}]}’  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Received WebSocket message from 192.168.178.29: ‘{“method”:“core.playback.play”,“params”:{“tlid”:1},“jsonrpc”:“2.0”,“id”:135}’  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [Audio-2] mopidy.audio.gst Changing state to GST\_STATE\_READY: result=GST\_STATE\_CHANGE\_SUCCESS  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [MainThread] mopidy.audio.gst Got STATE\_CHANGED bus message: old=GST\_STATE\_NULL new=GST\_STATE\_READY pending=GST\_STATE\_VOID\_PENDING  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [LocalBackend-5] mopidy.backend Backend translated URI from local:track:Foo%20Fighters/Greatest%20Hits/14%20Wheels.mp3 to file:///media/nasmusic/Foo%20Fighters/Greatest%20Hits/14%20Wheels.mp3  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [Audio-2] mopidy.audio.actor Flags: 2  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [SoftwareMixer-1] mopidy.mixer Mixer event: volume\_changed(volume=100)  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [SoftwareMixer-1] mopidy.listener Sending volume\_changed to MixerListener: {‘volume’: 100}  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [Audio-2] mopidy.audio.gst Got source-setup signal: element=GstFileSrc  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [Audio-2] mopidy.audio.gst Changing state to GST\_STATE\_PLAYING: result=GST\_STATE\_CHANGE\_ASYNC  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [Core-6] mopidy.listener Sending volume\_changed to CoreListener: {‘volume’: 100}  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Sent WebSocket message to 192.168.178.29: ‘{“jsonrpc”: “2.0”, “id”: 135, “result”: null}’  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [HttpServer] mopidy.http.handlers Received WebSocket message from 192.168.178.29: ‘{“method”:“core.tracklist.get\_tl\_tracks”,“params”:{},“jsonrpc”:“2.0”,“id”:136}’  
> Mar 27 12:41:18 pimusic mopidy[15882]: DEBUG [MpdFrontend-9] mopidy.listener Sending mixer to MpdSession: {}

Here some images how it looks like for me:  
 ![Capture](https://canada1.discourse-cdn.com/flex036/uploads/mopidy/original/2X/4/4c1e68c8c7362e1a3b8de3068ba8c6647ce9f5a5.png)

 ![Capture2](https://canada1.discourse-cdn.com/flex036/uploads/mopidy/original/2X/7/7c92ab59d9bebc3180af56ad520c86caefbe0e6a.png)

**Deps:**

> Running “/usr/bin/mopidy --config /usr/share/mopidy/conf.d:/etc/mopidy/mopidy.conf deps” as user mopidy  
> INFO [MainThread] mopidy. **main** Starting Mopidy 3.1.1  
> DEBUG [MainThread] mopidy.ext Loading entry point: file = mopidy.file:Extension  
> DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-File 3.1.1  
> DEBUG [MainThread] mopidy.ext Loading entry point: http = mopidy.http:Extension  
> DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-HTTP 3.1.1  
> DEBUG [MainThread] mopidy.ext Loading entry point: m3u = mopidy.m3u:Extension  
> DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-M3U 3.1.1  
> DEBUG [MainThread] mopidy.ext Loading entry point: softwaremixer = mopidy.softwaremixer:Extension  
> DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-SoftwareMixer 3.1.1  
> DEBUG [MainThread] mopidy.ext Loading entry point: stream = mopidy.stream:Extension  
> DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-Stream 3.1.1  
> DEBUG [MainThread] mopidy.ext Loading entry point: muse = mopidy\_muse:Extension  
> DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-Muse 0.0.24  
> DEBUG [MainThread] mopidy.ext Loading entry point: mpd = mopidy\_mpd:Extension  
> DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-MPD 3.1.0  
> DEBUG [MainThread] mopidy.ext Loading entry point: local = mopidy\_local:Extension  
> DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-Local 3.2.0  
> DEBUG [MainThread] mopidy.ext Loading entry point: iris = mopidy\_iris:Extension  
> DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-Iris 3.57.3  
> DEBUG [MainThread] mopidy.ext Discovered extensions: file, http, m3u, softwaremixer, stream, muse, mpd, local, iris  
> DEBUG [MainThread] mopidy.config.keyring Fetching passwords from your keyring failed. Any passwords stored in the keyring will not be available. (org.freedesktop.DBus.Error.NotSupported: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11)  
> INFO [MainThread] mopidy.config Loading config from builtin defaults  
> INFO [MainThread] mopidy.config Loading config from file:///usr/share/mopidy/conf.d/mopidy.conf  
> INFO [MainThread] mopidy.config Loading config from file:///etc/mopidy/mopidy.conf  
> INFO [MainThread] mopidy.config Loading config from command line options  
> DEBUG [MainThread] mopidy.ext Validating extension: file  
> DEBUG [MainThread] mopidy.ext Validating extension: http  
> DEBUG [MainThread] mopidy.ext Validating extension: m3u  
> DEBUG [MainThread] mopidy.ext Validating extension: softwaremixer  
> DEBUG [MainThread] mopidy.ext Validating extension: stream  
> DEBUG [MainThread] mopidy.ext Validating extension: muse  
> DEBUG [MainThread] mopidy.ext Validating extension: mpd  
> DEBUG [MainThread] mopidy.ext Validating extension: local  
> DEBUG [MainThread] mopidy.ext Validating extension: iris  
> INFO [MainThread] mopidy. **main** Enabled extensions: http, mpd, local, muse, iris, stream, softwaremixer, m3u  
> INFO [MainThread] mopidy. **main** Disabled extensions: file  
> Executable: /usr/bin/mopidy  
> Platform: Linux-5.10.17-v7l±armv7l-with-debian-10.8  
> Python: CPython 3.7.3 from /usr/lib/python3.7  
> Mopidy: 3.1.1 from /usr/local/lib/python3.7/dist-packages  
> Pykka: 2.0.3 from /usr/local/lib/python3.7/dist-packages  
> setuptools: 40.8.0 from /usr/lib/python3/dist-packages  
> tornado: 6.1 from /usr/local/lib/python3.7/dist-packages  
> requests: 2.21.0 from /usr/lib/python3/dist-packages  
> setuptools: 40.8.0 from /usr/lib/python3/dist-packages  
> Mopidy-MPD: 3.1.0 from /usr/local/lib/python3.7/dist-packages  
> Pykka: 2.0.3 from /usr/local/lib/python3.7/dist-packages  
> setuptools: 40.8.0 from /usr/lib/python3/dist-packages  
> Mopidy: 3.1.1 from /usr/local/lib/python3.7/dist-packages  
> setuptools: 40.8.0 from /usr/lib/python3/dist-packages  
> Mopidy-Muse: 0.0.24 from /usr/local/lib/python3.7/dist-packages  
> Pykka: 2.0.3 from /usr/local/lib/python3.7/dist-packages  
> setuptools: 40.8.0 from /usr/lib/python3/dist-packages  
> Mopidy: 3.1.1 from /usr/local/lib/python3.7/dist-packages  
> setuptools: 40.8.0 from /usr/lib/python3/dist-packages  
> Mopidy-Local: 3.2.0 from /usr/local/lib/python3.7/dist-packages  
> uritools: 3.0.0 from /usr/local/lib/python3.7/dist-packages  
> Pykka: 2.0.3 from /usr/local/lib/python3.7/dist-packages  
> setuptools: 40.8.0 from /usr/lib/python3/dist-packages  
> Mopidy: 3.1.1 from /usr/local/lib/python3.7/dist-packages  
> setuptools: 40.8.0 from /usr/lib/python3/dist-packages  
> Mopidy-Iris: 3.57.3 from /usr/local/lib/python3.7/dist-packages  
> Pykka: 2.0.3 from /usr/local/lib/python3.7/dist-packages  
> setuptools: 40.8.0 from /usr/lib/python3/dist-packages  
> Mopidy: 3.1.1 from /usr/local/lib/python3.7/dist-packages  
> setuptools: 40.8.0 from /usr/lib/python3/dist-packages  
> GStreamer: 1.14.4.0 from /usr/lib/python3/dist-packages/gi  
> Detailed information:  
> Python wrapper: python-gi 3.30.4  
> Relevant elements:  
> Found:  
> uridecodebin  
> souphttpsrc  
> appsrc  
> alsasink  
> osssink  
> oss4sink  
> pulsesink  
> id3demux  
> id3v2mux  
> lamemp3enc  
> mpegaudioparse  
> mpg123audiodec  
> vorbisdec  
> vorbisenc  
> vorbisparse  
> oggdemux  
> oggmux  
> oggparse  
> flacdec  
> flacparse  
> shout2send  
> Not found:  
> flump3dec  
> mad

**Config**

> [core]  
> cache\_dir = /var/cache/mopidy  
> config\_dir = /etc/mopidy  
> data\_dir = /var/lib/mopidy  
> max\_tracklist\_length = 10000  
> restore\_state = false
> 
> [logging]  
> verbosity = 4  
> format = %(levelname)-8s [%(threadName)s] %(name)s %(message)s  
> color = false  
> config\_file =
> 
> [audio]  
> mixer = software  
> mixer\_volume =  
> output = audioresample ! audioconvert ! audio/x-raw,rate=48000,channels=2,format=S16LE ! wavenc ! filesink location=/tmp/snapfifo  
> buffer\_time =
> 
> [proxy]  
> scheme =  
> hostname =  
> port =  
> username =  
> password =
> 
> [file]  
> enabled = false ; Extension disabled by user config.
> 
> [http]  
> enabled = true  
> hostname = 0.0.0.0  
> port = 6680  
> zeroconf = Mopidy HTTP server on $hostname  
> allowed\_origins =  
> csrf\_protection = true  
> default\_app = mopidy
> 
> [m3u]  
> enabled = true  
> base\_dir = /media/nasmusic/  
> default\_encoding = latin-1  
> default\_extension = .m3u8  
> playlists\_dir = /home/pi/playlists
> 
> [softwaremixer]  
> enabled = true
> 
> [stream]  
> enabled = true  
> protocols =  
> http  
> https  
> mms  
> rtmp  
> rtmps  
> rtsp  
> metadata\_blacklist =  
> timeout = 5000
> 
> [muse]  
> enabled = true  
> mopidy\_host = localhost  
> mopidy\_port = 6680  
> mopidy\_ssl = false  
> snapcast\_host = localhost  
> snapcast\_port = 1780  
> snapcast\_ssl = false
> 
> [mpd]  
> enabled = true  
> hostname = ::  
> port = 6600  
> password =  
> max\_connections = 20  
> connection\_timeout = 60  
> zeroconf = Mopidy MPD server on $hostname  
> command\_blacklist =  
> listall
> 
> listallinfo  
> default\_playlist\_scheme = m3u
> 
> [local]  
> enabled = true  
> max\_search\_results = 100  
> media\_dir = /media/nasmusic/  
> scan\_timeout = 5000  
> scan\_flush\_threshold = 100  
> scan\_follow\_symlinks = false  
> included\_file\_extensions =  
> .flac  
> .mp3  
> .aac  
> .m4a  
> excluded\_file\_extensions =  
> .cue  
> .directory  
> .html  
> .jpeg  
> .jpg  
> .log  
> .nfo  
> .pdf  
> .png  
> .txt  
> .zip  
> directories =  
> Albums local:directory?type=album  
> Artists local:directory?type=artist  
> Composers local:directory?type=artist&role=composer  
> Genres local:directory?type=genre  
> Performers local:directory?type=artist&role=performer  
> Release Years local:directory?type=date&format=%25Y  
> Tracks local:directory?type=track  
> Last Week’s Updates local:directory?max-age=604800  
> Last Month’s Updates local:directory?max-age=2592000  
> timeout = 10  
> use\_artist\_sortname = false  
> album\_art\_files =  
> \*.jpg  
> \*.jpeg  
> \*.png
> 
> [iris]  
> enabled = true

---

<div class="post-metadata">

**Author:** ![m-hoefling](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.mopidy.com/m-hoefling/32/1899_2.png) [@m-hoefling](https://discourse.mopidy.com/u/m-hoefling)\
**Post date:** [March 27, 2021, 11:55am UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/7 "2021-03-27T11:55:40Z")

</div>

regarding your 2nd question:  
Previously i had everything organized by and with iTunes (shame on me) so also my playlists originate from there.  
While “migrating” i did the following:  
a) configure modipy to use the files from the same location/folder structure itunes did  
b) write a script to extract the playlists from itunes xml and translate them into m3u8 by basically manipulating the path.

b) works for majority of the files, but there seems to be a special case if have not found yet and i am trying to investigate.

---

<div class="post-metadata">

**Author:** ![kingosticks](https://avatars.discourse-cdn.com/v4/letter/k/858c86/32.png) [@kingosticks](https://discourse.mopidy.com/u/kingosticks)\
**Post date:** [March 27, 2021, 1:30pm UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/8 "2021-03-27T13:30:21Z")

</div>

So, you created the paths within your playlist files yourself? They were not given to you by Mopidy?

What happens when you try to find these troublesome tracks by using the Browse methods and the look at their actual Uri?

---

<div class="post-metadata">

**Author:** ![m-hoefling](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.mopidy.com/m-hoefling/32/1899_2.png) [@m-hoefling](https://discourse.mopidy.com/u/m-hoefling)\
**Post date:** [March 27, 2021, 1:53pm UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/9 "2021-03-27T13:53:17Z")

</div>

yes, i created myself and verified existens/correctness of the path in my python script with e.g. os.path.isfile() - but looks like this check is not sufficient.

> BAD:  
> local:track:GEORGE%20MICHAEL/Unknown%20Album/FAITH%201.mp3  
> OK:  
> local:track:George%20Michael/Unknown%20Album/FAITH%201.mp3
> 
> BAD:  
> local:track:Foreigner/Unknown%20Album/Cold%20as%20Ice.mp3  
> OK:  
> local:track:FOREIGNER/Unknown%20Album/Cold%20as%20Ice.mp3
> 
> OK:  
> local:track:Foo%20Fighters/Greatest%20Hits/14%20Wheels.mp3

so it looks like randomly UPPERCASE is working/not working and i have to catch this in my m3u8 generation script. I still do not get why the os.path.isfile() check is not catching these troublesome tracks - i have to further investigate.

---

<div class="post-metadata">

**Author:** ![kingosticks](https://avatars.discourse-cdn.com/v4/letter/k/858c86/32.png) [@kingosticks](https://discourse.mopidy.com/u/kingosticks)\
**Post date:** [March 27, 2021, 2:13pm UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/10 "2021-03-27T14:13:13Z")

</div>

The other you can do is, other than verify the URIs using Mopidy’s browsing functionality, is ensure they were actually added to the Local database when you scanned. It should error for tracks it cant add for some reason. You can also verify the scanning with [this](https://docs.mopidy.com/en/develop/troubleshooting/#track-metadata).

In general we suggest people don’t try to generate URIs themselves but with playlists that idea breaks down pretty quickly.

---

<div class="post-metadata">

**Author:** ![m-hoefling](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.mopidy.com/m-hoefling/32/1899_2.png) [@m-hoefling](https://discourse.mopidy.com/u/m-hoefling)\
**Post date:** [March 27, 2021, 2:19pm UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/11 "2021-03-27T14:19:07Z")

</div>

Thanks @kingosticks, i will go that way.

One final question - is there a way to get all uris known to mopidy?  
1st think is to remove the troublesome uris (i will use your proposed solution)  
2nd would be to replace them with proper ones - question then is what is known to mopidy.

# EDIT:

Okay, no stuff is getting strange - local scan - in contrast to something different in the chain - seems to be NOT case-sensitive and i am not able to filter troublesome uris with this approach. see output below.

I am currently trying to check the same using Mopidy’s browsing functionality as suggested. But i am new to the code and not yet clear how to do so. Is there an easy way to include this functionality in a script for testing?

## troublesome uri from above

> pi@pimusic:~ $ python3 -m mopidy.audio.scan file:///media/nasmusic/GEORGE%20MICHAEL/Unknown%20Album/FAITH%201.mp3  
> 2021-03-27 16:25:57,791 TRACE element decodebin0: have-audio;  
> 2021-03-27 16:25:57,794 TRACE element fakesink0: GstMessageTag, taglist=(taglist)"taglist,\ title=(string)FAITH,\ artist...  
> 2021-03-27 16:25:57,795 TRACE element fakesink0: GstMessageTag, taglist=(taglist)"taglist,\ title=(string)FAITH,\ artist...  
> 2021-03-27 16:25:57,796 TRACE element pipeline0: GstMessageAsyncDone, running-time=(guint64)18446744073709551615;  
> 2021-03-27 16:25:57,797 DEBUG Using workaround for duration missing before play.  
> 2021-03-27 16:25:57,800 TRACE element fakesink0: GstMessageTag, taglist=(taglist)"taglist,\ title=(string)FAITH,\ artist...  
> 2021-03-27 16:25:57,801 TRACE element fakesink0: GstMessageTag, taglist=(taglist)"taglist,\ title=(string)FAITH,\ artist...  
> 2021-03-27 16:25:57,813 TRACE element mpegaudioparse0: GstMessageDurationChanged;  
> uri file:///media/nasmusic/GEORGE%20MICHAEL/Unknown%20Album/FAITH%201.mp3  
> mime None  
> duration 157956  
> playable True  
> seekable True  
> tags  
> title [‘FAITH’]  
> artist [‘GEORGE MICHAEL’]  
> datetime [‘0019’]  
> genre [‘disco’]  
> container-format [‘ID3 tag’]  
> extended-comment ['iTunNORM[en]= 0000014B 0000017D 00001EE1 00001632 00…  
> has-crc [False]  
> channel-mode [‘joint-stereo’]  
> audio-codec [‘MPEG-1 Layer 3 (MP3)’]  
> nominal-bitrate [112000]  
> minimum-bitrate [111781]  
> maximum-bitrate [112087]  
> bitrate [111985]

## working uri from above

> pi@pimusic:~ $ python3 -m mopidy.audio.scan file:///media/nasmusic/George%20Michael/Unknown%20Album/FAITH%201.mp3  
> 2021-03-27 16:27:06,278 TRACE element decodebin0: have-audio;  
> 2021-03-27 16:27:06,281 TRACE element fakesink0: GstMessageTag, taglist=(taglist)"taglist,\ title=(string)FAITH,\ artist...  
> 2021-03-27 16:27:06,282 TRACE element fakesink0: GstMessageTag, taglist=(taglist)"taglist,\ title=(string)FAITH,\ artist...  
> 2021-03-27 16:27:06,283 TRACE element pipeline0: GstMessageAsyncDone, running-time=(guint64)18446744073709551615;  
> 2021-03-27 16:27:06,284 DEBUG Using workaround for duration missing before play.  
> 2021-03-27 16:27:06,286 TRACE element fakesink0: GstMessageTag, taglist=(taglist)"taglist,\ title=(string)FAITH,\ artist...  
> 2021-03-27 16:27:06,288 TRACE element fakesink0: GstMessageTag, taglist=(taglist)"taglist,\ title=(string)FAITH,\ artist...  
> 2021-03-27 16:27:06,299 TRACE element mpegaudioparse0: GstMessageDurationChanged;  
> uri file:///media/nasmusic/George%20Michael/Unknown%20Album/FAITH%201.mp3  
> mime None  
> duration 157956  
> playable True  
> seekable True  
> tags  
> title [‘FAITH’]  
> artist [‘GEORGE MICHAEL’]  
> datetime [‘0019’]  
> genre [‘disco’]  
> container-format [‘ID3 tag’]  
> extended-comment ['iTunNORM[en]= 0000014B 0000017D 00001EE1 00001632 00…  
> has-crc [False]  
> channel-mode [‘joint-stereo’]  
> audio-codec [‘MPEG-1 Layer 3 (MP3)’]  
> nominal-bitrate [112000]  
> minimum-bitrate [111781]

---

<div class="post-metadata">

**Author:** ![kingosticks](https://avatars.discourse-cdn.com/v4/letter/k/858c86/32.png) [@kingosticks](https://discourse.mopidy.com/u/kingosticks)\
**Post date:** [March 27, 2021, 6:18pm UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/12 "2021-03-27T18:18:39Z")

</div>

When Mopidy-Local scans the filesystem, the Track uris it creates and inserts into the database match what the filesystem provided it with. The `lookup(uri)` that happens when adding to the tracklist is case-sensitive and so the uri you provide must match the actual path on the filesystem exactly.

On a regular Linux system with a common case-sensitive filesystem (e.g. ext3, ext4 etc), Mopidy’s `lookup` behaviour matches the filesystem behaviour, and `os.path.isfile(x) != os.path.isfile(x.upper())`. But network drives are sometimes formatted with a more Windows-like case-insensitive filesystem (such as FAT32). Mounting and using that on linux get you `os.path.isfile(x) == os.path.isfile(x.upper())`. Could this be what you are seeing?

> I am currently trying to check the same using Mopidy’s browsing functionality as suggested. But i am new to the code and not yet clear how to do so. Is there an easy way to include this functionality in a script for testing?

Most web clients and MPD clients already support Mopidy’s browse functionality. `mpc` is simplest:

```auto
mpc ls "Local media/Artists/GEORGE MICHAEL"

```

> One final question - is there a way to get all uris known to mopidy?

```auto
mpc ls "Local media/Tracks"

```

---

<div class="post-metadata">

**Author:** ![system](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.mopidy.com/system/32/1_2.png) [@system](https://discourse.mopidy.com/u/system)\
**Post date:** [September 26, 2021, 6:18am UTC](https://discourse.mopidy.com/t/failed-to-add-some-tracks-in-iris-what-could-be-the-reason/4839/13 "2021-09-26T06:18:45Z")

</div>

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.
