Giter Club home page Giter Club logo

mopidy-subidy's Introduction

Mopidy-Subidy

Latest PyPI version

CircleCI build status

Test coverage

This library is actively looking for maintainers to help out as I do not have the time or need to maintain this anymore. Please contact me if you feel that you could maintain this.

A Subsonic backend for Mopidy using py-sonic.

Installation

Install the latest release from PyPI by running:

python3 -m pip install Mopidy-Subidy

Install the development version directly from this repo by running:

python3 -m pip install https://github.com/Prior99/mopidy-subidy/archive/master.zip

See https://mopidy.com/ext/subidy/ for alternative installation methods.

Configuration

Before starting Mopidy, you must add configuration for Mopidy-Subidy to your Mopidy configuration file:

[subidy]
url=https://path.to/your/subsonic/server
username=subsonic_username
password=your_secret_password

In addition, the following optional configuration values are supported:

  • enabled -- Defaults to true. Set to false to disable the extension.
  • legacy_auth -- Defaults to false. Setting to true may solve some connection errors.
  • api_version -- Defaults to 1.14.0, which is the version used by Subsonic 6.2.

State of this plugin

The following things are supported:

  • Browsing all artists/albums/tracks
  • Searching for any terms
  • Browsing, creating, editing and deleting playlists
  • Searching explicitly for one of: artists, albums, tracks

The following things are not supported:

  • Subsonic's smart playlists
  • Searching for a combination of filters (artist and album, artist and track, etc.)

Credits

mopidy-subidy's People

Contributors

aagallag avatar hhm0 avatar jodal avatar jolny avatar prior99 avatar vincentdcmps 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

Watchers

 avatar  avatar  avatar  avatar  avatar

mopidy-subidy's Issues

Feature request: Random playlist

I often use Subsonic to randomly go through my library. It used to be that the former mopidy-subsonic plugin offered a "random" playlist, would it be possible to have the same here?

Cheers;
M.

Feature Request: Last FM / Listenbrainz Scrobbling

First of all I just wanna say thanks so much for this great plugin, I'm very glad it exists and use it basically every day.

It would be sweet if this plugin could support Last FM / Listenbrainz Scrobbling. I have it enabled in my Airsonic settings but noticed it doesn't seem to work when using this plugin. I'd love to find the time to learn the Subsonic API and this repo so I could try and take a stab at myself eventually but figured I'd ask here first.

Could not find a version that satisfies the requirement Mopidy-Subidy

Hello!

I'm a brand new mopidy user and wanted to connect it to my Airsonic instance but i've encoutered this:
Did i missed something?


pi@mopidy:~ $ sudo pip  install Mopidy-Subidy
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting Mopidy-Subidy
  Could not find a version that satisfies the requirement Mopidy-Subidy (from versions: )
No matching distribution found for Mopidy-Subidy

Subidy added to the song names in the Mpd interface

Hi

I am browsing Subsonic lib with Ncmpcpp via Mpd remote. I see that the file names have added some ids in the Mpd listing. This does not happen with other library types in Mopidy.

See the paste from the terminal

Herb Ellis/Joe Pass - Seven, Come Sevensubidy:song:159857          (5:10)
Great Guitars - Benny's Buglesubidy:song:159859                    (7:11)
Ruby Braff/George Barnes Quartet - I Got Rhythmsubidy:song:159860  (4:47)
Kenny Burrell - Tin Tin Deosubidy:song:159861                      (7:13)
L.A. - Just Friendssubidy:song:159862                              (7:21)
Bud Shank/Bill Mays/Alan Broadbent - Scrapple From The Applesubidy:(5:52)

Playlists not loading

Hi,

I have a Navidrome backend with three playlists. 300-500 Songs per Playlist.
In the Playlists overview I can see the playlists with the number of tracks inside, but when I open up a playlist there ist nothing in there. The refresh button also doesn't fix the problem.

Thanks

Directory Browsing only works two directories down

Browsing directories doesn't work multiple directories down. I've tested this using Ario (GTK frontend to mpd) and ncmpc.

For instance, the directory John Lennon/Imagine would be browsable, however John Lennon/Studio Albums/Imagine is not.

Subidy not listed as provider when creating playlists

When I want to create a playlist, iris webclient does not show subidy as provider. Only spotify and mopidy are listed. Hence it is not possible to create a "subidy playlist".

If this is not a subidy issue, which web client supports subidy as provider for creating new playlists?

Skipping Tracks Repeats Track

I am using version 0.4.0-1 on Arch Linux and connecting to an Airsonic server (fork of Subsonic that implements the Subsonic API).

I can connect fine and can browse / load my playlists from the server, but I can't skip songs with a playlist. After the first song has started playing, any attempt to skip to another song (including selecting one manually from the playlist or the library) will repeatedly play the same song. The playlist does move to the next song after that song finishes.

