diff --git a/pkgs/development/python-modules/python-telegram-bot/default.nix b/pkgs/development/python-modules/python-telegram-bot/default.nix index 30caa0f3d6a..f36f8239568 100644 --- a/pkgs/development/python-modules/python-telegram-bot/default.nix +++ b/pkgs/development/python-modules/python-telegram-bot/default.nix @@ -23,7 +23,11 @@ buildPythonPackage rec { checkInputs = [ pytest ]; propagatedBuildInputs = [ certifi future urllib3 tornado decorator ]; - pipInstallFlags = "--install-option '--with-upstream-urllib3'"; + # --with-upstream-urllib3 is not working properly + postPatch = '' + rm -rf telegram/vendor + ''; + setupPyGlobalFlags = "--with-upstream-urllib3"; # tests not included with release doCheck = false;