Bug 16140 - Library stats reporting fails for album within Genre > Various Artists
: Library stats reporting fails for album within Genre > Various Artists
Status: RESOLVED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Web Interface
: 7.5.0
: PC Windows XP
: P2 normal (vote)
: 7.5.1
Assigned To: Andy Grundman
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-04-25 02:51 UTC by Philip Meyer
Modified: 2010-04-29 11:18 UTC (History)
2 users (show)

See Also:
Category: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Philip Meyer 2010-04-25 02:51:15 UTC
I updated 7.5/trunk revision 30686.

Upon restarting server, in the Web UI I tried to Browse Genres > Blues > Various Artists > Blues Legends.

[As an aside, clicking on Various Artists for genre Blues seemed to take quite some time (~ 10 seconds)]

Clicking on an album within Various Artists throws an exception (see below) - looks like it is to do with calculating the "n albums with n songs by n artists" stats at the bottom of the browse page, as this appears to be blank.

If I browse to Artists > Various Artists > [any album], this doesn't throw the exception, and does report the album/songs/artists stats.


[23:38:42.3257] Slim::Schema::Storage::throw_exception (82) Error: DBI Exception: DBD::mysql::st execute failed: Unknown column 'contributorTracks.role' in 'where clause' [for Statement "SELECT COUNT( * ) FROM (SELECT contributor.id FROM albums me JOIN tracks tracks ON tracks.album = me.id LEFT JOIN genre_track genreTracks ON genreTracks.track = tracks.id JOIN albums album ON album.id = tracks.album JOIN contributors contributor ON contributor.id = album.contributor WHERE ( ( contributorTracks.role IN ( ?, ?, ?, ?, ? ) AND ( genreTracks.genre = ? AND me.compilation = ? AND me.id = ? ) ) ) GROUP BY contributor.id) count_subq"]
[23:38:42.3272] Slim::Schema::Storage::throw_exception (82) Backtrace:

   frame 0: Slim::Utils::Log::logBacktrace (P:/Music/SlimServer/trunk/server/Slim/Schema/Storage.pm line 82)
   frame 1: Slim::Schema::Storage::throw_exception (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/Storage/DBI.pm line 957)
   frame 2: DBIx::Class::Storage::DBI::__ANON__ (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/Storage/DBI.pm line 1217)
   frame 3: DBIx::Class::Storage::DBI::_dbh_execute (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/Storage/DBI.pm line 532)
   frame 4: DBIx::Class::Storage::DBI::dbh_do (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/Storage/DBI.pm line 1227)
   frame 5: DBIx::Class::Storage::DBI::_execute (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/Storage/DBI.pm line 1451)
   frame 6: DBIx::Class::Storage::DBI::_select (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/Storage/DBI/Cursor.pm line 82)
   frame 7: DBIx::Class::Storage::DBI::Cursor::_dbh_next (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/Storage/DBI.pm line 547)
   frame 8: (eval) (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/Storage/DBI.pm line 540)
   frame 9: DBIx::Class::Storage::DBI::dbh_do (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/Storage/DBI/Cursor.pm line 101)
   frame 10: DBIx::Class::Storage::DBI::Cursor::next (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/ResultSetColumn.pm line 128)
   frame 11: DBIx::Class::ResultSetColumn::next (P:\Music\SlimServer\trunk\server\CPAN/DBIx/Class/ResultSet.pm line 1181)
   frame 12: DBIx::Class::ResultSet::count (P:/Music/SlimServer/trunk/server/Slim/Web/Pages/Common.pm line 162)
   frame 13: (eval) (P:/Music/SlimServer/trunk/server/Slim/Web/Pages/Common.pm line 159)
   frame 14: Slim::Web::Pages::Common::addLibraryStats (P:/Music/SlimServer/trunk/server/Slim/Web/Pages/BrowseDB.pm line 513)
   frame 15: Slim::Web::Pages::BrowseDB::browsedb (P:/Music/SlimServer/trunk/server/Slim/Web/HTTP.pm line 1097)
   frame 16: Slim::Web::HTTP::generateHTTPResponse (P:/Music/SlimServer/trunk/server/Slim/Web/HTTP.pm line 924)
   frame 17: Slim::Web::HTTP::processURL (P:/Music/SlimServer/trunk/server/Slim/Web/HTTP.pm line 735)
   frame 18: Slim::Web::HTTP::processHTTP (P:/Music/SlimServer/trunk/server/Slim/Networking/IO/Select.pm line 139)
   frame 19: (eval) (P:/Music/SlimServer/trunk/server/Slim/Networking/IO/Select.pm line 123)
   frame 20: Slim::Networking::IO::Select::__ANON__ (P:/Music/SlimServer/trunk/server/Slim/Networking/IO/Select.pm line 183)
   frame 21: (eval) (P:/Music/SlimServer/trunk/server/Slim/Networking/IO/Select.pm line 183)
   frame 22: Slim::Networking::IO::Select::loop (P:\Music\SlimServer\trunk\server\slimserver.pl line 626)
   frame 23: main::idle (P:\Music\SlimServer\trunk\server\slimserver.pl line 580)
   frame 24: main::main (P:\Music\SlimServer\trunk\server\slimserver.pl line 1072)


I don't often browse various artists via a specific genre, so perhaps this has been broken for a while?  I assume that it should report stats if browsed in this way, and the query is just a bit wrong?
Comment 1 Jim McAtee 2010-04-25 02:55:58 UTC
I see this error in both 7.5 trunk and 7.6 trunk.
Comment 2 SVN Bot 2010-04-29 11:18:00 UTC
 == Auto-comment from SVN commit #30714 to the slim repo by agrundman ==
 == http://svn.slimdevices.com/slim?view=revision&revision=30714 ==

Fixed bug 16140, library stats was broken under Genre -> Various Artsits -> Album