Any ideas why this might be happening? I can provide logs or run some local tests if necessary.

Connecting to subsonic failed when loading list of playlists.

No Playlist Shows up in mopidy.
Mopidy Log:

1 10:09:55 Ipse mopidy[31225]: INFO Connecting to subsonic server on url https://server.tld as user admin
Dec 1 10:09:55 Ipse mopidy[31225]: WARNING Connecting to subsonic failed when loading list of playlists.

i created a Playlist in the subsonic webinterface.
SubidyBackend installed with pip install py-sonic, git clone and setup.py install

mopidy --version
Mopidy 2.0.1

Nothing Shows up in the subsonic logs..

Server URL with trailing / produces unexpected error

Currently, if the url parameter in the config has a trailing slash (e.g. https://music.example.com/ as opposed to https://music.example.com), then subidy is able to connect correctly and even show songs/albums/etc, but fails to stream - yielding instead a very confusing error about needing a gstreamer plugin for text/html.

The reason for this is that subidy later generates URLs with double slashes, such as https://music.example.com//rest/stream.view?id=tr-12749&c=Mopidy-Subidy&v=1.14.0&u=******&p=******, which can produce an HTML error page instead of a binary audio stream.

I made a PR to fix this, it should link to this issue.

Cannot play any titles: GStreamer reports "Secure connection setup failed"

As the title says. I'm trying to connect to a Subsonic instance running the most up to date Subsonic 6.1.3. I can access the list of titles in Album/Artist/Directory view just fine, but no title will play. Whenever I try to play a title, an error is printed to the mopidy log: "ERROR GStreamer error: gst-resource-error-quark: Secure connection setup failed. (5)"

I'm using legacy auth because the server's authentication is LDAP connected, which doesn't support other auth modes. I've tried with both the default-configured API version 1.14.0 as well as the more recent supported API version 1.16.0 of the server version according to this table. The GStreamer plugins are all installed and up to date (running Arch Linux).

Cannot seek

For some reason, when playing FLACs from subsonic mopidy isn't able to seek.

cover art

is subidy supposed to show covers? i tried it with two different subsonic servers (one of them most recent version), with neither i could see the covers in my webinterface (iris).

get_raw_songs and album_id

get_raw_songs query the directory id not the album id, this means its not possible to load songs from an album

I've fixed this on my own branch with a hack jonathanchristison@4c465f1 but I don't know enough about the structure of the mopidy-subidy, mopidy or py-sonic to make a nice fix, i just know it fixes it for my particular case

Crash on launch

When I try connecting to my subsonic server, I get the following error whilst starting mopidy:

ERROR    Got un-handled exception from SubidyBackend
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/mopidy/commands.py", line 237, in _actor_error_handling
    yield
  File "/usr/lib/python2.7/site-packages/mopidy/commands.py", line 385, in start_backends
    config=config, audio=audio).proxy()
  File "/usr/lib/python2.7/site-packages/pykka/actor.py", line 93, in start
    obj = cls(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/mopidy_subidy/backend.py", line 15, in __init__
    self.playlists = playlists.SubidyPlaylistsProvider(backend=self)
  File "/usr/lib/python2.7/site-packages/mopidy_subidy/playlists.py", line 12, in __init__
    self.refresh()
  File "/usr/lib/python2.7/site-packages/mopidy_subidy/playlists.py", line 32, in refresh
    self.playlists = self.subsonic_api.get_playlists_as_refs()
  File "/usr/lib/python2.7/site-packages/mopidy_subidy/subsonic_api.py", line 137, in get_playlists_as_refs
    return [self.raw_playlist_to_ref(playlist) for playlist in self.get_raw_playlists()]
TypeError: 'NoneType' object is not iterable

Configuration looks as follows:

[subidy]
enabled = true
url = https://m.kunix.org/
username = username
password = password

I installed this package using modipy-subidy from the AUR on Arch

Name of the package in AUR

Hi
Why in AUR exists package mopidy-subidy which is updated and package rofi-mpd which is outdated? Why you have two packages with totally different names and you didn't remove previous? I want to add own script named... rofi-mpd to AUR but this is little conflict.

Publish tarballs to PyPI

Right now it appears that only eggs are being published to PyPI. I've recently taken over maintainership of the mopidy-subidy package on the AUR, and I would appreciate it if you could publish tarballs to PyPI in addition to eggs.

Right now there isn't an easy to way to download a tarball of an official release anywhere, as version 1.2.0 hasn't been tagged here on github.

Some web clients cannot access artist page

musicbox 2.3.0 and moped 0.7.0 cannot access an artist page when it is selected through search. The quite uninformative error message is:

  File "/usr/lib/python2.7/site-packages/mopidy/core/library.py", line 19, in _backend_error_handling
    yield
  File "/usr/lib/python2.7/site-packages/mopidy/core/library.py", line 236, in lookup
    result = future.get()
  File "/usr/lib/python2.7/site-packages/pykka/future.py", line 299, in get
    exec('raise exc_info[0], exc_info[1], exc_info[2]')
  File "/usr/lib/python2.7/site-packages/pykka/actor.py", line 200, in _actor_loop
    response = self._handle_receive(message)
  File "/usr/lib/python2.7/site-packages/pykka/actor.py", line 294, in _handle_receive
    return callee(*message['args'], **message['kwargs'])
  File "/home/micha/src/mopidy-subidy/mopidy_subidy/library.py", line 117, in lookup
    return self.lookup_one(uri)
  File "/home/micha/src/mopidy-subidy/mopidy_subidy/library.py", line 103, in lookup_one
    return self.lookup_artist(uri.get_artist_id(lookup_uri))
  File "/home/micha/src/mopidy-subidy/mopidy_subidy/library.py", line 69, in lookup_artist
    return list(self.subsonic_api.get_artist_as_songs_as_tracks_iter(artist_id))
  File "/home/micha/src/mopidy-subidy/mopidy_subidy/subsonic_api.py", line 294, in get_artist_as_songs_as_tracks_iter
    albums = self.get_raw_albums(artist_id)
  File "/home/micha/src/mopidy-subidy/mopidy_subidy/subsonic_api.py", line 213, in get_raw_albums
    response = self.connection.getArtist(artist_id)
  File "build/bdist.linux-armv7l/egg/libsonic/connection.py", line 1669, in getArtist
    self._checkStatus(res)
  File "build/bdist.linux-armv7l/egg/libsonic/connection.py", line 2692, in _checkStatus
    raise exc(result['error']['message'])
DataNotFoundError: Artist not found.

Surprisingly, iris 3.2.0 works well, but seems to query a different artist ID.

Against mopidy-subidy git version.

Not all albums are listed under "Subsonic -> Albums" virtual folder

I have a whole lot of albums stored on my Subsonic server. When I try to list them via Subidy, I can get to the letter H (sorted alphabetically); not beyond that letter. I know for sure I have albums with names starting with alphabetical letters beyond H, like M (like the Metal Gear Solid original soundtrack).

Bonus issue, album arts are not displayed at all when navigating "Subsonic -> Albums" through the Iris web frontend.

Pausing a song ends up restarting a song

When a song is paused, regardless of MPD frontend, and resumed at a later point, it will resume playing the song until it has run out of buffer. After which it'll restart the same song without resetting the time it has been playing. Resulting, for example, in "14:36 / 9:57" time played by the end of the song.

[Question] AUR - python2-pykka>=1.1

==> Error: Could not find all required packages:
python2-pykka>=1.1 (Wanted by: mopidy-subidy)

Newer to using Arch, this may be an obvious question, but was trying to install mopidy-subidy through AUR using Yay and am met with the above error. I have python2 installed and python3, I also tried doing pip install pykka and get

Defaulting to user installation because normal site-packages is not writeable
Requirement already satisfied: pykka in /usr/lib/python3.8/site-packages (2.0.2)

So it seems pykka is already existent, so I'm confused as to what I am missing? I notice on the AUR, this dependency is listed as red, not sure if that means it is outdated or something? I wouldn't assume that to be the case seeing the mopidy-subidy AUR pack was updated like two months ago so all seems it should work, I assume this is a me issue.
Was just looking for a little help, thanks.

Add "Random Albums" section

The "Random" section where 75 songs are pulled is great but I'd like to pull random albums too. I'll try to add a "Random Albums" section modeled after the existing "Random" section.

Not Working With Airsonic - "Connecting to subsonic failed when loading list of artists"

Currently using Airsonic (fork of Subsonic) and it shows it connects to the Airsonic server and reads the API version, but then when it starts to fetch stuff I get constant errors of: [154926:SubidyBackend-3] mopidy_subidy.subsonic_api Connecting to subsonic failed when loading list of artists

My Mopidy file is as follows:

[mpd]
hostname = 127.0.0.1

[subidy]
url=https://airsonic.xxx.xxx/index
api_version=1.15.0
username=x
password=x

In case the above isn't clear, I'm using Mopidy-Subidy plugin and the Mopidy-MPD plugin, I run Mopidy on my laptop, then open NCMPCPP for the player.

Genuinely hope it is possible to use Airsonic with this and it's an easy fix that can be resolved soon, I have used my Airsonic server with Ultrasonic (App), I believe they're similar APIs. If this is not possible, I'd highly appreciate guidance towards an alternative plugin for Mopidy that isn't deprecated (the only few I found were deprecated).

Also on a sidenote, dependencies for mopidy-subidy are flagged out of date on the AUR. But I installed via pip so that shouldn't be an issue. Just wanted to point that out.

How to install?

This is not avail with pip, not sure how I can install this. It would be nice if the way to install is mentioned.

thanks

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.