After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 314021 - Add "View Statistics" command
Add "View Statistics" command
Status: RESOLVED OBSOLETE
Product: rhythmbox
Classification: Other
Component: Plugins (other)
0.9.x
Other Linux
: Normal enhancement
: ---
Assigned To: RhythmBox Maintainers
RhythmBox Maintainers
: 461981 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2005-08-20 10:52 UTC by James "Doc" Livingston
Modified: 2018-05-24 10:46 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Adds a statistics plugin (33.39 KB, patch)
2009-05-12 21:21 UTC, Thorsten Sick
needs-work Details | Review

Description James "Doc" Livingston 2005-08-20 10:52:38 UTC
What would be nice is if Rhythmbox has a "View Statistics" command (probably in
the View menu). It would probably bring up a window with choices for "Top
Songs", "Top Artists", "Top Albums" and others. The "Top Songs" is relatively
trivial, just giving the N most played songs, and the Top Artist/Album would
sort by total playcount of the songs by the artist/on the album.

Other options that some players or things like last.fm/audioscrobber have:
* "Top X in the last week/month", which would require RB to keep more playback
details that it currently does (namely, the time of every playback).
* Recently played songs


Some things that would also be nice:
* being able to drag tracks/artist/albums from the window into a playlist
* "Browse this Artist/Album" in a context menu
* being able to drag artists/albums to the source list to create playlists
* indication of how many songs from artist/album
* average rating of songs from artist/album
Comment 1 Alex Lancaster 2006-04-11 10:17:03 UTC
Probably should be a plugin?
Comment 2 James "Doc" Livingston 2006-04-11 10:40:48 UTC
Part of the AudioScrobbler Plugin?
Comment 3 Peter 2006-07-05 18:53:24 UTC
Regarding your list of "Some things that would also be nice",

* "Top X in the last week/month", which would require RB to keep more playback
details that it currently does (namely, the time of every playback).

Nice...

* Recently played songs

You can get this indirectly using an automatic playlist

* being able to drag tracks/artist/albums from the window into a playlist

That works for me from the library and from other playlists

* "Browse this Artist/Album" in a context menu

That works for me in the library

* being able to drag artists/albums to the source list to create playlists

That works for me, playlist name defaults to the artist/album name.

* indication of how many songs from artist/album

That works for me on the library view

* average rating of songs from artist/album

Interesting idea...

Regarding comment 2 see bug 345957 for viewing your last.fm profile as an enhancement to the AudioScrobbler Plugin.

Comment 4 Sven Arvidsson 2008-06-20 22:37:04 UTC
*** Bug 461981 has been marked as a duplicate of this bug. ***
Comment 5 Sven Arvidsson 2008-06-20 22:40:34 UTC
The same request was made in a downstream bug report to Debian, see
http://bugs.debian.org/486206

The submitter mentioned that the Jajuk player has a statistics view and nice
pie charts which could surve as inspiration...
http://www.jajuk.info/index.php/Screenshots#Statistics_perspective
Comment 6 Thorsten Sick 2009-05-12 21:21:03 UTC
Created attachment 134531 [details] [review]
Adds a statistics plugin

The statistics plugin contains the most essential statistical information (average rating album/artist). It has a notebook and can be enhanced easily. Please test and enjoy
Comment 7 Seemanta Dutta 2009-06-02 06:34:17 UTC
I shall test is today and let you know my comments.
Comment 8 Seemanta Dutta 2009-06-02 19:13:46 UTC
Getting some patch errors while trying it out on the HEAD with the git-am command.


$ git am 0001-Starting-Statistics-plugin-Bug-314021.patch
Applying: Starting Statistics plugin (Bug 314021)
/home/seemanta/gnomedev/rhythmbox/.git/rebase-apply/patch:24: trailing whitespace.
      </schema>     
/home/seemanta/gnomedev/rhythmbox/.git/rebase-apply/patch:46: trailing whitespace.
      </schema>       
/home/seemanta/gnomedev/rhythmbox/.git/rebase-apply/patch:58: trailing whitespace.
	visualizer                                     
