Bug 489856 - collection scanner fails/no files displayed
Summary: collection scanner fails/no files displayed
Status: RESOLVED WORKSFORME
Alias: None
Product: amarok
Classification: Applications
Component: Collections/Local (show other bugs)
Version: 3.0.1
Platform: Ubuntu Linux
: NOR major
Target Milestone: kf5
Assignee: Amarok Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-07-07 03:47 UTC by bob@mroczka.com
Modified: 2025-03-22 03:46 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description bob@mroczka.com 2024-07-07 03:47:38 UTC
SUMMARY
When I attempt to scan my local audio files the scanner completes but no files are shown in the local music browser.  I attempted to run the scanner from command line with same options and it finishes successfully so it is not clear what the underlying issue is.

STEPS TO REPRODUCE
1. add folder to scan
2. 
3. 

OBSERVED RESULT
No audio files displayed

EXPECTED RESULT
The scanner to allow searching of local audio file collection.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
Ubuntu 22.04.4 LTS 
Amarok Version 3.0.1-git

KDE Plasma Version: 5.24.7
KDE Frameworks Version: 5.92.0
Qt Version: 5

ADDITIONAL INFORMATION
Comment 1 Tuomas Nurmi 2024-07-07 07:16:27 UTC
Thank you for report! I'm not that familiar with scanner internals yet, but let's see if I'll figure it out in process.

Is this a problem with a fresh new installation (I take from the description that this is the case), or did you have previous Amarok data and the scanner stopped working? I guess you could try (backupping+)clearing ~/.local/share/amarok and ~/.config/amarokrc.

Can you try running `amarok --debug`, starting a scan and seeing if there seems to be anything scan problem related in output? (Possibly trying full rescan from settings -> collection settings)

I think it's also possible to run collection scanner manually, saving the output to xml file and importing it from collection settings. It could be interesting to know if that works (or if not, what kind of errors are visible in debug output)
Comment 2 bob@mroczka.com 2024-12-01 03:03:45 UTC
amarok --debug show the scan completing ok but the collection does not show any files (0 tracks).  The scan takes about 37 seconds.  If I run the scanner from the command line and output the xml to a file and attempt to import the file I get the message "Failed: No tracks were imported".  Here is the output from amarok --debug at the bottom that shows the scan result.

amarok:   END__: virtual void AbstractScanResultProcessor::scanSucceeded() [Took: 0.37s]
amarok:   BEGIN: void SqlScanResultProcessor::unblockUpdates()
amarok:     BEGIN: void Amarok2ConfigDialog::updateButtons()
amarok:       BEGIN: virtual bool Amarok2ConfigDialog::hasChanged()
amarok:         BEGIN: virtual bool CollectionConfig::hasChanged()
amarok:         END__: virtual bool CollectionConfig::hasChanged() [Took: 0s]
amarok:         [ConfigDialog] Changed:  MetadataConfig
amarok:         BEGIN: virtual bool NotificationsConfig::hasChanged()
amarok:         END__: virtual bool NotificationsConfig::hasChanged() [Took: 0s]
amarok:       END__: virtual bool Amarok2ConfigDialog::hasChanged() [Took: 0s]
amarok:     END__: void Amarok2ConfigDialog::updateButtons() [Took: 0s]
amarok:   END__: void SqlScanResultProcessor::unblockUpdates() [Took: 0.003s]
amarok: END__: virtual void SqlScanResultProcessor::scanSucceeded() [Took: 0.38s]
Comment 3 Tuomas Nurmi 2025-01-06 09:32:51 UTC
Okay. If you try running

amarokcollectionscanner --recursive .

in your collection directory, what kind of output does it show?
There are probably entries like

<directory>
        <path>/home/user/musicdir/</path>
        <rpath>.</rpath>
        <mtime>1700480163</mtime>

for directories and, with <track> entries inside for successfully scanned tags; and probably something like "FileTypeResolver: file /home/user/musicdir/filename (mimetype application/octet-stream) not recognized as Amarok-compatible" for any files the scanner fails to handle.
Comment 4 Tuomas Nurmi 2025-02-20 05:44:54 UTC
Waiting for info on
amarokcollectionscanner --recursive .
output, marking status as such
Comment 5 Bug Janitor Service 2025-03-07 03:47:42 UTC
🐛🧹 ⚠️ This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information, then set the bug status to REPORTED. If there is no change for at least 30 days, it will be automatically closed as RESOLVED WORKSFORME.

For more information about our bug triaging procedures, please read https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging.

Thank you for helping us make KDE software even better for everyone!
Comment 6 Bug Janitor Service 2025-03-22 03:46:42 UTC
🐛🧹 This bug has been in NEEDSINFO status with no change for at least 30 days. Closing as RESOLVED WORKSFORME.