GithubHelp home page GithubHelp logo

sublime-music / sublime-music Goto Github PK

View Code? Open in Web Editor NEW
89.0 1.0 9.0 21.29 MB

A native Gonic/Subsonic/Airsonic/*sonic client for Linux. Built using Python and GTK+.

Home Page: https://sublimemusic.app

License: GNU General Public License v3.0

Python 98.68% Makefile 0.04% Nix 0.42% CSS 0.84% HTML 0.02%
airsonic dbus gtk linux music native python subsonic subsonic-client gonic music-player navidrome

sublime-music's Introduction

Sublime Music Logo

Sublime Music is a native, GTK3 Subsonic/Airsonic/Revel/Gonic/Navidrome/Ampache/*sonic client for the Linux Desktop.

CI

Lint and Build

GitHub Pages

Community

GPLv3 or later

liberapay donate

Code

image

image

Packages

Packaging status


The Albums tab of Sublime Music with the Play Queue opened. More Screenshots

The Albums tab of Sublime Music with the Play Queue opened. More Screenshots

Features

  • Switch between multiple Subsonic-API-compliant1 servers.
  • Play music through Chromecast devices on the same LAN.
  • Offline Mode where Sublime Music will not make any network requests.
  • DBus MPRIS interface integration for controlling Sublime Music via clients such as playerctl, i3status-rust, KDE Connect, and many commonly used desktop environments.
  • Browse songs by the sever-reported filesystem structure, or view them organized by ID3 tags in the Albums, Artists, and Playlists views.
  • Intuitive play queue.
  • Create/delete/edit playlists.
  • Download songs for offline listening.

Installation

Via the AUR:

Install the sublime-music package_. Example using yay:

yay -S sublime-music

If you want support for storing passwords in the system keychain, also install python-keyring.

If you want support for playing on Chromecast devices, install python-pychromecast. If you want to serve cached files from your computer over the LAN to Chromecast devices also install python-bottle.

Via NixOS:

Sublime Music is part of the nixos-20.09 channel and newer (including nixos-unstable).

To install Sublime Music on NixOS, either use the declarative or the imperative way:

  • In configuration.nix (declarative):

    environment.systemPackages = [ pkgs.sublime-music ];
  • In command line (imperative):

    nix-env -iA sublime-music

To customize the extra components installed, you need to use the override function provided by Nix:

(sublime-music.override {
  serverSupport = true;
  chromecastSupport = true;
})

The following components are supported:

  • chromecastSupport: if you want support for playing on Chromecast devices on the LAN. Defaults to false.
  • serverSupport: if you want to be able to serve cached files from your computer over the LAN to Chromecast devices. Defaults to false.
  • keyringSupport: if you want to store your passwords in the system keyring instead of in plain-text. Defaults to true.
  • notifySupport: if you want to enable notifications when a new song begins to play. Defaults to true.
  • networkSupport: if you want to change the address used to access the server depending on what network you are connected to. Defaults to true.

See Nix package management for more information.

Via the Debian package

Sublime Music is not currently in the Debian 'Stable' distribution, but has been packaged for Debian 'Unstable' and 'Testing'.

If you have these sources in your /etc/apt/sources.list, you can install the package with:

sudo apt install sublime-music

Via PyPi:

pip install sublime-music

There are a few optional dependencies that you can install. Here's an example of how to do that:

pip install sublime-music[keyring,chromecast,server]
  • keyring: if you want to store your passwords in the system keyring instead of in plain-text
  • chromecast: if you want support for playing on Chromecast devices on the LAN.
  • server: if you want to be able to serve cached files from your computer over the LAN to Chromecast devices

Note

Sublime Music requires Python 3.8. Please make sure that you have that installed. You may also need to use pip3 instead of pip if you are on an OS that hasn't deprecated Python 2 yet.


Click HERE for the Sublime Music website._

Click HERE for extended user documentation._

See the CONTRIBUTING.md_ document for how to contribute to this project.

You can also join the conversation in our Matrix room: #sublime-music:matrix.org.


  1. Requires a server which implements the Subsonic API version 1.8.0+.โ†ฉ

sublime-music's People

Contributors

acompagno avatar albakham avatar anarcat avatar baldurmen avatar benjaminschaaf avatar cquike avatar dependabot[bot] avatar dotlambda avatar edwardbetts avatar edwargix avatar esiqveland avatar github-actions[bot] avatar jlxip avatar jordannewport avatar llfw avatar loveisgrief avatar metallkopf avatar mo0nmokey avatar nevarro-bot avatar robozman avatar sentriz avatar sumnerevans avatar supersandro2000 avatar t11230 avatar wangd avatar wboubi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

sublime-music's Issues

Persist selected tab on restart

Store the selected tab of the application in the ApplicationState and then restore it when the app loads again.

Also store the state of the tab.

  • Restore the selected tab
  • Restore the selected item in the tab
  • Albums
    • Search state
    • Selected album
  • Artists
    • Selected artist
  • Playlists
    • Selected playlist

New icon for Devices button

Currently it is a generic icon. Make a new one that isn't crap. Needs to support different themes as well.

Libremsonic breaks when parent terminal is closed

In GitLab by @robozman on Aug 31, 2019, 20:28

If I launch libremsonic in the background (using &) and close the parent terminal any new requests made my libresonic will spin forever.
This error occurs using zsh with NO_HUP and NO_CHECK_JOBS enabled (which allow libremsonic to stay open) If the parent terminal is left open the application works fine.

Cancel download when "Remove download(s)" is clicked

Currently, when you click "Remove download(s)", it does not actually cancel the
download. Rather, it continues downloading. It should not do this, it should
cancel the download (or at least cancel the result of the download).

We need to figure out if there is a way to easily cancel a requests operation. Right now, we don't, which causes problems.

Ideas:

  • Put downloading into a separate process using multiprocessing so that I can terminate
  • Use stream=True and check every block whether or not to cancel. (probably easier than the above)

Make "Go to Album" work

  • How should we deal with the non-deterministic nature of the album list due to multiple different search types?
  • How should we deal with the potential large size of the album list?
  • We can also implement going to Album in the Artists panel instead.

New Name

We need a new name for LibremSonic, since this app is no longer focused on working on the Librem 5 phone.

Confirm remove from playlist

Instead of immediately removing the song from the playlist, prompt for confirmation.

Alternative: add an "undo" in-app notification.

Respect Metered Connection setting in NetworkManager

  • Figure out what should only be done on non-metered connections (should be
    a setting). Examples:

    • Downloading cover art
    • Pre-fetching songs
    • Sending play queue updates
  • Figure out how to access that setting (DBus?)

  • Respect it

Make Deployment and Installation easy

All executables should be called sublime-music. The actual Python module is called sublime.

Allow installation via:

  • Flatpak
  • PyPi
  • AUR
  • GitLab Release

Automate:

  • Flatpak build
  • PyPi release
  • GitLab Release

Offline support

One of the primary goals was to make sure that the offline usage was good.

  • Convert the can_* functions to be not dependent on the ping state.

  • Get rid of can_service_requests and instead use ping state and initial_sync.

  • Use the GTA can_* only, because the caching adapter should basically inherit from that.

  • Disable certain features that require being online.

  • Need to be able to detect being offline.

    • Listen on DBUS for network updates from NetworkManager (Deferred to #96)
    • Poll periodically to see if we have a connection.
  • Invalidations should not be destructive. That way, we can just use the previous values when we are unable to fetch.

  • The UI should have some indication of being offline. Maybe just something in the header or maybe in the dropdown, not sure.

  • Albums browsing needs to be refactored. In online mode, we can just use the server function, but in offline mode:

    • When random is selected, just grab a random sample of the downloaded albums.
    • When genre is selected, iterate though the local albums for albums of the genre.
    • When year is selected, find all albums in the year range.
    • When alphabetical is selected, sort all of the albums according to the secondary sort param.
  • Search (two ideas here: combine offline and online results always, or use two different searches when in offline/online modes)

Fix issues with switching between tag/directory browsing

When the connected server changes:

  • the entire albums pages should refresh because it's no longer right
  • the artists page should refresh, and select the old artist (just now in the new system). This will require a string match, but I don't think that's too bad. Alternatively, we could just deselect and reset everything.
  • playlists from what I can tell are static, so no issues there

Cached info expiration policy

Figure out a cache expiration policy for the more volatile parts of the application. These include things like:

  • Playlists list
  • Playlist songs

This technique should be used instead of deleting stuff from the cache so that we don't nuke things in offline mode when we don't want to.

My thought here is to wrap each entity that may expire in a tuple of (expiration: Optional[datetime], entity: Any). Then, all of the CacheManager functions need to be adapted to check expiration. If expiration is None, then it never expires.

Play Queue editing

  • Allow reordering of the Play Queue.
  • Allow removing of items from the Play Queue. (Done with #58)

Song play notifications

  • Create a notification when a song starts playing. (Should not notify when playback is resumed.)
  • There should be a setting to disable notifications.

Implement paging for Albums

No idea what to do here and be able to support offline. Maybe we should cache all of the Albums, compute what to show locally?

  • Cache per type
  • Figure out how to deal with random (my idea here is to cache the random for when offline, but expire the random result in a couple seconds (to avoid issues with multiple updates) so that in normal cases it will download again)
  • Figure out how to deal with changes to other parameters
  • Refactor get_model_list_future to be get_model_list_future_generator. Implementors should yield futures to give the next page of results.
  • When scroll to the bottom, show a loading indicator, see if there's anything left in the future generator, and then load if there is.
  • Modify the cache manager to deal with pages
  • Maybe refactor to get rid of cover_art_grid shared component and integrate in with AlbumsGrid.

Play queue resume

Implement functionality to check to see if there is a play queue on the server
which is different than the local one and ask if the user wants to resume that
queue.

Do this on startup. Maybe also provide some option for forcing a load as well
(probably a button at the top of the Up Next popup.)

Implement smart shuffle

Currently, I'm using a pure random shuffle. This is not ideal for shuffling songs. This will require some research into what shuffles are best.

Refactor Connect to server logic

  • should download a bunch of metadata for offline use when connecting to a server
    • playlists, artists, albums (not cover art)
  • the CacheManager needs a good refactor to deal with different servers (#62)
  • UI changes to make it obvious that things are being cached? Not even sure if this is necessary, tbh. (I think it should depend on #64)
  • Clear out the UI of the previous server's state.

Add .desktop file

  • Create a .desktop file for Sublime Music.
  • Install logo
  • Add to AUR installation.
  • In DBus Manager.

Do not store password in plain text

Would be good to integrate in the keychain if possible... That would kinda suck having to do that though. It would also add complexity when porting to Windows/macOS.

Sort the artist list

In GitLab by @robozman on Oct 11, 2019, 20:24

The artist list is displayed in the order that the server sends it. It would be nice to have it sorted alphabetically.

Windows Support

Need the ability to be installed as an application on Windows.

Volume management updates

  • Get rid of the old volume/old_volume model.
  • Replace with volume/muted model. Use ao-mute for MPV implementation.
  • Make each player have its own volume settings so that it saves when switching between players.

Allow installation via snap package

I hate snaps. If someone wants to tackle this, go for it, but I'm not going to do this.

Requirements:

  • Need a way to build locally
  • Need to automate the deployment via GitLab CI/CD

Implement Global Search functionality

Potentially requires #21 refactor to have all of the metadata downloaded.

Questions:

  • How much can we rely on the online search?
  • How to deal with offline search? (How much should we rely on the downloaded metadata.) May want to just wait for #24 to implement this.

Show abbreviated playlist/artist info when scrolled down

Once sufficiently scrolled down, the info panels should show an abbreviated version that is sticky to the top of the scroll window and that doesn't take up nearly as much room.

This is basically the functionality of Spotify where the large info panel scrolls with the content, but a new header appears when scrolled down enough.

2020-04-13-09_47_12

2020-04-13-09_47_15

Delete Playlist does not work

I tried to use something like this on a button in a Dialog:

            action_name='app.delete-playlist',
            action_target=GLib.Variant('s', playlist_id),

but it doesn't seem to be hooking up correctly to the application's action.

See libremsonic/ui/playlists.py:24.

Flatpak support

In GitLab by @robozman on Aug 31, 2019, 20:46

Flatpak is a great cross distribution way of distributing applications. It would great to see a flatpak package from libremsonic.

macOS Support

Want to be able to support installing the app on macOS.

Maybe Homebrew?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.