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

nixos/packagekit: make it not error out + test #60146

Merged
merged 2 commits into from Apr 26, 2019

Conversation

peterhoeg
Copy link
Member

@peterhoeg peterhoeg commented Apr 24, 2019

Motivation for this change

We have a nixos module for packagekit, but it doesn't work as we do not have a backend for nix (#21230) so we now make the backend configurable and set it to test_nop which at least means that other software depending on packagekit (#34756 needs it) will at least not error out complaining about not being able to connect to to packagekit over dbus.

Cc: @peti @matthewbauer @wizeman

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • 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 nix-review --run "nix-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)
  • Assured whether relevant documentation is up to date
  • Fits CONTRIBUTING.md.

Copy link
Contributor

@worldofpeace worldofpeace left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commit msg should be
nixos/packagekit: make it not error out

@worldofpeace
Copy link
Contributor

Out of scope of this change, but this has polkit stuff so it probably needs to be in environment.systemPackages too.

@peterhoeg peterhoeg force-pushed the f/packagekit branch 2 times, most recently from c842f69 to 5f18694 Compare April 24, 2019 08:50
@peterhoeg
Copy link
Member Author

Out of scope of this change, but this has polkit stuff so it probably needs to be in environment.systemPackages too.

Yikes, wasn't aware of that. We really should have a nicer way to deal with policykit rules than adding them to the global environment.

Leaving that out for now as we cannot actually do anything with policykit due to the missing backend, so it doesn't ever need elevated permissions.

@peterhoeg peterhoeg changed the title packagekit (nixos): make it not error out nixos/packagekit: make it not error out + test Apr 24, 2019
@peterhoeg
Copy link
Member Author

@GrahamcOfBorg test packagekit

@worldofpeace
Copy link
Contributor

Yikes, wasn't aware of that. We really should have a nicer way to deal with policykit rules than adding them to the global environment.

Totally agree on that, definitely something to make issue out of.

Leaving that out for now as we cannot actually do anything with policykit due to the missing backend, so it doesn't ever need elevated permissions.

Maybe add a TODO?

@peterhoeg peterhoeg force-pushed the f/packagekit branch 2 times, most recently from 8de9746 to d39036e Compare April 24, 2019 09:12
@peterhoeg
Copy link
Member Author

Leaving that out for now as we cannot actually do anything with policykit due to the missing backend, so it doesn't ever need elevated permissions.

Maybe add a TODO?

Done

@peterhoeg
Copy link
Member Author

@GrahamcOfBorg test packagekit

</para>
<para>
On NixOS however, we do not have a backend compatible with nix 2.0
(refer to https://github.com/NixOS/nix/issues/233) so we have to force
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably should use a link like <link xlink:href="https://theissue">Some words</link>

type = types.enum [ "test_nop" ];
default = "test_nop";
description = ''
PackageKit supports multiple different backends and `auto` which
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
PackageKit supports multiple different backends and `auto` which
PackageKit supports multiple different backends and <literal>auto</literal> which

@peterhoeg peterhoeg merged commit eb6ce1c into NixOS:master Apr 26, 2019
@peterhoeg
Copy link
Member Author

@worldofpeace all your comments have been addressed.

@peterhoeg peterhoeg deleted the f/packagekit branch April 26, 2019 06:20
@worldofpeace
Copy link
Contributor

Thank you for fixing this @peterhoeg

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

2 participants