Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

slimserver: add perlPackages.ArchiveZip as a dependency #108612

Merged
merged 1 commit into from Jan 7, 2021

Conversation

mfrischknecht
Copy link
Contributor

@mfrischknecht mfrischknecht commented Jan 6, 2021

Motivation for this change

slimserver is missing perlPackages.ArchiveZip as a dependency. This causes its PluginDownloader to fail with the following message:

Slim::Utils::PluginDownloader::extract (102) error loading Archive::Zip Can't locate Archive/Zip.pm in @INC (you may need to install the Archive::Zip module) (@INC contains: /var/lib/slimserver/cache/InstalledPlugins [...])

I was able to consistently reproduce this by trying to install the Spotify plugin on new Slimserver instances. The WebUI will prompt a server restart, after which the message above can be found with journalctl -b -u slimserver.

For a while, I had a custom override in place which fixed this issue on my local machine. If slimserver has already been running like this, it will continue to work even when the dependency is removed, since it caches all plugins in its cache folder. To reproduce it, I simply had to wipe the cache and preference folders clean.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

Slimserver uses `Archive::Zip`, in order to unpack plugins before
installing them. Without this dependency, its `PluginDownloader`
module will fail, printing the following error message instead:

Slim::Utils::PluginDownloader::extract (102) error loading Archive::Zip
Can't locate Archive/Zip.pm in @inc (you may need to install the Archive:
:Zip module) (@inc contains: [...])
@mfrischknecht
Copy link
Contributor Author

mfrischknecht commented Jan 6, 2021

I tested this change by rebasing it onto nixos-20.09 (git rebase --onto origin/nixos-20.09 HEAD^) and performing nixos-rebuild -I "nixpkgs=$(pwd)" switch, after which I was able to install the Spotify plugin via the web UI on my x64 NAS.

I still have trouble doing the same on a Raspberry PI 4 due to some issues with a seemingly missing IOSocketSSL includes (which are in the Nix expression, though). I'll open an issue for this, as I wasn't able to figure out a fix myself.

Edit: See #108617

@mfrischknecht mfrischknecht changed the title nixos/slimserver: add perlPackages.ArchiveZip as a dependency slimserver: add perlPackages.ArchiveZip as a dependency Jan 6, 2021
@SuperSandro2000
Copy link
Member

This is a semi-automatic executed nixpkgs-review which does not build all packages (e.g. lumo, tensorflow or pytorch)
If you find some bugs or got suggestions for further things to search or run please reach out to SuperSandro2000 on IRC.

Result of nixpkgs-review pr 108612 run on x86_64-linux 1

1 package built:
  • slimserver

@SuperSandro2000
Copy link
Member

Result of nixpkgs-review pr 108612 run on x86_64-darwin 1

1 package marked as broken and skipped:
  • slimserver

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants