Skip to content

python3Packages.brottsplatskartan: init at 1.0.5 #110816

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

Merged
merged 2 commits into from
Jan 25, 2021

Conversation

fabaff
Copy link
Member

@fabaff fabaff commented Jan 25, 2021

Motivation for this change

Python API wrapper for brottsplatskartan.se

https://github.com/chrillux/brottsplatskartan

This is a Home Assistant dependency.

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.

Sorry, something went wrong.

@ofborg ofborg bot added 6.topic: python 8.has: package (new) This PR adds a new package 11.by: package-maintainer This PR was created by the maintainer of the package it changes 10.rebuild-darwin: 1-10 10.rebuild-linux: 1-10 labels Jan 25, 2021
@dotlambda
Copy link
Member

@fabaff May I ask why you are packaging all those Home Assistant dependencies? Seems like you're taking on a huge burden by maintaining all of them?

@SuperSandro2000
Copy link
Member

This is a semi-automatic executed nixpkgs-review which is checked by a human on a best effort basis and does not build all packages (e.g. lumo, tensorflow or pytorch).
If you have any questions or problems please reach out to SuperSandro2000 on IRC.

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

3 packages built:
  • python37Packages.brottsplatskartan
  • python38Packages.brottsplatskartan
  • python39Packages.brottsplatskartan

@SuperSandro2000
Copy link
Member

This is a semi-automatic executed nixpkgs-review which is checked by a human on a best effort basis and does not build all packages (e.g. lumo, tensorflow or pytorch).
If you have any questions or problems please reach out to SuperSandro2000 on IRC.

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

3 packages built:
  • python37Packages.brottsplatskartan
  • python38Packages.brottsplatskartan
  • python39Packages.brottsplatskartan

@SuperSandro2000 SuperSandro2000 merged commit 080e13d into NixOS:master Jan 25, 2021
@fabaff fabaff deleted the brottsplatskartan branch January 26, 2021 07:57
@fabaff
Copy link
Member Author

fabaff commented Jan 26, 2021

May I ask why you are packaging all those Home Assistant dependencies? Seems like you're taking on a huge burden by maintaining all of them?

I still have the romantic idea of beging able to install Home Assistant and be ready to go. No waiting till all required dependencies are installed during the first start, start again because g++ is missing and again because some devel libs are not present.

Approx. 90 % of the dependencies are very low maintenance. And the rest seems to be covered as those are broadly used Python modules. It's undeniable that at every new packages introduces possible risks and the possibility for extra work in the future.

I guess that in the meantime 50 % of Home Assistant's dependencies are present. It will not be possible to provide every dependency in the end due to licensing issues and other reasons but let's say 90 %. This would give one the option to run home automation in a very lean and highly customizable way without permanently depending on a internet uplink after the installation.

@dotlambda
Copy link
Member

I still have the romantic idea of beging able to install Home Assistant and be ready to go. No waiting till all required dependencies are installed during the first start, start again because g++ is missing and again because some devel libs are not present.

Approx. 90 % of the dependencies are very low maintenance. And the rest seems to be covered as those are broadly used Python modules. It's undeniable that at every new packages introduces possible risks and the possibility for extra work in the future.

I guess that in the meantime 50 % of Home Assistant's dependencies are present. It will not be possible to provide every dependency in the end due to licensing issues and other reasons but let's say 90 %. This would give one the option to run home automation in a very lean and highly customizable way without permanently depending on a internet uplink after the installation.

I certainly see the benefit of that and it's why I started the Home Assistant module for NixOS a couple of years back. However, I just don't see normal Home Assistant users choosing to run it on NixOS. Those who do are enthusiasts who are able to package the dependencies they miss anyway.
The problem with Home Assistant is that the direction it's taking is orthogonal to the principles behind NixOS:

  • The dynamic installation of dependencies certainly makes sense for novice users but is downright scary for anyone who is used to installing packages with a package manager. Reminds of e.g. the Dropbox client for Linux downloading a binary to $HOME/... and exec'ing that. Luckily, --skip-pip solves that issue.
  • As far as I know, the NixOS module is still not able to work around the onboarding process and there is no upstream documentation of how to skip it. That means that the configuration is not actually entirely declarative.
  • Configuration can in principle be done in YAML but it seems like Home Assistant is moving towards configuration from the web interface. That isn't a problem if everything can still be configured in YAML and all options are properly documented. But I'm not sure that's the case.

To be fair, I haven't had a real look at Home Assistant in a long time, so my information might be outdated.

@fabaff
Copy link
Member Author

fabaff commented Jan 29, 2021

Those who do are enthusiasts who are able to package the dependencies they miss anyway.

Indeed, but I like to think that if the dependencies are present then people can save time and not have to repeat the work. Also, some dependencies are useful if one is interested in common IoT stuff.

As far as I know, the NixOS module is still not able to work around the onboarding process and there is no upstream documentation of how to skip it. That means that the configuration is not actually entirely declarative.

The documentation is having holes. At some point in the future everything will probably be configured through the web interface and stored in .storage. My hacky way for now is to write the data in .storage right after the installation. Will not work for all situations of course.

Configuration can in principle be done in YAML but it seems like Home Assistant is moving towards configuration from the web interface.

The "move-away-from-YAML" decision makes the usage easier for the average users when discovery is helping and the platforms are popular. The downside is flexibility was lost and the mixture at the moment

To be fair, I haven't had a real look at Home Assistant in a long time, so my information might be outdated.

No, they are pretty much match with mine 😉 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.topic: python 8.has: package (new) This PR adds a new package 10.rebuild-darwin: 1-10 10.rebuild-linux: 1-10 11.by: package-maintainer This PR was created by the maintainer of the package it changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants