-
Notifications
You must be signed in to change notification settings - Fork 83
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 package #86
Comments
Hi, |
* Global version added * Flag icons added to menu * Flag icons license information added to ICON-AUTHORS * About dialog added * Refactored application settings module * Added separate settingshelper module #86 * Test cases fixed
Hi @ciferkey, Kind regards |
Thank you for the response. I just reran the build with 1.3.1-6 and I'm getting the same error message:
|
Thanks for the fast feedback. I missed the intrinsic settings import in file.py. Will try to fix tomorrow. |
* Moved state image to TlpConfig items * Code refactorings
Hi @ciferkey, |
Hmm unfortunately I'm still getting a similar exception:
|
Hi @ciferkey, Thanks in advance |
Hi @ciferkey, |
Thanks for the follow ups. Here's the most recent default.nix:
When I run it it now produces:
I'm wondering now if the display warning might be related to Wayland? I'll take some more time to experiment but wanted to give you and update first. |
Hi @ciferkey, Add tox in first line like
If this does not work please add:
To see if it even builds without testing. If this still does not work I might have to look deeper into building nix packages, but this might take some time. Cheers |
Hi @ciferkey, |
@d4nj1 Thanks for reaching out. Life has gotten recently so I've not been able to look into this right. I'm hoping to get back to it once I have time. |
@ciferkey Thanks for the feedback. I'm currently also under proper load, so you have my full understanding. I wish you strength and energy for whatever challenge there is. Kind regards |
I close this for now. Please feel free to reopen anytime. |
Hello, I built a working derivation with one problem. When the application is starting it tries to read the intrinsic default file path /nix/store/x21576pb3spqqzwpkg89damd5ygr9z6f-python3.9-tlpui-1.5.0-5/bin/tlpui
Traceback (most recent call last):
File "/nix/store/x21576pb3spqqzwpkg89damd5ygr9z6f-python3.9-tlpui-1.5.0-5/bin/..tlpui-wrapped-wrapped", line 9, in <module>
sys.exit(main())
File "/nix/store/x21576pb3spqqzwpkg89damd5ygr9z6f-python3.9-tlpui-1.5.0-5/lib/python3.9/site-packages/tlpui/__main__.py", line 31, in main
init_tlp_file_config()
File "/nix/store/x21576pb3spqqzwpkg89damd5ygr9z6f-python3.9-tlpui-1.5.0-5/lib/python3.9/site-packages/tlpui/file.py", line 40, in init_tlp
_file_config
settings.tlpconfig_defaults = get_tlp_config_defaults(tlpversion)
File "/nix/store/x21576pb3spqqzwpkg89damd5ygr9z6f-python3.9-tlpui-1.5.0-5/lib/python3.9/site-packages/tlpui/file.py", line 31, in get_tlp_
config_defaults
tlpconfig_defaults.update(extract_default_tlp_configs(intrinsic_defaults_path))
File "/nix/store/x21576pb3spqqzwpkg89damd5ygr9z6f-python3.9-tlpui-1.5.0-5/lib/python3.9/site-packages/tlpui/filehelper.py", line 46, in ex
tract_default_tlp_configs
fileopener = open(filename)
FileNotFoundError: [Errno 2] No such file or directory: '/usr/share/tlp/defaults.conf' While manually creating a blank file at |
@GeorgesAlkhouri |
The intrinsic defaults are packaged and distributed within the nix-build result. The link to tlp is done via the make flags DESTDIR and TLP_CONFDEF. Also consider this comment for more clarification. |
What do you think @d4nj1 ? |
@GeorgesAlkhouri Could you change the PR to something like:
Would that work for you? |
As far as I am understandingt this, |
Just a heads-up that the Guix tlpui package also seems to run into the same issue: (.tlpui-real:6890): Gtk-WARNING **: 09:19:16.758: Locale not supported by C library.
Using the fallback 'C' locale.
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LC_CTYPE = "en_US.UTF-8",
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LC_CTYPE = "en_US.UTF-8",
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
Traceback (most recent call last):
File "/gnu/store/yi977fxj546v05jvw6k5vpxr752pix9r-tlpui-1.5.0-7/bin/.tlpui-real", line 33, in <module>
sys.exit(load_entry_point('TLPUI==1.5.0.post7', 'gui_scripts', 'tlpui')())
File "/gnu/store/yi977fxj546v05jvw6k5vpxr752pix9r-tlpui-1.5.0-7/lib/python3.10/site-packages/tlpui/__main__.py", line 31, in main
init_tlp_file_config()
File "/gnu/store/yi977fxj546v05jvw6k5vpxr752pix9r-tlpui-1.5.0-7/lib/python3.10/site-packages/tlpui/file.py", line 40, in init_tlp_file_config
settings.tlpconfig_defaults = get_tlp_config_defaults(tlpversion)
File "/gnu/store/yi977fxj546v05jvw6k5vpxr752pix9r-tlpui-1.5.0-7/lib/python3.10/site-packages/tlpui/file.py", line 31, in get_tlp_config_defaults
tlpconfig_defaults.update(extract_default_tlp_configs(intrinsic_defaults_path))
File "/gnu/store/yi977fxj546v05jvw6k5vpxr752pix9r-tlpui-1.5.0-7/lib/python3.10/site-packages/tlpui/filehelper.py", line 46, in extract_default_tlp_configs
fileopener = open(filename)
FileNotFoundError: [Errno 2] No such file or directory: "'/gnu/store/chi79kcl74gr4spix4xqlqgx95sf4rci-tlp-1.5.0/share/tlp/defaults.conf'" Package definition is at https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/linux.scm#n7787 |
I'm looking to build TLPUI (most recent release) on NixOS. It seems the TLPUI build process tries to read your configuration from /etc/tlp.conf during build time (possibly in a test?). This fails on NixOS where the builds are sandboxed.
Is there any way to disable this while building or to provide a parameter during the build for an alternate path for the configuration file?
Here is the stack trace from the build failure:
Note the "Error: cannot read user configuration from /etc/tlp.conf or /etc/default/tlp."
If you are curious about the NixOS specifics there's more details on my Stack Overflow question.
The text was updated successfully, but these errors were encountered: