python310Packages.telethon: 1.25.0 -> 1.25.1

Fetch source from GitHub, enable tests, migrate build to pyproject and
add setuptools to nativeBuildInputs.
This commit is contained in:
R. Ryantm 2022-09-25 08:13:50 +00:00 committed by Martin Weinelt
parent 6fcaded221
commit c0118dcbbb
No known key found for this signature in database
GPG key ID: 87C1E9888F856759

View file

@ -1,13 +1,26 @@
{ lib, buildPythonPackage, fetchPypi, openssl, rsa, pyaes, pythonOlder }:
{ lib
, buildPythonPackage
, fetchFromGitHub
, openssl
, rsa
, pyaes
, pythonOlder
, setuptools
, pytest-asyncio
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "telethon";
version = "1.25.0";
version = "1.25.1";
format = "pyproject";
disabled = pythonOlder "3.5";
src = fetchPypi {
inherit version;
pname = "Telethon";
sha256 = "sha256-Z22XuSbm0w2+0x1sbmYRzeyfyCdZeFzqVcR3C3RhQpA=";
src = fetchFromGitHub {
owner = "LonamiWebs";
repo = "Telethon";
rev = "refs/tags/v${version}";
hash = "sha256-xmFoCUqYo600RH72KWG/aM7hKGiTYdCBsbPOFipxIzA=";
};
patchPhase = ''
@ -15,15 +28,23 @@ buildPythonPackage rec {
"ctypes.util.find_library('ssl')" "'${lib.getLib openssl}/lib/libssl.so'"
'';
nativeBuildInputs = [
setuptools
];
propagatedBuildInputs = [
rsa
pyaes
];
# No tests available
doCheck = false;
checkInputs = [
pytest-asyncio
pytestCheckHook
];
disabled = pythonOlder "3.5";
pytestFlagsArray = [
"tests/telethon"
];
meta = with lib; {
homepage = "https://github.com/LonamiWebs/Telethon";