/home/seemanta/gnomedev/rhythmbox/.git/rebase-apply/patch:482: trailing whitespace.
- Average rating album/artist           
/home/seemanta/gnomedev/rhythmbox/.git/rebase-apply/patch:483: trailing whitespace.
- number of songs    
error: data/rhythmbox.schemas: does not match index
error: plugins/Makefile.am: does not match index
error: plugins/statistics/Makefile.am: already exists in working directory
error: plugins/statistics/statistics-ui.xml: already exists in working directory
error: plugins/statistics/statistics.rb-plugin.in: already exists in working directory
error: plugins/statistics/statistics/Makefile.am: already exists in working directory
error: plugins/statistics/statistics/__init__.py: already exists in working directory
Patch failed at 0001.
When you have resolved this problem run "git am --resolved".
If you would prefer to skip this patch, instead run "git am --skip".
To restore the original branch and stop patching run "git am --abort".


Can anyone help?


Comment 9 Jonathan Matthew 2010-01-02 01:39:21 UTC
Review of attachment 134531 [details] [review]:

Sorry it took so long for me to take a look at this.. hopefully you're still interested in working on it.  It looks like a reasonable start, but I'd like it to do a bit more before I'd think about including it in rhythmbox.  Specifically, I think the 'basic' tab should be a bit less basic - instead of a single favorite song, a top 5 or so; and similar lists for albums and artists; maybe a simple graph of rating distribution.

The average rating tabs should exclude 'unknown' artists and albums, since an average rating across those doesn't mean much.

If we're going to include something like the '16963 Bohemian Rhapsodies' statistic, I'd rather we had a list of non-musical things to compare it to.  Lifespans of various species, football games, transatlantic plane flights, other trivia.  As it is, it gives a vague idea of the average song length, but with a largeish library the numbers you get are meaningless, so we need something longer.  Having an 'average song length' statistic would also be useful, of course.

It might be worth looking at displaying statistics inside the main window, rather than as a separate window.  Might get a bit ugly though.

::: plugins/statistics/Makefile.am
@@ +12,3 @@
+
+uixmldir = $(plugindir)
+uixml_DATA = statistics-ui.xml

For consistency with other plugins, the makefile variables should be called gtkbuilderdir and gtkbuilder_DATA

The gtkbuilder file should be called statistics.ui, too.  We name GTK UI manager XML files *-ui.xml, but these are different to GTKBuilder files.

::: plugins/statistics/statistics-ui.xml
@@ +1,3 @@
+<?xml version="1.0"?>
+<interface>
+  <requires lib="gtk+" version="2.16"/>

GTK version should be set to 2.14.

@@ +137,3 @@
+                    <property name="visible">True</property>
+                    <property name="xalign">0</property>
+                    <property name="label" translatable="yes">foobar</property>

This should be empty

@@ +186,3 @@
+                      <object class="GtkLabel" id="label_info">
+                        <property name="visible">True</property>
+                        <property name="label" translatable="yes">The average rating for each album. A song with 0 points is handled as not rated and does not count.</property>

I don't think we need this explanation, really.. if we do, it shouldn't be hidden inside an expander.  We typically describe ratings in terms of stars, not points.

@@ +209,3 @@
+              <object class="GtkLabel" id="label2">
+                <property name="visible">True</property>
+                <property name="label" translatable="yes">Average  album rating</property>

Extra space after 'average'

::: plugins/statistics/statistics/__init__.py
@@ +25,3 @@
+
+"""
+This plugin for rythmbox creates song statistics and shows them.

'Rhythmbox' is misspelled here

@@ +42,3 @@
+This should fix the bug
+314021
+http://bugzilla.gnome.org/show_bug.cgi?id=314021

No need to include bug references when they don't really provide any information.

@@ +79,3 @@
+        self.db.query_append(query, (rhythmdb.QUERY_PROP_EQUALS, rhythmdb.PROP_TYPE, song_type))
+        query_model = self.db.query_model_new_empty()
+        self.db.do_full_query_parsed(query_model, query)

I think it'd be easier (and faster) to find the library source and get the base-query-model property from it, which already contains all song entries.
Comment 10 GNOME Infrastructure Team 2018-05-24 10:46:41 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/rhythmbox/issues/70.