316 Commits

Author SHA1 Message Date
Deluan
e4bcb90672
Only import playlists from configured paths in option PlaylistsPath. Closes #1181
Syntax is Ant-style Globs, with support for '**' (any subfolder). Default: '.:**' (or '.;**' in Windows`, meaning all folders and subfolders under `MusicFolder`
2026-01-02 20:06:54 +00:00
caiocotts
4f35ec6dae
Use wchar_t for TagLib filenames on Windows (#1310)
* Use wchar_t for tagLib filenames on Windows

* Make TagLib default extractor for all platforms.

* Organize imports

Co-authored-by: Deluan <deluan@navidrome.org>
2026-01-02 20:06:33 +00:00
Deluan
b96344ca93
Some small refactorings 2026-01-02 20:06:13 +00:00
Deluan
19e1553dbe
Import song duration with hundredths when using TagLib
This is how ffmpeg extractor currently works, and it makes album durations more precise.
2026-01-02 20:06:12 +00:00
caio
bf706177d0
Support local paths as urls in playlists. 2026-01-02 20:06:11 +00:00
Deluan
a62472af7b
Fix build 2026-01-02 20:06:10 +00:00
Deluan
79dfba80cb
Use ffmpeg extractor by default on Windows
This is to avoid issue with unicode chars in filenames. See #810
2026-01-02 20:06:10 +00:00
Deluan
4f43c6bec5
Reorganize metadata extractors code 2026-01-02 20:06:10 +00:00
Deluan
dc717c62f1
Use TagLib to detect whether a media file has embedded cover or not 2026-01-02 20:06:10 +00:00
Deluan
442497ae5f
Change fallback extractor to taglib, the default option 2026-01-02 20:06:10 +00:00
Deluan
3202d01f4d
Reduce number of calls to lstat.
Should make the scanner a bit faster, specially in networked filesystems
2026-01-02 20:06:10 +00:00
Deluan
e63769051f
Remove dependency of deprecated ioutil package 2026-01-02 20:06:10 +00:00
Deluan
03e7edc427
Fix multiple id3v2.4 genres appearing as one big concatenated genre 2026-01-02 20:06:09 +00:00
Deluan
033be045c0
Add more tests 2026-01-02 20:06:09 +00:00
Deluan
41a7468876
Fix lint error 2026-01-02 20:06:08 +00:00
Deluan
1e9e8edc49
Add multiple genres to MediaFile 2026-01-02 20:06:08 +00:00
Deluan
52510a55c4
Add genre tables, read multiple-genres from tags 2026-01-02 20:06:08 +00:00
Deluan
ce8a1c9cec
Fix forceRescan not re-importing all tracks 2026-01-02 20:06:07 +00:00
Deluan
5e246e3d2d
Reapply the fix from #1054, but without getting into an infinite look in case of SMB fs errors. See #1164 2026-01-02 20:06:07 +00:00
Deluan
44fb753b61
Fix infinite loop when the fs fails. Closes #1164 2026-01-02 20:06:07 +00:00
Deluan
19e9ec46a2
Use AlbumArtist tag even for compilations, when it is specified.
If the tracks' AlbumArtists are different, then use "Various Artists"
2026-01-02 20:06:07 +00:00
Deluan
39623748f2
Fix deadlock situation when events are sent too fast to the broker 2026-01-02 20:05:07 +00:00
Deluan
8e32b56ea0
Only send events to clients who need it
- User events (star, rating, plays) only sent to same user
- Don't send to the client (browser window) that originated the event
2026-01-02 20:02:35 +00:00
Deluan
ec02ddf624
Less warning messages when first running it.
They are actually `info` messages
2026-01-02 20:02:34 +00:00
Deluan
2e645a3191
Trigger a UI refresh when the scanner finds changes.
Closes #1025
2026-01-02 19:32:17 +00:00
Deluan
7ddf96904f
Don't panic when taglib returns an error 2026-01-02 19:31:52 +00:00
Deluan
eeeb98adb5
Foundational work to enable multi-valued tags 2026-01-02 19:31:52 +00:00
Deluan
4dd0ebf571
Remove C++11 warning in macOS 2026-01-02 19:31:10 +00:00
Deluan
26b52a49ee
Fix test 2026-01-02 19:31:10 +00:00
Deluan
fbfe1af318
Upgrade TagLib to 1.12 2026-01-02 19:31:10 +00:00
Deluan
d2d780918b
Breaking change: Add ScanSchedule, allows interval and cron based configurations.
See https://pkg.go.dev/github.com/robfig/cron#hdr-CRON_Expression_Format for expression syntax.

`ScanInterval` will still work for the time being. The only situation it does not work is when you want to disable periodic scanning by setting `ScanInterval=0`. If you want to disable it, please set `ScanSchedule=""`

Closes #1085
2026-01-02 19:26:43 +00:00
Brian Schrameck
4264a5c6ef
BPM metadata enhancement (#1087)
* BPM metadata enhancement

Related to #1036.

Adds BPM to the stored metadata about MediaFiles.

Displays BPM in the following locations:
- Listing songs in the song list (desktop, sortable)
- Listing songs in playlists (desktop, sortable)
- Listing songs in albums (desktop)
- Expanding song details

When listing, shows a blank field if no BPM is present. When showing song details, shows a question mark.

Updates test MP3 file to have BPM tag. Updated test to ensure tag is read correctly.

Updated localization files. Most languages just use "BPM" as discovered during research on Wikipedia. However, a couple use some different nomenclature. Spanish uses PPM and Japanese uses M.M.

* Enhances support for BPM metadata extraction

- Supports reading floating point BPM (still storing it as an integer) and FFmpeg as the extractor
- Replaces existing .ogg test file with one that shouldn't fail randomly
- Adds supporting tests for both FFmpeg and TagLib

* Addresses various issues with PR #1087.

- Adds index for BPM. Removes drop column as it's not supported by SQLite (duh).
- Removes localizations for BPM as those will be done in POEditor.
- Moves BPM before Comment in Song Details and removes BPM altogether if it's empty.
- Omits empty BPM in JSON responses, eliminating need for FunctionField.
- Fixes copy/paste error in ffmpeg_test.
2026-01-02 19:26:43 +00:00
Deluan
e05468d2dc
FIx ffmpeg output regex too rigid 2026-01-02 19:26:43 +00:00
Deluan
ff0f8a01d7
Fix cover art detection with ffmpeg 4.4 2026-01-02 19:26:42 +00:00
Deluan
ddae77c3ac
Fix SIGUSR1 work when ScanInterval=0 2026-01-02 19:26:41 +00:00
whorfin
35aa640cfe
Improve scanner (#1054)
* Handle subdirectories without rx permission correctly
Allow ogg files w/o metadata, having taglib behave more like ffmpeg

* Fix test for walk_dir_tree, fix full reading of files in permission-
constrained directories, allow directories with leading ellipses

* Sorted directory traversal is preferred, and cleanup tests

* Small refactoring to clean-up `loadDir` function and to remove some "warnings" from IntelliJ

Co-authored-by: Deluan <deluan@navidrome.org>
2026-01-02 19:26:41 +00:00
Deluan
cc6d1fcca9
Fix build tag 2026-01-02 19:26:39 +00:00
Deluan
deb9ceb3c9
Disable SIGUSR1 handler for Windows (not available) 2026-01-02 19:26:39 +00:00
Deluan
5efc88904f
Add trigger scan when receiving SIGUSR1 signal 2026-01-02 19:26:39 +00:00
Deluan
a881b7d667
Comment out flaky tests 2026-01-02 19:22:07 +00:00
Deluan
77e31b27b9
Add option to sort Recently Added by file's mtime instead of time of import. 2026-01-02 19:22:06 +00:00
Deluan
10cf2372f8
Move project to Navidrome GitHub organization 2026-01-02 19:20:16 +00:00
Deluan
971728dfd5
Replace periodic scanner cancellation channel with a context 2026-01-02 19:20:13 +00:00
Deluan
8313d6fe97
Fix log message, as it is also used for taglib 2026-01-02 19:20:12 +00:00
Deluan
ad8dc26f9c
Error should always be nil 2026-01-02 19:20:11 +00:00
Deluan
e0dbf1972a
Add elapsed time when scanner does not detect any new changes 2026-01-02 19:20:11 +00:00
Deluan
bed1410e0d
Disconnect the client if the output buffer fills up 2026-01-02 19:20:11 +00:00
Deluan
9f056dcf97
Fix logging field case 2026-01-02 19:20:10 +00:00
Deluan
a0195aa5d3
Better termination handling in Scanner's progress 2026-01-02 19:20:08 +00:00
Deluan
70dc847836
Show folders scanned instead of files scanned 2026-01-02 19:20:05 +00:00