From de4de850ee4d3dbc4c201dc74c718f50bbb6fb58 Mon Sep 17 00:00:00 2001 From: Naga Praneeth Date: Sat, 18 Oct 2025 20:24:31 +0530 Subject: [PATCH] conkeyscan: replace random-user-agent with fake-useragent Applies patch from upstream PR https://github.com/CompassSecurity/conkeyscan/pull/3 to replace the abandoned random-user-agent package with fake-useragent. Part of #410837. --- pkgs/by-name/co/conkeyscan/package.nix | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/pkgs/by-name/co/conkeyscan/package.nix b/pkgs/by-name/co/conkeyscan/package.nix index 84db874f792b..9260aa7c73a9 100644 --- a/pkgs/by-name/co/conkeyscan/package.nix +++ b/pkgs/by-name/co/conkeyscan/package.nix @@ -2,6 +2,7 @@ lib, python3, fetchFromGitHub, + fetchpatch, }: let @@ -34,6 +35,15 @@ python.pkgs.buildPythonApplication rec { hash = "sha256-xYCms+Su7FmaG7KVHZpzfD/wx9Gepz11t8dEK/YDfvI="; }; + patches = [ + # https://github.com/CompassSecurity/conkeyscan/pull/3 + (fetchpatch { + name = "replace-random-user-agent-with-fake-useragent.patch"; + url = "https://github.com/nagapraneethk/conkeyscan/commit/f6cf61cc42fcc07930a06891b6c4a2653bfbf47f.patch"; + hash = "sha256-zfHU/KsgzQvn/kNsWZy1hGZaBHw/he1zDTUHHV/BHFc="; + }) + ]; + postPatch = '' substituteInPlace setup.py \ --replace-fail "{{VERSION_PLACEHOLDER}}" "${version}" @@ -47,7 +57,7 @@ python.pkgs.buildPythonApplication rec { clize loguru pysocks - random-user-agent + fake-useragent readchar requests-ratelimiter ];