Giter Site home page Giter Site logo

Comments (26)

loqusion avatar loqusion commented on June 11, 2024 2

As a side note, it's strange that the error Couldn't connect to /tmp/hypr/.../.socket.sock happens with hyprshade ls but not with hyprshade on, since they're both running hyprctl under the hood.

So, it turns out I was completely wrong about this: it's not strange. And the reason is this: the only reason hyprshade ls was failing and reporting the error is because it tried to parse the output of hyprctl as JSON, whereas hyprshade on runs hyprctl and only reports an error if the exit code is non-zero... except, the exit code of hyprctl is not non-zero if it fails to connect to the Hyprland socket. hyprctl's general method of reporting errors is to print an error message to stdout, which makes it difficult to detect every error programatically unless we make assumptions about the formatting of the error message which have no guarantee of remaining correct in the future. (Proper exit code implementation was actually added a few days ago, so at least we won't have to worry about this any more eventually.)

While we have yet to determine with 100% certainty whether hyprshade on runs hyprctl properly, I think it's safe to assume that it is, and that it's experiencing the same error as with hyprshade ls but not reporting it for reasons elaborated on above.


Now, that begs the question: why is hyprctl failing to connect to the socket? More specifically, why does hyprctl succeed in connecting to the socket when run interactively, but not as a subprocess of hyprshade?

from hyprshade.

willswats avatar willswats commented on June 11, 2024 2
(pkgs.hyprshade.override {
  hyprland = inputs.hyprland.packages.${pkgs.system}.hyprland;
})

I'm on flakes, yeah. Did you add this directly to the inputs block of flake.nix? Or add it somewhere else?

Add it to environment.systemPackages:

{ pkgs, inputs, ... }:

{
  environment.systemPackages = [
    (pkgs.hyprshade.override {
      hyprland = inputs.hyprland.packages.${pkgs.system}.hyprland;
    })
  ];
}

Or home.packages if you are using home-manager:

{ pkgs, inputs, ... }:

{
  home.packages = [
    (pkgs.hyprshade.override {
      hyprland = inputs.hyprland.packages.${pkgs.system}.hyprland;
    })
  ];
}

And If you haven't done so already, you will also need to add @inputs to the outputs part of your flake, and then inherit inputs in specialArgs, or in extraSpecialArgs for home-manager so that you can access inputs as an argument.

from hyprshade.

willswats avatar willswats commented on June 11, 2024 1

I have the same issue on NixOS with Hyprland git (commit c21a5a934061c248ff1cdd459a74a05b621fb427), however, on Hyprland v0.39.1 hyprshade (3.2.1) works fine.

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024 1

By the way, I couldn't reproduce the error on the development version of Hyprland (f8857e6) in Arch Linux (btw), so I'm going to assume this error is specific to NixOS until proven otherwise. I've also updated the title to reflect that.

from hyprshade.

markaacosta avatar markaacosta commented on June 11, 2024 1

@willswats I've got all that other scaffolding and have modularized things pretty well, but I hadn't seen this construct for overriding specific attributes or dependencies for a package. Thanks for the great tip - and @loqusion this also definitely fixed / rolled back hyprshade for me!

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024 1

Great! I'll pin the issue in case it helps anyone else experiencing the same error, and hide some comments to increase visibility of the solution.

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024

The hyprshade available on nixpkgs is version 0.12.1, the latest stable version is 3.2.1. Try installing from PyPI and let me know the output of hyprshade -v on <SHADER> and hyprshade -v ls -l.

from hyprshade.

markaacosta avatar markaacosta commented on June 11, 2024

I'm seeing the issue on 3.2.1 (I use the 'nix unstable' channel which is ahead of nix 23.11). Here's the output below:


hyprshade -v on blue-light-filter.glsl.mustache

here I pass the path and it looks in the standard /nix/store/* and $HOME/.config/hypr/shaders/ directories:

Traceback (most recent call last):
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/bin/.hyprshade-wrapped", line 9, in <module>
    sys.exit(main())
             ^^^^^^
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/cli/__init__.py", line 44, in main
    raise e
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/cli/__init__.py", line 41, in main
    return cli()
           ^^^^^
  File "/nix/store/a9illw5w19kdzrl312h10hk39w36xx46-python3.11-click-8.1.7/lib/python3.11/site-packages/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/a9illw5w19kdzrl312h10hk39w36xx46-python3.11-click-8.1.7/lib/python3.11/site-packages/click/core.py", line 1078, in main
    rv = self.invoke(ctx)
         ^^^^^^^^^^^^^^^^
  File "/nix/store/a9illw5w19kdzrl312h10hk39w36xx46-python3.11-click-8.1.7/lib/python3.11/site-packages/click/core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/a9illw5w19kdzrl312h10hk39w36xx46-python3.11-click-8.1.7/lib/python3.11/site-packages/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/a9illw5w19kdzrl312h10hk39w36xx46-python3.11-click-8.1.7/lib/python3.11/site-packages/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/cli/on.py", line 18, in on
    shader.on()
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/shader/core.py", line 96, in on
    path_ = self._resolve_path()
            ^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/shader/core.py", line 114, in _resolve_path
    return self._resolve_path_from_shader_dirs()
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/shader/core.py", line 123, in _resolve_path_from_shader_dirs
    raise FileNotFoundError(
FileNotFoundError: Shader 'blue-light-filter.glsl' could not be found in any of the following directories:
	/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/share/hyprshade/shaders
	/home/marka/.config/hypr/shaders

hyprshade -v on ./blue-light-filter.glsl.mustache

here I pass with the explicit leading ./ and it points to the shader in my current directory. It doesn't turn on, despite the shorter output that mentions it is turning on:

DEBUG:root:Turning on shader 'blue-light-filter.glsl' at '/home/marka/Downloads/blue-light-filter.glsl.mustache'

hyprshade -v ls -l

output with the '-v' flag:

Traceback (most recent call last):
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/shader/hyprctl.py", line 57, in get_screen_shader
    shader_json = json.loads(hyprctl_pipe.stdout)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/k3701zl6gmx3la7y4dnflcvf3xfy88kh-python3-3.11.9/lib/python3.11/json/__init__.py", line 346, in loads
    return _default_decoder.decode(s)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/k3701zl6gmx3la7y4dnflcvf3xfy88kh-python3-3.11.9/lib/python3.11/json/decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/k3701zl6gmx3la7y4dnflcvf3xfy88kh-python3-3.11.9/lib/python3.11/json/decoder.py", line 355, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/bin/.hyprshade-wrapped", line 9, in <module>
    sys.exit(main())
             ^^^^^^
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/cli/__init__.py", line 44, in main
    raise e
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/cli/__init__.py", line 41, in main
    return cli()
           ^^^^^
  File "/nix/store/a9illw5w19kdzrl312h10hk39w36xx46-python3.11-click-8.1.7/lib/python3.11/site-packages/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/a9illw5w19kdzrl312h10hk39w36xx46-python3.11-click-8.1.7/lib/python3.11/site-packages/click/core.py", line 1078, in main
    rv = self.invoke(ctx)
         ^^^^^^^^^^^^^^^^
  File "/nix/store/a9illw5w19kdzrl312h10hk39w36xx46-python3.11-click-8.1.7/lib/python3.11/site-packages/click/core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/a9illw5w19kdzrl312h10hk39w36xx46-python3.11-click-8.1.7/lib/python3.11/site-packages/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/a9illw5w19kdzrl312h10hk39w36xx46-python3.11-click-8.1.7/lib/python3.11/site-packages/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/cli/ls.py", line 75, in ls
    shaders = ShaderWithMeta.get_shaders_list()
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/cli/ls.py", line 37, in get_shaders_list
    current = cls._current()
              ^^^^^^^^^^^^^^
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/cli/ls.py", line 51, in _current
    shader = super().current()
             ^^^^^^^^^^^^^^^^^
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/shader/core.py", line 106, in current
    path_ = hyprctl.get_screen_shader()
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade/shader/hyprctl.py", line 72, in get_screen_shader
    raise RuntimeError(message) from e
RuntimeError: hyprctl returned invalid JSON.
This is likely a bug in Hyprland; go bug Vaxry about it (nicely :)).

�[31mstdout�[0m:
    Couldn't connect to /tmp/hypr/4cdddcfe466cb21db81af0ac39e51cc15f574da9_1716037622_2056029974/.socket.sock. (3)

�[31mstderr�[0m:
    <empty>

from hyprshade.

markaacosta avatar markaacosta commented on June 11, 2024

I imagine the PyPi version will work fine - I will try that soon if I can and put the output here

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024

There are some weird things going on here:

  • blue-light-filter isn't being found in $out/share/hyprshade/shaders (see the package definition), this could indicate an issue with installation (EDIT: This is wrong, since I assumed hyprshade -v on blue-light-filter was being run and not hyprshade -v on blue-light-filter.glsl.mustache)
  • hyprctl is failing to connect to the running Hyprland instance when running hyprshade ls, but not hyprshade on
    • hyprctl should really be returning a non-zero exit code and printing errors to stderr so that it can be programmatically determined that there's an error and the output is not just malformed JSON, that's why Hyprshade is conflating the two in its error message

I assume when you're running hyprshade -v on ./blue-light-filter.glsl.mustache that you're using this file? If so, it's likely not working because support for shader templates (.glsl.mustache files) has not been in any release yet. Try this instead:

/*
 * Blue Light Filter
 *
 * Use warmer colors to make the display easier on your eyes.
 *
 * Source: https://github.com/hyprwm/Hyprland/issues/1140#issuecomment-1335128437
 */

precision highp float;
varying vec2 v_texcoord;
uniform sampler2D tex;

/**
 * Color temperature in Kelvin.
 *
 * @min 1000.0
 * @max 40000.0
 */
const float Temperature = 2600.0;

/**
 * Strength of filter.
 *
 * @min 0.0
 * @max 1.0
 */
const float Strength = 1.0;

#define WithQuickAndDirtyLuminancePreservation
const float LuminancePreservationFactor = 1.0;

// function from https://www.shadertoy.com/view/4sc3D7
// valid from 1000 to 40000 K (and additionally 0 for pure full white)
vec3 colorTemperatureToRGB(const in float temperature) {
    // values from: http://blenderartists.org/forum/showthread.php?270332-OSL-Goodness&p=2268693&viewfull=1#post2268693
    mat3 m = (temperature <= 6500.0) ? mat3(vec3(0.0, -2902.1955373783176, -8257.7997278925690),
                                            vec3(0.0, 1669.5803561666639, 2575.2827530017594),
                                            vec3(1.0, 1.3302673723350029, 1.8993753891711275))
                                     : mat3(vec3(1745.0425298314172, 1216.6168361476490, -8257.7997278925690),
                                            vec3(-2666.3474220535695, -2173.1012343082230, 2575.2827530017594),
                                            vec3(0.55995389139931482, 0.70381203140554553, 1.8993753891711275));
    return mix(clamp(vec3(m[0] / (vec3(clamp(temperature, 1000.0, 40000.0)) + m[1]) + m[2]), vec3(0.0), vec3(1.0)),
               vec3(1.0), smoothstep(1000.0, 0.0, temperature));
}

void main() {
    vec4 pixColor = texture2D(tex, v_texcoord);

    // RGB
    vec3 color = vec3(pixColor[0], pixColor[1], pixColor[2]);

#ifdef WithQuickAndDirtyLuminancePreservation
    color *= mix(1.0, dot(color, vec3(0.2126, 0.7152, 0.0722)) / max(dot(color, vec3(0.2126, 0.7152, 0.0722)), 1e-5),
                 LuminancePreservationFactor);
#endif

    color = mix(color, color * colorTemperatureToRGB(Temperature), Strength);

    vec4 outCol = vec4(color, pixColor[3]);

    gl_FragColor = outCol;
}

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024

Hyprshade 3.2.1 looks for shaders in the following directories: $HYPRSHADE_SHADERS_DIR, ~/.config/hyprland/shaders, ~/.config/hyprshade/shaders, <data-dir>/share/hyprshade/shaders (<data-dir> is the return value of sysconfig.get_path("data"), and is usually /usr/local or /usr on linux systems). The code which defines these directories is here.

<data-dir>/share/hyprshade/shaders seems not to exist on your system, and judging from the Nix package definition it seems like this is expected, since a wrapper for hyprshade is created which sets $HYPRSHADE_SHADERS_DIR, presumably as a workaround.

But while this directory exists, it seems not to contain blue-light-filter.glsl for some reason. (EDIT: This is wrong, since I assumed hyprshade -v on blue-light-filter was being run and not hyprshade -v on blue-light-filter.glsl.mustache.)

from hyprshade.

markaacosta avatar markaacosta commented on June 11, 2024

image

Here's an example of attempting to enable it. Whether I let it use an implicit path or force an explicit one, as long as I pass a non-mustache filter and a valid filter name, it seems it does try to apply it, and there's no error output I can see either. This is true both for filters in the /nix/store/* path, and the ~/.config/hyprland/shaders. Other paths you mentioned too I think.

So even when the path is valid, though it says it's turning it on, it's just not applying it for some reason. Maybe someone else on NixOS unstable will chime in if they're experiencing the same thing. If there's other helpful info I can provide you, let me know. For now, that's probably the extent of my helpful knowledge.

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024

Ah, I see now that I was making an assumption which was incorrect. I've updated my previous comments with that in mind.

@markaacosta Could you run hyprshade on blue-light-filter && hyprctl -j getoption decoration:screen_shader and paste the output here? That lets me know whether decoration:screen_shader is being set. If it's something like /nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/share/hyprshade/shaders/blue-light-filter.glsl, then there's probably some issue with your version of Hyprland that's not applying the screen shader.

As a side note, it's strange that the error Couldn't connect to /tmp/hypr/.../.socket.sock happens with hyprshade ls but not with hyprshade on, since they're both running hyprctl under the hood.

from hyprshade.

markaacosta avatar markaacosta commented on June 11, 2024

it's strange that the error Couldn't connect to /tmp/hypr/.../.socket.sock happens with hyprshade ls but not with hyprshade on, since they're both running hyprctl under the hood

very strange, yeah


here's the new output:

hyprshade on blue-light-filter && hyprctl -j getoption decoration:screen_shader:

{"option": "decoration:screen_shader", "str": "[[EMPTY]]", "set": false }

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024

Hmm, so hyprshade on blue-light-filter isn't setting decoration:screen_shader then.

Try hyprctl keyword decoration:screen_shader <path-to-shader> and then hyprctl -j getoption decoration:screen_shader (replace <path-to-shader> with the absolute path to blue-light-filter.glsl)?

from hyprshade.

markaacosta avatar markaacosta commented on June 11, 2024

hyprctl keyword decoration:screen_shader /nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/share/hyprshade/shaders/blue-light-filter.glsl

running this applied the filter with no issues

hyprctl -j getoption decoration:screen_shader

{"option": "decoration:screen_shader", "str": "/nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/share/hyprshade/shaders/blue-light-filter.glsl", "set": true }

and now the hyprctl JSON seems fine too

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024

Either one of two things is happening here:

  1. hyprshade on blue-light-filter does not run hyprctl keyword decoration:screen_shader /nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/share/hyprshade/shaders/blue-light-filter.glsl
  2. hyprshade on blue-light-filter does run the above, but runs the command in a context where hyprctl fails silently

I doubt 1. is the case, since we can see from the debug output above that Hyprshade is correctly resolving the path to blue-light-filter.glsl and I have no reason to believe that the subprocess.run() call is malformed or that the incorrect argument is being passed to hyprctl.set_screen_shader(). However, I want to completely rule out this possibility.

Could you copy the following to hyprctl.py.patch:

--- shader/hyprctl.py	2024-05-18 15:06:54
+++ shader/hyprctl.py.new	2024-05-18 15:07:47
@@ -32,12 +32,13 @@
 
 def set_screen_shader(shader_path: str) -> None:
     try:
-        subprocess.run(
+        result = subprocess.run(
             ["hyprctl", "keyword", "decoration:screen_shader", shader_path],
             capture_output=True,
             check=True,
             encoding="utf-8",
         )
+        print(result.args)
     except subprocess.CalledProcessError as e:
         raise HyprctlError(e) from e
 

...then run this (might have to run as root with sudo)

patch -d <hyprshade-root> -i hyprctl.py.patch

(Replace <hyprshade-root> with /nix/store/80fjhzmrkpi4zx9x2c8lgf0fxwk23ccp-python3.11-hyprshade-3.2.1/lib/python3.11/site-packages/hyprshade, which should be where the source code for Hyprshade is located on your system.)

(Also, if patch isn't installed on your system, you can install GNU Patch or manually apply the patch yourself if you prefer.)

Afterwards, run hyprshade -v on blue-light-filter and let me know the output.

from hyprshade.

markaacosta avatar markaacosta commented on June 11, 2024

Since NixOS is declarative / read-only, I can't apply the patch directly. I'll see if I can manage to apply it using nix tooling then check back.

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024

It's ok, I don't think it's necessary for reasons I'll explain soon.

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024

I have the same issue on NixOS with Hyprland git (commit c21a5a934061c248ff1cdd459a74a05b621fb427), however, on Hyprland v0.39.1 hyprshade (3.2.1) works fine.

Since the error seems not to occur for @willswats in Hyprland v0.39.1, I wonder if the same would also apply for @markaacosta. @markaacosta Would you mind confirming if this is true?

from hyprshade.

markaacosta avatar markaacosta commented on June 11, 2024

I have the same issue on NixOS with Hyprland git (commit c21a5a934061c248ff1cdd459a74a05b621fb427), however, on Hyprland v0.39.1 hyprshade (3.2.1) works fine.

Since the error seems not to occur for @willswats in Hyprland v0.39.1, I wonder if the same would also apply for @markaacosta. @markaacosta Would you mind confirming if this is true?

I'm building 0.39 right now, I'll let you know

from hyprshade.

markaacosta avatar markaacosta commented on June 11, 2024

on 0.39 hyprland everything works fine for me too

from hyprshade.

willswats avatar willswats commented on June 11, 2024

I think I figured out whats wrong, the hyprshade in nixpkgs is using Hyprland v0.39.1 as that's currently the latest version, and it hasn't been updated probably because of this issue. To fix this you can override the Hyprland package that hyprshade uses like so (this is if you are using flakes):

(pkgs.hyprshade.override {
  hyprland = inputs.hyprland.packages.${pkgs.system}.hyprland;
})

I don't know if this is the typical behavior for when there is a difference between the Hyprland version that hyprshade uses, or if this only occurred due to there being a lot of under-the-hood changes in the Hyprland v0.40.0 release.

from hyprshade.

willswats avatar willswats commented on June 11, 2024

Perhaps it's due to this breaking change in Hyprland v0.40.0:

  • The hyprland logs, sockets, etc. have moved from /tmp/hypr to $XDG_RUNTIME_DIR/hypr.

from hyprshade.

loqusion avatar loqusion commented on June 11, 2024

I think I figured out whats wrong, the hyprshade in nixpkgs is using Hyprland v0.39.1 as that's currently the latest version, and it hasn't been updated probably because of this issue. To fix this you can override the Hyprland package that hyprshade uses like so (this is if you are using flakes):

(pkgs.hyprshade.override {

  hyprland = inputs.hyprland.packages.${pkgs.system}.hyprland;

})

I don't know if this is the typical behavior for when there is a difference between the Hyprland version that hyprshade uses, or if this only occurred due to there being a lot of under-the-hood changes in the Hyprland v0.40.0 release.

I didn't even think of the possibility that Hyprshade is running the wrong hyprctl executable! Bravo, William. Let's hope this fix also works for @markaacosta.

from hyprshade.

markaacosta avatar markaacosta commented on June 11, 2024
(pkgs.hyprshade.override {
  hyprland = inputs.hyprland.packages.${pkgs.system}.hyprland;
})

I'm on flakes, yeah. Did you add this directly to the inputs block of flake.nix? Or add it somewhere else?

from hyprshade.

Related Issues (20)

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.