Git Product home page Git Product logo

psst's Introduction

Psst

A fast Spotify client with a native GUI written in Rust, without Electron. Psst is still very early in development, lacking in features, stability, and general user experience. It's fully cross-platform, supporting Windows, Linux, and macOS. Contributions are welcome!

Note: A Spotify Premium account is required.

Build

Screenshot

Download

GitHub Actions automatically creates builds when new commits are pushed to the master branch. You can download the prebuilt binaries for x86_64 Windows, Linux (Ubuntu), and macOS.

Platform
Windows
Linux (Ubuntu)
Debian Package
MacOS

Unofficial builds of Psst are also available through the AUR and Homebrew.

Building

On all platforms, the latest Rust stable (at least 1.65.0) is required. For platform-specific requirements, see the dropdowns below.

Linux

Our user-interface library, Druid, has two possible backends on Linux: GTK and pure X11, with a Wayland backend in the works. The default Linux backend is GTK. Before building on Linux, make sure the required dependencies are installed.

Debian/Ubuntu:

sudo apt-get install libssl-dev libgtk-3-dev libcairo2-dev libasound2-dev

RHEL/Fedora:

sudo dnf install openssl-devel gtk3-devel cairo-devel alsa-lib-devel
OpenBSD (WIP)

OpenBSD support is still a WIP, and things will likely not function as intended. Similar to Linux, Druid defaults to GTK while also providing a pure X11 backend. Furthermore, bindgen must be able to find LLVM through the expected environment variable. Only OpenBSD/amd64 has been tested so far.

doas pkg_add gtk+3 cairo llvm
export LIBCLANG_PATH=/usr/local/lib

In case rustc(1) fails building bigger crates

memory allocation of xxxx bytes failed
error: could not compile `gtk`
Caused by:
  process didn't exit successfully: `rustc --crate-name gtk [...]` (signal: 6, SIGABRT: process abort signal)
warning: build failed, waiting for other jobs to finish...

try increasing your user's maximum heap size:

ulimit -d $(( 2 * `ulimit -d` ))

Build from Source:

cargo build
# Append `--release` for a release build.

Run from Source:

cargo run --bin psst-gui
# Append `--release` for a release build.

Build Installation Bundle (i.e., macOS .app):

cargo install cargo-bundle
cargo bundle --release

Roadmap

  • Vorbis track playback
  • Browsing saved albums and tracks
  • Save / unsave albums and tracks
  • Browsing followed playlists
  • Search for artists, albums, and tracks
  • Podcast support
  • Media keys control
  • Open Spotify links through the search bar
  • Audio volume control
  • Audio loudness normalization
  • Genre playlists and "For You" content
  • Dark theme
  • Resilience to network errors (automatically retry timed-out requests)
  • Managing playlists
    • Follow/unfollow
    • Add/remove tracks
    • Reorder tracks
    • Rename playlist
    • Playlist folders
  • Playback queue
  • React to audio output device events
    • Pause after disconnecting headphones
    • Transfer playback after connecting headphones
  • Better caching
    • Cache as many WebAPI responses as possible
    • Visualize cache utilization
      • Total cache usage in the config dialog
      • Show time origin of cached data, allow to refresh
  • Trivia on the artist page, Wikipedia links
  • Downloading encrypted tracks
  • Reporting played tracks to Spotify servers
  • OS-specific application bundles
  • UI
    • Rethink the current design, consider a two-pane layout
      • Left pane for browsing
      • Right pane for current playback
    • Detect light/dark OS theme
    • Robust error states, ideally with a retry button
    • Correct playback highlight
      • Highlight now-playing track only in the correct album/playlist
      • Keep highlighted track in viewport
    • Paging or virtualized lists for albums and tracks
    • Grid for albums and artists
    • Robust active/inactive menu visualization
    • Save playback state

Development

Contributions are very welcome!
Here's the basic project structure:

  • /psst-core - Core library, takes care of Spotify TCP session, audio file retrieval, decoding, audio output, playback queue, etc.
  • /psst-gui - GUI application built with Druid
  • /psst-cli - Example CLI that plays a track. Credentials must be configured in the code.
  • /psst-protocol - Internal Protobuf definitions used for Spotify communication.

Privacy Policy

Psst connects only to the official Spotify servers and does not call home. Caches of various things are stored locally and can be deleted anytime. User credentials are not stored at all; instead, a re-usable authentication token from Spotify is used.

Thanks

This project would not exist without the following:

  • Big thank you to librespot, the Open Source Spotify client library for Rust. Most of psst-core is directly inspired by the ideas and code of librespot, although with a few differences:
    • Spotify Connect (remote control) is not supported yet.
    • Psst is completely synchronous, without tokio or other async runtime, although it will probably change in the future.
    • Psst is using HTTPS-based CDN audio file retrieval, similar to the official Web client or librespot-java, instead of the channel-based approach in librespot.
  • druid native GUI library for Rust.
  • ncspot cross-platform ncurses Spotify client written in Rust, using librespot.
  • ...and of course other libraries and projects.

psst's People

Contributors

arch-btw avatar bivhitscar avatar brandly avatar brightly-salty avatar charliethomson avatar dscso avatar gokayokyay avatar gordonshieh avatar im-coder-lg avatar insprill avatar itsjunetime avatar jacksongoode avatar jpochyla avatar julidi avatar kesefon avatar kethku avatar klemensn avatar literallyjustroy avatar luukvanderduim avatar martingoe avatar mtorromeo avatar nicolasf avatar oleggtro avatar paolobarbolini avatar reynn avatar soooch avatar swiesmann avatar takanoro avatar timgws avatar tmdh 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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 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

psst's Issues

Proxy Support

Hello, I have tried using psst but I am unable to connect to Spotify. I believe this is because Spotify now has even stricter region requirements. I tried using proxychains4, but it doesn't seem to work properly with this application. The main Spotify client has an option to select a SOCKS5/SOCKS4/HTTP proxy. Are there any plans to add this to psst as well?

Preferences button almost hidden

image

When psst-gui is first started, the preferences window is a bit too small in height and not resizable, so the (I guess) apply button is hidden.

Env:
Windows 10 20H2
Psst Version 0bb5258

Homebrew Cask

Can you confirm that as of right now the only way to run the app on MacOS is by building it from source?
It would be great to have an Homebrew package of the app.

Thanks a lot!
T

Build error on windows 10

I know you haven't been able to test on windows so I'm just putting this here for your information.
The initial error I got was that libsoundio-sys needed cmake. So probably want to document that in the readme. After I installed cmake, this was the error I got. I don't really know what the issue is, but maybe you will.

I'm on windows 10 version 10.0.18363 Build 18363

error: failed to run custom build command for `libsoundio-sys v0.3.0 (https://github.com/jpochyla/soundio-rs?branch=static-callbacks#5000df22)`

Caused by:
  process didn't exit successfully: `C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-c1586ac3501b8a21\build-script-build` (exit code: 101)
  --- stdout
  running: "cmake" "C:\\Users\\Me\\.cargo\\git\\checkouts\\soundio-rs-21410f3b88cc1cd8\\5000df2\\libsoundio-sys\\libsoundio" "-G" "Visual Studio 15 2017" "-Thost=x64" "-Ax64" "-DBUILD_DYNAMIC_LIBS=OFF" "-DBUILD_STATIC_LIBS=ON" "-DBUILD_EXAMPLE_PROGRAMS=OFF" "-DBUILD_TESTS=OFF" "-DCMAKE_INSTALL_PREFIX=C:\\Users\\Me\\Projects\\psst\\target\\release\\build\\libsoundio-sys-119d7aa244eb28dd\\out" "-DCMAKE_C_FLAGS= -nologo -MD -Brepro" "-DCMAKE_C_FLAGS_RELEASE= -nologo -MD -Brepro" "-DCMAKE_CXX_FLAGS= -nologo -MD -Brepro" "-DCMAKE_CXX_FLAGS_RELEASE= -nologo -MD -Brepro" "-DCMAKE_ASM_FLAGS= -nologo -MD -Brepro" "-DCMAKE_ASM_FLAGS_RELEASE= -nologo -MD -Brepro" "-DCMAKE_BUILD_TYPE=Release"
  -- Selecting Windows SDK version 10.0.17763.0 to target Windows 10.0.18363.
  -- The C compiler identification is MSVC 19.16.27044.0
  -- Detecting C compiler ABI info
  -- Detecting C compiler ABI info - done
  -- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2017/BuildTools/VC/Tools/MSVC/14.16.27023/bin/Hostx64/x64/cl.exe - skipped
  -- Detecting C compile features
  -- Detecting C compile features - done
  -- Looking for pthread.h
  -- Looking for pthread.h - not found
  -- Found Threads: TRUE
  -- Looking for jack_set_port_rename_callback in jack
  -- Looking for jack_set_port_rename_callback in jack - not found
  -- Could NOT find JACK (missing: JACK_LIBRARY JACK_INCLUDE_DIR HAVE_jack_set_port_rename_callback)
  -- Could NOT find PULSEAUDIO (missing: PULSEAUDIO_LIBRARY PULSEAUDIO_INCLUDE_DIR)
  -- Could NOT find ALSA (missing: ALSA_LIBRARY ALSA_INCLUDE_DIR)
  -- Could NOT find COREAUDIO (missing: COREAUDIO_LIBRARY COREAUDIO_INCLUDE_DIR)
  -- Looking for audioclient.h
  -- Looking for audioclient.h - found
  -- Found WASAPI: 1
  -- Configuring done
  -- Generating done
  -- Build files have been written to: C:/Users/Me/Projects/psst/target/release/build/libsoundio-sys-119d7aa244eb28dd/out/build
  running: "cmake" "--build" "." "--target" "install" "--config" "Release" "--"
  Microsoft (R) Build Engine version 15.9.21+g9802d43bc3 for .NET Framework
  Copyright (C) Microsoft Corporation. All rights reserved.

    Checking Build System
    Building Custom Rule C:/Users/Me/.cargo/git/checkouts/soundio-rs-21410f3b88cc1cd8/5000df2/libsoundio-sys/libsoundio/CMakeLists.txt
    soundio.c
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\util.h(89): warning C4244: 'return': conversion from 'const double' to 'int', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\util.h(93): warning C4244: 'initializing': conversion from '__int64' to 'const double', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\atomics.h(48): fatal error C1083: Cannot open include file: 'stdatomic.h': No such file or directory [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
    util.c
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\util.h(89): warning C4244: 'return': conversion from 'const double' to 'int', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\util.h(93): warning C4244: 'initializing': conversion from '__int64' to 'const double', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
    os.c
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\util.h(89): warning C4244: 'return': conversion from 'const double' to 'int', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\util.h(93): warning C4244: 'initializing': conversion from '__int64' to 'const double', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  C:\Users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\os.c(453): warning C4244: 'initializing': conversion from 'double' to 'DWORD', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  C:\Users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\os.c(614): warning C4244: 'return': conversion from 'const double' to 'size_t', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  C:\Users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\os.c(613): warning C4244: 'initializing': conversion from 'size_t' to 'const double', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  C:\Users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\os.c(622): warning C4267: 'function': conversion from 'size_t' to 'DWORD', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
    dummy.c
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\atomics.h(48): fatal error C1083: Cannot open include file: 'stdatomic.h': No such file or directory [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
    channel_layout.c
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\util.h(89): warning C4244: 'return': conversion from 'const double' to 'int', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\util.h(93): warning C4244: 'initializing': conversion from '__int64' to 'const double', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\atomics.h(48): fatal error C1083: Cannot open include file: 'stdatomic.h': No such file or directory [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
    ring_buffer.c
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\atomics.h(48): fatal error C1083: Cannot open include file: 'stdatomic.h': No such file or directory [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
    wasapi.c
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\util.h(89): warning C4244: 'return': conversion from 'const double' to 'int', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\util.h(93): warning C4244: 'initializing': conversion from '__int64' to 'const double', possible loss of data [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\atomics.h(48): fatal error C1083: Cannot open include file: 'stdatomic.h': No such file or directory [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]
    Generating Code...
  c:\users\Me\.cargo\git\checkouts\soundio-rs-21410f3b88cc1cd8\5000df2\libsoundio-sys\libsoundio\src\os.c(588): warning C4706: assignment within conditional expression [C:\Users\Me\Projects\psst\target\release\build\libsoundio-sys-119d7aa244eb28dd\out\build\libsoundio_static.vcxproj]

  --- stderr
  CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
    Compatibility with CMake < 2.8.12 will be removed from a future version of
    CMake.

    Update the VERSION argument <min> value or use a ...<max> suffix to tell
    CMake that the project does not need compatibility with older versions.


  Configuring libsoundio version 2.0.0
  CMake Warning (dev) at C:/Users/Me/scoop/apps/cmake/3.19.2/share/cmake-3.19/Modules/FindPackageHandleStandardArgs.cmake:426 (message):
    The package name passed to `find_package_handle_standard_args` (PULSEAUDIO)
    does not match the name of the calling package (PulseAudio).  This can lead
    to problems in calling code that expects `find_package` result variables
    (e.g., `_FOUND`) to follow a certain pattern.
  Call Stack (most recent call first):
    cmake/FindPulseAudio.cmake:14 (find_package_handle_standard_args)
    CMakeLists.txt:65 (find_package)
  This warning is for project developers.  Use -Wno-dev to suppress it.

  CMake Warning (dev) at C:/Users/Me/scoop/apps/cmake/3.19.2/share/cmake-3.19/Modules/FindPackageHandleStandardArgs.cmake:426 (message):
    The package name passed to `find_package_handle_standard_args` (COREAUDIO)
    does not match the name of the calling package (CoreAudio).  This can lead
    to problems in calling code that expects `find_package` result variables
    (e.g., `_FOUND`) to follow a certain pattern.
  Call Stack (most recent call first):
    cmake/FindCoreAudio.cmake:14 (find_package_handle_standard_args)
    CMakeLists.txt:99 (find_package)
  This warning is for project developers.  Use -Wno-dev to suppress it.


  Installation Summary
  --------------------
  * Install Directory            : C:/Users/Me/Projects/psst/target/release/build/libsoundio-sys-119d7aa244eb28dd/out
  * Build Type                   : Release
  * Build static libs            : ON
  * Build examples               : OFF
  * Build tests                  : OFF

  System Dependencies
  -------------------
  * threads                      : OK
  * JACK       (optional)        : not found
  * PulseAudio (optional)        : not found
  * ALSA       (optional)        : not found
  * CoreAudio  (optional)        : not found
  * WASAPI     (optional)        : OK

  CMake Warning:
    Manually-specified variables were not used by the project:

      CMAKE_ASM_FLAGS
      CMAKE_ASM_FLAGS_RELEASE
      CMAKE_CXX_FLAGS
      CMAKE_CXX_FLAGS_RELEASE


  thread 'main' panicked at '
  command did not execute successfully, got: exit code: 1

  build script failed, must exit now', C:\Users\Me\.cargo\registry\src\github.com-1ecc6299db9ec823\cmake-0.1.45\src\lib.rs:894:5

panicked on linux - WIP to get it working on linux

Steps:

$ git clone https://github.com/jpochyla/psst
$ cd psst
$ git submodule update --recursive --init
$ cd psst-bin
$ rustup install stable
$ rustup run stable rustc --version
# rustc 1.49.0 (e1884a8e3 2020-12-29)
$ cargo +stable run --release
# see message below

Using cargo +stable run --release in /psst-bin for starting.

warning: field is never read: `loading_handle`
   --> psst-core/src/audio_player.rs:568:9
    |
568 |         loading_handle: JoinHandle<()>,
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = note: `#[warn(dead_code)]` on by default

warning: field is never read: `loading_handle`
   --> psst-core/src/audio_player.rs:585:9
    |
585 |         loading_handle: JoinHandle<()>,
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

warning: field is never read: `reusable_creds`
  --> psst-core/src/session.rs:58:5
   |
58 |     reusable_creds: Credentials,
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^

warning: unused `std::result::Result` that must be used
   --> psst-core/src/audio_file.rs:173:13
    |
173 | /             thread::Builder::new().name(thread_name).spawn({
174 | |                 // TODO: Do not bury the whole servicing loop in case the URL renewal fails.
175 | |                 let url = fresh_url()?.url.clone();
176 | |                 let cdn = self.cdn.clone();
...   |
198 | |                 }
199 | |             });
    | |_______________^
    |
    = note: `#[warn(unused_must_use)]` on by default
    = note: this `Result` may be an `Err` variant, which should be handled

warning: 4 warnings emitted

   Compiling psst-bin v0.1.0 (/home/daniel/Downloads/setups/psst/psst-bin)
    Finished release [optimized] target(s) in 33.56s
     Running `/home/daniel/Downloads/setups/psst/target/release/psst-bin`
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: NotPresent', psst-bin/src/main.rs:17:38
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

I guess it's connected to the last warning, however I'm not very good nor up-to-date with rust.

My system:

  • Kernel: x86_64 Linux 5.10.2-2-MANJARO
  • OS: Manjaro 20.2 Nibia

Cannot find value `TEXT_COLOR` in module `theme`

Hi, i was trying to compile your program (looks awesome btw), but i was getting this weird error, idk nothing about rust so idk if it is something on my machine or on the code, the following is the output of the error

Screenshot_20210508_003400

Thanks.

Media keys support (MPRIS, etc)

Hi. I really like this client and I want to have a go at implementing media keys support. I've been doing some research and doing this seems straightforward. Please forgive me if my issue format or style isn't correct, it's my first time posting an issue on an open-source project, besides English isn't my first language 😅

Implementation details

I need some orientation as to in what part of the project this has to be implemented. In terms of in which crate, I assume psst-gui since it's the highest level one of them all. I've looked at the code a bit and got a general idea of it. Still, I don't know how and where the media key receiver should modify the app's state, maybe this could be done via polling the receiver for events on every frame and then applying the changes to the state. I hope multithreading isn't necessary (I haven't done anything with it except for a few experiments).

Cross-platform support

Surprisingly, I haven't found an all-in-one solution for cross-platform media keys support in Rust. Maybe because each platform's implementation slightly varies in capability, or maybe I haven't looked good enough. I was thinking we could maybe create a MediaKeys trait with some basic functionality functions:

trait MediaKeys {
	fn process_event(&mut self, state: &mut AppState, event: MediaKeyEvent);
	fn emit_metadata(&mut self, state: &AppState);
}

And then, derive that trait for each platform implementation: LinuxMediaKeys, MacOSMediaKeys, etc. Then maybe use Cargo features or other cfg! stuff to actually compile each of them only in their respective platforms.

Personally, I can try to implement it on Linux first, and then Windows but I am not quite sure about macOS since I don't own an Apple desktop or laptop.

My sources for most of this actually come from this blogpost.

Linux

Using D-Bus MPRIS messages and maybe the mpris-player crate, I think it'll be quite simple. This crate is a bit old and it uses function callbacks for things so I might have to do it in a different way.

Windows

It seems System Media Transport Controls is the way to go. Haven't quite looked into it yet.

macOS

Haven't looked into it yet, but here's what the blogpost says:

My experience as a user of macOS is very limited, and as a developer non-existent, but it seems that the macOS equivalent of MPRIS is MPRemoteCommandCenter in the Media Player framework.

Impossible to open Preferences on Linux and Windows

rn the window looks like this:

image

I have not jet found a way to open the settings menu. Light theme hurts 😄 ☢️

I could imagine something like psst-gui --theme=dark.

psst-gui --help doesn't seam to be a thing yet since it start the gui normally.

Environment:
Debian 10 (installed via .deb package)
Version: 562f9df (Mar 10, 2021)

Build failing on macOS 11.3.1

rustc 1.52.1

The following warnings were emitted during compilation:

warning: ./minivorbis.c:6:10: fatal error: 'minivorbis.h' file not found
warning: #include "minivorbis.h"
warning:          ^~~~~~~~~~~~~~
warning: 1 error generated.

error: failed to run custom build command for `minivorbis-sys v0.1.0 (/Users/tenx/Documents/GitHub/psst/minivorbis-sys)`

Caused by:
  process didn't exit successfully: `/Users/tenx/Documents/GitHub/psst/target/release/build/minivorbis-sys-bde3f7516baa9d47/build-script-build` (exit code: 1)
  --- stdout
  TARGET = Some("x86_64-apple-darwin")
  OPT_LEVEL = Some("3")
  HOST = Some("x86_64-apple-darwin")
  CC_x86_64-apple-darwin = None
  CC_x86_64_apple_darwin = None
  HOST_CC = None
  CC = None
  CFLAGS_x86_64-apple-darwin = None
  CFLAGS_x86_64_apple_darwin = None
  HOST_CFLAGS = None
  CFLAGS = None
  CRATE_CC_NO_DEFAULTS = None
  DEBUG = Some("false")
  CARGO_CFG_TARGET_FEATURE = Some("fxsr,sse,sse2,sse3,ssse3")
  running: "cc" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "-arch" "x86_64" "-I" "./minivorbis" "-Wall" "-Wextra" "-o" "/Users/tenx/Documents/GitHub/psst/target/release/build/minivorbis-sys-acf704866ae9211b/out/./minivorbis.o" "-c" "./minivorbis.c"
  cargo:warning=./minivorbis.c:6:10: fatal error: 'minivorbis.h' file not found
  cargo:warning=#include "minivorbis.h"
  cargo:warning=         ^~~~~~~~~~~~~~
  cargo:warning=1 error generated.
  exit code: 1

  --- stderr


  error occurred: Command "cc" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "-arch" "x86_64" "-I" "./minivorbis" "-Wall" "-Wextra" "-o" "/Users/tenx/Documents/GitHub/psst/target/release/build/minivorbis-sys-acf704866ae9211b/out/./minivorbis.o" "-c" "./minivorbis.c" with args "cc" did not execute successfully (status code exit code: 1).

Build failing on Debian

Problem

On LMDE 4, building in release mode fails with

 run pkg_config fail: "`\"pkg-config\" \"--libs\" \"--cflags\" \"openssl\"` did not exit successfully: exit code: 1\n--- stderr\nPackage openssl was not found in the pkg-config search path.\nPerhaps you should add the directory containing `openssl.pc\'\nto the PKG_CONFIG_PATH environment variable\nNo package \'openssl\' found\n"

Solution

Installing libssl-dev package fixes the error. Probably adding some documentation about it would be enough.

Notes

After continuing with the build also needed to install libgtk-3-dev, libcairo2-dev

Panic trying to run app

thread 'main' panicked at 'called `Option::unwrap()` on a `None` value', psst-gui/src/delegate.rs:43:47

Seems like I need to define credentials?

Authentication failure

I'm getting this error with credentials that I tested to work correctly in-browser:

[2021-01-02T13:51:33Z ERROR psst_gui::delegate] connection error: AuthFailed { code: 11 }

Sorry, don't know where to look for logs, otherwise I'd provide them!

~

EDIT - this is after building e62719d from source

Debian Package: Missing maintainer field

I get the following error:

Preparing to unpack .../Downloads/psst_154_amd64.deb ...
Unpacking psst (154) over (152) ...
dpkg: warning: parsing file '/var/lib/dpkg/status' near line 59933 package 'psst':
 missing 'Maintainer' field

This warning is also shown when upgrading.

Store user credentials in the system keychain

Saving the authentication credentials to the disk in a config file is great, but saving them raw is a bit insecure. It would be really helpful if the passwords get encrypted for user's privacy and safety.

Build failing on Windows 10

Build from latest master

  • Windows 20H2 19042.985
  • rustc 1.54.0-nightly (5c0292654 2021-05-11)

Error output:

error[E0599]: no method named `raw_window_handle` found for reference `&WindowHandle` in the current scope
  --> psst-gui\src\controller\playback.rs:77:67
   |
77 |         let mut media_controls = MediaControls::for_window(window.raw_window_handle()).unwrap();
   |                                                                   ^^^^^^^^^^^^^^^^^ method not found in `&WindowHandle`
   |
   = help: items from traits can only be used if the trait is in scope
   = note: the following trait is implemented but not in scope; perhaps add a `use` for it:
           `use raw_window_handle::HasRawWindowHandle;`

Audio stuttering

Audio playback stutters frequently (noticeably a few times throughout a song) despite CPU usage being low and network bandwidth being plentiful.
Nothing is printed to the console.
I use pipewire with pipewire-pulse.

I'm running the latest version in git (643bdd9).

How can I help debug this?

Testers / maintainers of Linux and Windows platform needed

Although Psst code is mostly multi-platform, I use only Mac OS as my daily driver and develop on Mac, and I don't really have the time that other platforms deserve. So, would you like to own and maintain the platform-specific parts of Psst for Windows or Linux? Volunteers wanted!

Build fails installing on macOS 11.3.1 (Apple Silicon, M1)

This is the error I get when cargo build --release OR cargo build --release on my M1 MacBook Air (macOS 11.3.1).

error: failed to run custom build command for `ep-miniaudio-sys v2.4.0 (https://github.com/jpochyla/miniaudio-rs#1ff94282)`

Cannot compile on Arch Linux (pango fails)

Hi, an Arch user made a package for psst in the AUR; however it does not compile due to pango failing; let me know if this is not an issue with this program and I should report it elsewhere.

error: could not compile `pango`

Caused by:
  process didn't exit successfully: `rustc --crate-name pango /home/fra/.local/share/cargo/registry/src/github.com-1ecc6299db9ec823/pango-0.9.1/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C embed-bitcode=no -C metadata=fd47632d393c7c14 -C extra-filename=-fd47632d393c7c14 --out-dir /home/fra/.cache/paru/clone/psst-git/src/psst/target/release/deps -L dependency=/home/fra/.cache/paru/clone/psst-git/src/psst/target/release/deps --extern bitflags=/home/fra/.cache/paru/clone/psst-git/src/psst/target/release/deps/libbitflags-5cbcf9f412d8390c.rmeta --extern glib=/home/fra/.cache/paru/clone/psst-git/src/psst/target/release/deps/libglib-730f694880de99cc.rmeta --extern glib_sys=/home/fra/.cache/paru/clone/psst-git/src/psst/target/release/deps/libglib_sys-7782c43c10f8627b.rmeta --extern gobject_sys=/home/fra/.cache/paru/clone/psst-git/src/psst/target/release/deps/libgobject_sys-28a8e39382bb9e33.rmeta --extern libc=/home/fra/.cache/paru/clone/psst-git/src/psst/target/release/deps/liblibc-3019511b9686418e.rmeta --extern once_cell=/home/fra/.cache/paru/clone/psst-git/src/psst/target/release/deps/libonce_cell-a3e868d9c55edc40.rmeta --extern pango_sys=/home/fra/.cache/paru/clone/psst-git/src/psst/target/release/deps/libpango_sys-f432e2e5b2d01b34.rmeta --cap-lints allow -C opt-level=2 -C target-cpu=native` (signal: 11, SIGSEGV: invalid memory reference)

[GUI] Hovered item not correctly highlighted after scrolling down.

System: macOS 10.15.17

In the song select list its flickering really fast (not visible in the gif) and in the playlist view on the left sidebar it is highlighting the wrong playlist after scrolling down. After scrolling all the way up it is working normally again.

Short-term Roadmap

Here's what I plan on solving in the nearest future:

  • Feedback for invalid credentials in the Preferences dialog
  • Menus & shortcuts on Linux and Windows
  • Media key support on Mac
  • Infinite scrolling or pagination for long playlists and libraries

High CPU usage

I wonder if something is off with my setup because I get pegged at 100% CPU usage when I look up the app in activity monitor. The app seems to run just fine, no noticeable frame drops or anything, but the high CPU usage is concerning. Totally understand if that is a TODO that you aren't worrying about yet, I'm mostly just curious / reporting it in case it is an environment compatibility issue. I'm on a MBP with Catalina

Preferences: Hide password

The password is currently shown in clear text. I think the user is more used to the characters being replaced by dots.

Run Action Builds in Parallel

It'd be great if the Debian build gets executed when the windows build fails. Sequential builds could also be interesting.

image
(from psst/actions/runs/885002673)


Edit:

Found this in the docs: Example not requiring dependent jobs to be successful

jobs:
  job1:
  job2:
    needs: job1
  job3:
    if: always()
    needs: [job1, job2]

needs may not apply, but if: always() sounds promissing.

https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#example-not-requiring-dependent-jobs-to-be-successful

Audio Features Integration

Spotify has a lot of metadata. It'd be nice to view them to some degree.

Example:

GET https://api.spotify.com/v1/audio-features
{
    "audio_features": [
        {
            "danceability": 0.808,
            "energy": 0.626,
            "key": 7,
            "loudness": -12.733,
            "mode": 1,
            "speechiness": 0.168,
            "acousticness": 0.00187,
            "instrumentalness": 0.159,
            "liveness": 0.376,
            "valence": 0.369,
            "tempo": 123.99,
            "type": "audio_features",
            "id": "4JpKVNYnVcJ8tuMKjAj50A",
            "uri": "spotify:track:4JpKVNYnVcJ8tuMKjAj50A",
            "track_href": "https://api.spotify.com/v1/tracks/4JpKVNYnVcJ8tuMKjAj50A",
            "analysis_url": "http://echonest-analysis.s3.amazonaws.com/TR/WhpYUARk1kNJ_qP0AdKGcDDFKOQTTgsOoINrqyPQjkUnbteuuBiyj_u94iFCSGzdxGiwqQ6d77f4QLL_8=/3/full.json?AWSAccessKeyId=AKIAJRDFEY23UEVW42BQ&Expires=1458063189&Signature=JRE8SDZStpNOdUsPN/PoS49FMtQ%3D",
            "duration_ms": 535223,
            "time_signature": 4
        },
        {
            "danceability": 0.457,
            "energy": 0.815,
            "key": 1,
            "loudness": -7.199,
            "mode": 1,
            "speechiness": 0.034,
            "acousticness": 0.102,
            "instrumentalness": 0.0319,
            "liveness": 0.103,
            "valence": 0.382,
            "tempo": 96.083,
            "type": "audio_features",
            "id": "2NRANZE9UCmPAS5XVbXL40",
            "uri": "spotify:track:2NRANZE9UCmPAS5XVbXL40",
            "track_href": "https://api.spotify.com/v1/tracks/2NRANZE9UCmPAS5XVbXL40",
            "analysis_url": "http://echonest-analysis.s3.amazonaws.com/TR/WhuQhwPDhmEg5TO4JjbJu0my-awIhk3eaXkRd1ofoJ7tXogPnMtbxkTyLOeHXu5Jke0FCIt52saKJyfPM=/3/full.json?AWSAccessKeyId=AKIAJRDFEY23UEVW42BQ&Expires=1458063189&Signature=qfclum7FwTaR/7aQbnBNO0daCsM%3D",
            "duration_ms": 187800,
            "time_signature": 4
        },
        {
            "danceability": 0.281,
            "energy": 0.402,
            "key": 4,
            "loudness": -17.921,
            "mode": 1,
            "speechiness": 0.0291,
            "acousticness": 0.0734,
            "instrumentalness": 0.83,
            "liveness": 0.0593,
            "valence": 0.0748,
            "tempo": 115.7,
            "type": "audio_features",
            "id": "24JygzOLM0EmRQeGtFcIcG",
            "uri": "spotify:track:24JygzOLM0EmRQeGtFcIcG",
            "track_href": "https://api.spotify.com/v1/tracks/24JygzOLM0EmRQeGtFcIcG",
            "analysis_url": "http://echonest-analysis.s3.amazonaws.com/TR/ehbkMg05Ck-FN7p3lV7vd8TUdBCvM6z5mgDiZRv6iSlw8P_b8GYBZ4PRAlOgTl3e5rS34_l3dZGDeYzH4=/3/full.json?AWSAccessKeyId=AKIAJRDFEY23UEVW42BQ&Expires=1458063189&Signature=bnTm0Hcb%2Bxo8ZCmuxm1mY0JY4Hs%3D",
            "duration_ms": 497493,
            "time_signature": 3
        }
    ]
}

Docs: https://developer.spotify.com/documentation/web-api/reference/#endpoint-get-several-audio-features (page is very slow for me)

App crashed at the start

@Jan Pochyla , I am checking your code, also applied Spotify account, but after setting .env , get this error:

[2020-08-21T21:08:49Z ERROR rspotify::blocking::oauth2] couldn't open .spotify_token_cache.json: "No such file or directory (os error 2)"

ALso after enter the redirect URL, I got this.

thread 'main' panicked at 'called `Option::unwrap()` on a `None` value', src/database.rs:242:44
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Any idea?

can't run release on macos

matthiasdebernardini@Matthiass-MacBook-Pro ~/g/psst (master) [101]> cargo build --release
Updating git repository https://github.com/jpochyla/miniaudio-rs
error: failed to get miniaudio as a dependency of package psst-core v0.1.0 (/Users/matthiasdebernardini/gits/psst/psst-core)

Caused by:
failed to load source for dependency miniaudio

Caused by:
Unable to update https://github.com/jpochyla/miniaudio-rs#1ff94282

Caused by:
failed to fetch into /Users/matthiasdebernardini/.cargo/git/db/miniaudio-rs-0268a3ab613f78e9

Caused by:
http parser error: stream ended at an unexpected time; class=Http (34)

Thats the error I got, any tips? this looks really nice btw.

Cannot play any song (NixOS)

Hi,

I successfully build and run the app. GUI seems to show that a song is being played, though I cannot hear any sound.

The following appears in the log:

psst/psst-gui (master*) $ cargo run --release 
<... skipping warnings ...>
     Running `/home/user/source/psst/target/release/psst-gui`
[2021-01-26T12:58:08Z INFO  psst_gui::data::config] loading config: "/home/user/.config/Psst/config.json"
[2021-01-26T12:58:08Z WARN  druid::menu] MenuDesc::platform_default is not implemented for this platform.
[2021-01-26T12:58:08Z INFO  psst_core::cache] using cache: "/home/user/.cache/Psst"
[2021-01-26T12:58:08Z INFO  druid_shell::platform::gtk::application] gtk: Activated application
[2021-01-26T12:58:08Z INFO  psst_gui::delegate] session connected
[2021-01-26T12:58:14Z INFO  psst_core::audio_file] blocked at 14697124
[2021-01-26T12:58:14Z INFO  psst_core::audio_file] blocked at 14697124
[2021-01-26T12:58:15Z INFO  psst_core::audio_file] blocked at 14698495
<... snip ...>
[2021-01-26T12:58:15Z INFO  psst_core::audio_player] starting playback
[2021-01-26T12:58:15Z INFO  psst_core::audio_file] blocked at 14698495
[2021-01-26T12:58:15Z INFO  psst_core::audio_file] blocked at 14699866
[2021-01-26T12:58:15Z INFO  psst_core::audio_file] blocked at 14701237
<... snip ...>
[2021-01-26T12:58:15Z INFO  psst_core::audio_player] stale open result received, ignoring

Environment

  • cargo version: cargo 1.51.0-nightly (783bc43c6 2021-01-20)
  • rustc version: rustc 1.51.0-nightly (f4eb5d9f7 2021-01-25)
  • OS: NixOS, pulseaudio

I've found an issue about connection interruption (#10), but my PC is connected via Ethernet cable, and also I cannot play any song at all.

Let me know if any additional information is needed.

OS Bundles

Hello!
First of all, thanks for the amazing project. ❤️ I really appreciate for your efforts to save us from lots of cpu usage (no offense electron's awesome too just a little heavy).
When do you plan to create OS specific bundles? Compilation of the release profile is way too slow. Takes up to an hour with a 1 gig linux instance.

Build errors for arm: armhf and aarch64

Hi! I'm not sure if this nice client is meant to be used on arm-devices, in this case L4T-ubuntu on my Switch.
Anyway , when I try building it for AARCH64 (64 bit) using:
cargo build --release

error: failed to run custom build command for ep-miniaudio-sys v2.4.0 (https://github.com/jpochyla/miniaudio-rs#1ff94282)

More Caused by: process didn't exit successfully: `/home/retropie/Downloads/psst/psst/target/release/build/ep-miniaudio-sys-9346f72f0f4095e6/build-script-build` (exit code: 101) --- stdout TARGET = Some("aarch64-unknown-linux-gnu") OPT_LEVEL = Some("3") HOST = Some("aarch64-unknown-linux-gnu") CC_aarch64-unknown-linux-gnu = None CC_aarch64_unknown_linux_gnu = None HOST_CC = None CC = None CFLAGS_aarch64-unknown-linux-gnu = None CFLAGS_aarch64_unknown_linux_gnu = None HOST_CFLAGS = None CFLAGS = None CRATE_CC_NO_DEFAULTS = None DEBUG = Some("false") CARGO_CFG_TARGET_FEATURE = None CC_aarch64-unknown-linux-gnu = None CC_aarch64_unknown_linux_gnu = None HOST_CC = None CC = None CFLAGS_aarch64-unknown-linux-gnu = None CFLAGS_aarch64_unknown_linux_gnu = None HOST_CFLAGS = None CFLAGS = None CRATE_CC_NO_DEFAULTS = None CARGO_CFG_TARGET_FEATURE = None running: "cc" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-I" "./miniaudio" "-Wall" "-Wextra" "-Wno-unused-function" "-DMINIAUDIO_IMPLEMENTATION=" "-DMA_NO_FLAC=1" "-DMA_NO_MP3=1" "-DMA_NO_WAV=1" "-DMA_LOG_LEVEL=1" "-o" "/home/retropie/Downloads/psst/psst/target/release/build/ep-miniaudio-sys-368fa8058b732cd1/out/./miniaudio-wrapper.o" "-c" "./miniaudio-wrapper.c" exit code: 0 AR_aarch64-unknown-linux-gnu = None AR_aarch64_unknown_linux_gnu = None HOST_AR = None AR = None running: "ar" "cq" "/home/retropie/Downloads/psst/psst/target/release/build/ep-miniaudio-sys-368fa8058b732cd1/out/liblibminiaudio.a" "/home/retropie/Downloads/psst/psst/target/release/build/ep-miniaudio-sys-368fa8058b732cd1/out/./miniaudio-wrapper.o" exit code: 0 running: "ar" "s" "/home/retropie/Downloads/psst/psst/target/release/build/ep-miniaudio-sys-368fa8058b732cd1/out/liblibminiaudio.a" exit code: 0 cargo:rustc-link-lib=static=libminiaudio cargo:rustc-link-search=native=/home/retropie/Downloads/psst/psst/target/release/build/ep-miniaudio-sys-368fa8058b732cd1/out cargo:rustc-cfg=feature="ma-unix" cargo:rustc-cfg=feature="ma-linux" cargo:rustc-cfg=feature="ma-posix" cargo:rustc-cfg=feature="ma-support-alsa" cargo:rustc-cfg=feature="ma-support-pulseaudio" cargo:rustc-cfg=feature="ma-support-jack" cargo:rustc-cfg=feature="ma-support-null" cargo:rustc-cfg=feature="ma-enable-jack" cargo:rustc-cfg=feature="ma-enable-alsa" cargo:rustc-cfg=feature="ma-enable-pulseaudio" cargo:rustc-cfg=feature="ma-enable-null" cargo-warning=using pre-generated bindings - these are not guaranteed to always work (!!!)

--- stderr
thread 'main' panicked at 'bindings for linux-aarch64 do not exist in bindings/linux-aarch64, please enable the bindgen feature instead', /root/.cargo/git/checkouts/miniaudio-rs-0268a3ab613f78e9/1ff9428/miniaudio-sys/build.rs:60:9
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
error: build failed

I gave it a try crosscompiling for ARMHF (32 bit) using:
PKG_CONFIG_PATH=/usr/lib/arm-linux-gnueabihf/pkgconfig PKG_CONFIG_ALLOW_CROSS=1 cargo build --target=arm-unknown-linux-gnueabihf --release

I receive:
error: failed to run custom build command for ring v0.16.20

More Caused by: process didn't exit successfully: `/home/retropie/Downloads/psst/psst/target/release/build/ring-1d58efa7e298e7fa/build-script-build` (exit code: 101) --- stdout OPT_LEVEL = Some("3") TARGET = Some("arm-unknown-linux-gnueabihf") HOST = Some("aarch64-unknown-linux-gnu") CC_arm-unknown-linux-gnueabihf = None CC_arm_unknown_linux_gnueabihf = None TARGET_CC = None CC = None CROSS_COMPILE = None CFLAGS_arm-unknown-linux-gnueabihf = None CFLAGS_arm_unknown_linux_gnueabihf = None TARGET_CFLAGS = None CFLAGS = None CRATE_CC_NO_DEFAULTS = None DEBUG = Some("false") CARGO_CFG_TARGET_FEATURE = None

--- stderr
running "arm-linux-gnueabihf-gcc" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-march=armv6" "-marm" "-mfpu=vfp" "-I" "include" "-Wall" "-Wextra" "-pedantic" "-pedantic-errors" "-Wall" "-Wextra" "-Wcast-align" "-Wcast-qual" "-Wconversion" "-Wenum-compare" "-Wfloat-equal" "-Wformat=2" "-Winline" "-Winvalid-pch" "-Wmissing-field-initializers" "-Wmissing-include-dirs" "-Wredundant-decls" "-Wshadow" "-Wsign-compare" "-Wsign-conversion" "-Wundef" "-Wuninitialized" "-Wwrite-strings" "-fno-strict-aliasing" "-fvisibility=hidden" "-fstack-protector" "-g3" "-DNDEBUG" "-c" "-o/home/retropie/Downloads/psst/psst/target/arm-unknown-linux-gnueabihf/release/build/ring-e6ba255990d1bed0/out/aesv8-armx-linux32.o" "/root/.cargo/registry/src/github.com-1ecc6299db9ec823/ring-0.16.20/pregenerated/aesv8-armx-linux32.S"
thread 'main' panicked at 'failed to execute ["arm-linux-gnueabihf-gcc" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-march=armv6" "-marm" "-mfpu=vfp" "-I" "include" "-Wall" "-Wextra" "-pedantic" "-pedantic-errors" "-Wall" "-Wextra" "-Wcast-align" "-Wcast-qual" "-Wconversion" "-Wenum-compare" "-Wfloat-equal" "-Wformat=2" "-Winline" "-Winvalid-pch" "-Wmissing-field-initializers" "-Wmissing-include-dirs" "-Wredundant-decls" "-Wshadow" "-Wsign-compare" "-Wsign-conversion" "-Wundef" "-Wuninitialized" "-Wwrite-strings" "-fno-strict-aliasing" "-fvisibility=hidden" "-fstack-protector" "-g3" "-DNDEBUG" "-c" "-o/home/retropie/Downloads/psst/psst/target/arm-unknown-linux-gnueabihf/release/build/ring-e6ba255990d1bed0/out/aesv8-armx-linux32.o" "/root/.cargo/registry/src/github.com-1ecc6299db9ec823/ring-0.16.20/pregenerated/aesv8-armx-linux32.S"]: No such file or directory (os error 2)', /root/.cargo/registry/src/github.com-1ecc6299db9ec823/ring-0.16.20/build.rs:653:9

I think this client looks beautiful and I'd love to have it up running, but I totally understand if it's not supported.
Thanks!

Error when decoding audio (Hole)

Hi, really like the project!

Once in a while, an error occures when decoding the audio and the player skips to the next song.
This is what I get in the terminal:

[2021-01-04T13:45:47Z ERROR psst_core::audio_decode] error while decoding: Hole

Not sure how to reproduce this.
I'm running this in Fedora.

No function `new_with_name` for struct `MediaControls`

When installing from the aur (https://aur.archlinux.org/packages/psst-git/) I got the following error:

   Compiling psst-gui v0.1.0 (/home/oliver/.cache/yay/psst-git/src/psst/psst-gui)
error[E0599]: no function or associated item named `new_with_name` found for struct `MediaControls` in the current scope
  --> psst-gui/src/controller/playback.rs:87:49
   |
87 |         let mut media_controls = MediaControls::new_with_name("psst", "Psst");
   |                                                 ^^^^^^^^^^^^^ function or associated item not found in `MediaControls`

error: aborting due to previous error

For more information about this error, try `rustc --explain E0599`.
error: could not compile `psst-gui`

To learn more, run the command again with --verbose.
==> ERROR: A failure occurred in build().
    Aborting...
error making: psst-git

Hang after connection timeout

The app seems to hang after a connection timeout:

[2021-01-05T10:00:17Z ERROR psst_core::audio_file] failed to download: timed out reading response

After this, selecting a new song doesn't seem to solve the problem.

Issue building on Pop-OS

Hi, I'm on Pop-OS 20.04, and I get the following error when I try to build the program using cargo build --release

error[E0658]: `match` is not allowed in a `const fn`

Originally I got an open-ssl error, which I got around by installing openssl-dev, but I'm not sure how to get around this one.

While I'm thinking of it, I know this is super early days for this project, but it would be awesome to release the app as a Flatpak. I love the idea, and think it will get heavy use once it is stable.

Add UI for incorrect credentials?

Currently there is logging for incorrect credentials, but there is no way to see in the interface that the credentials have been saved, updated, are incorrect, or are already saved and won't be replaced since they are the same.

Screen Shot 2021-01-04 at 5 02 40 PM

Undefined Symbol Error

The error I get when I start psst-gui:

psst-gui: symbol lookup error: psst-gui: undefined symbol: pango_attr_insert_hyphens_new

I'm on Debian 10. Installed psst via the .deb package provides in the actions (from commit 0161cc1).

Hangs after connection is lost

After connection is lost and reset, the player hangs (running with WiFi).
This is the output:

[2021-01-04T15:21:39Z ERROR psst_gui::delegate] connection error: IoError(Os { code: 104, kind: ConnectionReset, message: "Connection reset by peer" })
[2021-01-04T15:21:42Z INFO psst_gui::delegate] session connected
[2021-01-04T15:22:07Z INFO psst_core::stream_storage] blocked at 8992924
[2021-01-04T15:22:07Z INFO psst_core::stream_storage] blocked at 7408684
[2021-01-04T15:22:07Z INFO psst_core::stream_storage] blocked at 7447668
[2021-01-04T15:22:07Z INFO psst_core::stream_storage] blocked at 6179592
[2021-01-04T15:22:07Z INFO psst_core::audio_player] stale open result received, ignoring

After this, nothing happens, unless selecting a new song.

Player and general opinion

Hey, I really like your project. I'd like to collaborate but the roudmap you gave is way too general for me to be able to just pick and do something. Anyways, I want to share my experience using the player (I'm on Windows btw, no idea if those are specific bugs):

  • It's really slow to use. Are you waiting for the web confirmation to change the play state? The music keeps running for about 2s after I click pause and seeking takes ages.
  • The pause button stays a pause button even after pausing the track until I click it again, which changes it to the play button but does not start playing the song until I click a second time on it.
  • Starting songs rapidly in succession will start playing each one of them for a brief moment after they finally loaded and not only the song that is currently selected at that point.

General personal opinion (debatable):

  • Single clicking songs in playlists should not start playing them (at least not if clicking into the previously unfocused window).
  • The player should be bigger and not 50:50 with the title (nothing has a title this long).
  • All in all the player feels really out of sync with the gui. Maybe show changes only once they are actually in effect?
  • The currently selected playlist should be highlighted like "Home" and "Library".
  • The search bar looks a bit out of place.
  • Otherwise I love the gui, it looks great and is intuitive.

Searching for playlists

Is it possible to show user created playlists when searching? Artists, Albums and Tracks already show up when searching.

Thank you for your awesome work so far!

Support spotify connect

Spotify has this Connect feature that allows one to play audio on other devices logged into the same account and control the playback remotely. I would love to see this feature beeing part of psst as I often like to use my pc to control playback on my phone that is connected to some speakers by cable or is just out of reach.

Can't type credentials

XFCE Manjaro Linux 5.10.36-2-MANJARO

When I open the program, it shows settings and asks for my credentials. I can click on the buttons and on the text fields but when I try to type, nothing gets written, and whatever I type gets typed on whatever the window was that I had opened before opening psst.

If I click save and go to the main app and try to type there (eg the search bar), typing works fine, but when i open settings again, it doesnt send the text to it, it only sends it to the main app. This means it's probably a problem with the settings specifically.

This is pretty crucial for me because I can't sign in at all.

Long playlists/albums not working

Only the first songs of a playlist are shown. I haven't counted the number of the songs, but I'd guess the first 50 songs are displayed.

Playback shuffle and looping controls

So far this has been great for me, minimal issues. One thing that is keeping this from being the only thing I use is a shuffle/random option. I was looking through the code and would like to contribute code for this purpose. If this is good with you I'll spend some time looking through code to find places to update but any info would be great!

I do see there are SVG icons for the control buttons, how were these generated in case we will need more?

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.