Obs-studio package overlay gives me the old package version

So I made this obs-studio overlay under nixpkgs.overlays to test out the candidate release of the package and added it to my environment.systemPackages list.

    (self: super: {
      obs-studio-26 = obs-studio.overrideAttrs (oldAttrs: rec {
        pname = "obs-studio";
        version = "26.0.0-rc1";

        src = pkgs.fetchFromGitHub {
          owner = "obsproject";
          repo = "obs-studio";
          rev = version;
          sha256 = "0931df9yv5akid16y6abp0ihl8vc3gwa0dr3hnnn94h8567mwq3s";
        };

        buildInputs = oldAttrs.buildInputs ++ [ pkgs.rnnoise ];
      });
    })

However when I run sudo nixos-rebuild switch the obs --version command reports 25.0.8 which is the old version. It seems to me like the overlay is being ignored, but I don’t understand why. The sha256 has been updated to match version 26.0.0-rc1 so I would at least expect a hash mismatch when it fetches the older version.

Do you refer to obs-studio-26 in your configuration.nix?

Yes, obs-studio-26 is part of my environment.systemPackages list

Please ignore the output of --version, I skimmed the CMakeLists.txt and it seems as if the build file does some magic to get the version from the repo or tag.

Though fetchFromGitHub doesn’t make that available, so it is likely falling back to something else, that I was unable to identify by skimming.

Instead of relying on the output of the --version flag, have you checked if available features correspond to the release candidate?

1 Like

Yes it seems I do have the new features which correspond to the candidate release. So there is just something wrong with the version reporting