Manually adding content to media directory

Hi all,
I’m running Mopidy 3.4.1 on a Pi 4B with Debian Bookworm. My setup all works and I’m enjoying this great software!

One issue… I have some DTS CDs (DTS 5.1 audio encoded to look like a CD). Mopidy won’t play them directly but I have a script of GStreamer pipelines to decode the dts files to pcm and then encoded them as flac files - these are playable by Mopidy :).
I’m trying to incorporate these new flac files into my library.

I have:

  • Put 2 of these new flac files in my media directory. The structure is Artist / Album / Track.flac . Example in my media_dir: /Wings/Band on the Run/02 - Jet.flac
  • Run sudo mopidyctl local clear
  • Run sudo mopidyctl local scan
  • Run sudo systemctl restart mopidy
    One of these files is called ‘02 - Jet.flac’. The local scan finds it as shown in this snippet from the scan output:

DEBUG [MainThread] mopidy_local.storage Adding track: Track(last_modified=1721710733910, length=253306, uri=‘local:track:Wings/Band%20on%20the%20Run/02%20-%20Jet.flac’)
DEBUG [MainThread] mopidy_local.schema SQLite insert statement: INSERT OR REPLACE INTO track (uri, name, album, artists, composers, performers, genre, track_no, disc_no, date, length, bitrate, comment, musicbrainz_id, last_modified) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) dict_values([‘local:track:Wings/Band%20on%20the%20Run/02%20-%20Jet.flac’, ‘02 - Jet.flac’, None, None, None, None, None, None, None, None, 253306, None, None, None, 1721710733910])
DEBUG [MainThread] mopidy_local.commands Added local:track:Wings/Band%20on%20the%20Run/02%20-%20Jet.flac

There is no record of “Adding album” for “Band on the Run” in the log. Why would this be the case?
Consequence is that the Album does not appear in Iris.

The Track does appear in Iris.
The Artist “Wings” is added however, due to another album by the same band.

Thanks in advance,
Geoff.

my /etc/mopidy/mopidy.conf file is:
[http]
hostname = 0.0.0.0
[audio]
mixer_volume = 40
output = audioconvert ! audio/x-raw,rate=96000,channels=2,format=F64LE
! audioresample resample-method=kaiser sinc-filter-mode=full quality=10
! equalizer-10bands band0=+10.0 band1=+8.0 band2=+6.0 band3=+4.0 band4=2.0 band5=0.0 band6=+1.0 band7=+1.0 band8=+3.0 band9=+5.0
! audioconvert ! audio/x-raw,rate=96000,channels=2,format=S32LE
! filesink location=/run/snapserver/snapfifo
[file]
[local]
enabled = true
media_dir = /media/geoff/MEDIA/Music
included_file_extensions = .flac
[pandora]
enabled = true
api_host = tuner.pandora.com/services/json
partner_device = android-generic
partner_username = android
partner_password = AC7IBG09A3DTSYM4R41UJWL07VLN8JI7
partner_encryption_key = 6#26FRL$ZWD
partner_decryption_key = R=U!LH$O2B#
username = *******
password = *******
preferred_audio_quality = highQuality
[logging]
verbosity = 2

and sudo mopidyctl deps produces:
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.4.1
DEBUG [MainThread] mopidy.ext Loading entry point: iris = mopidy_iris:Extension
DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-Iris 3.69.3
DEBUG [MainThread] mopidy.ext Loading entry point: local = mopidy_local:Extension
DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-Local 3.2.1
DEBUG [MainThread] mopidy.ext Loading entry point: pandora = mopidy_pandora:Extension
DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-Pandora 1.1.1
DEBUG [MainThread] mopidy.ext Loading entry point: file = mopidy.file:Extension
DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-File 3.4.1
DEBUG [MainThread] mopidy.ext Loading entry point: http = mopidy.http:Extension
DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-HTTP 3.4.1
DEBUG [MainThread] mopidy.ext Loading entry point: m3u = mopidy.m3u:Extension
DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-M3U 3.4.1
DEBUG [MainThread] mopidy.ext Loading entry point: softwaremixer = mopidy.softwaremixer:Extension
DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-SoftwareMixer 3.4.1
DEBUG [MainThread] mopidy.ext Loading entry point: stream = mopidy.stream:Extension
DEBUG [MainThread] mopidy.ext Loaded extension: Mopidy-Stream 3.4.1
DEBUG [MainThread] mopidy.ext Discovered extensions: iris, local, pandora, file, http, m3u, softwaremixer, stream
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: iris
DEBUG [MainThread] mopidy.ext Validating extension: local
DEBUG [MainThread] mopidy.ext Validating extension: pandora
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
INFO [MainThread] mopidy.main Enabled extensions: http, pandora, iris, stream, local, softwaremixer, file, m3u

I wouldn’t expect to see an album “added” as such, everything revolves around tracks and everything else is determined from that. Adding tracks is what matters, and that’s working. I expect your problem is because when you re-encoded your tracks from CD to flac you lost (or never had) the correct track metadata. Tracks require proper metadata for them to be indexed correctly. If the metadata is missing, Mopidy will use the filename as the track name, you can see it did this here when it inserted track name ‘02 - Jet.flac’ instead of ‘Jet’. But it won’t know what to use for all the other metadata fields so they are empty (None).

There is help at Troubleshooting — Mopidy 3.4.2 documentation with this. You probably need to use a tagging program to add the correct metadata. Something like https://picard.musicbrainz.org/

Thanks for your help kingosticks - this is appreciated.
You will be right about the metadata. I converted the DTS CD files to PCM before creating the playable FLAC files.
Will get tagging software and fix em up.
Cheers,
Geoff.

Re-tagged the files using JRiver and now all good.
Thanks again,
Geoff

1 Like

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