diff --git a/pkgs/development/python-modules/asyncpraw/default.nix b/pkgs/development/python-modules/asyncpraw/default.nix index 0126f99cc91e..299b4a384752 100644 --- a/pkgs/development/python-modules/asyncpraw/default.nix +++ b/pkgs/development/python-modules/asyncpraw/default.nix @@ -2,57 +2,52 @@ lib, aiofiles, aiohttp, - aiosqlite, asyncprawcore, buildPythonPackage, + coverage, + defusedxml, fetchFromGitHub, - flit-core, - mock, + hatchling, pytestCheckHook, - pytest-asyncio_0, + pytest-asyncio, pytest-vcr, - pythonOlder, - requests-toolbelt, update-checker, vcrpy, }: buildPythonPackage rec { pname = "asyncpraw"; - version = "7.8.1"; + version = "7.8.1-unstable-2025-10-08"; pyproject = true; - disabled = pythonOlder "3.8"; - src = fetchFromGitHub { owner = "praw-dev"; repo = "asyncpraw"; - tag = "v${version}"; - hash = "sha256-glWAQoUjMFbjU3C4+MGuRGSGJS9mun15+6udMPCf9nU="; + rev = "9221cbef5d94fce9ecc92376cbab084f0082502d"; + hash = "sha256-/7x7XYw1JDVaoc2+wKWW3iUkyfI6MVtBNP9G1AEUp4Y="; }; - pythonRelaxDeps = [ "aiosqlite" ]; + pythonRelaxDeps = [ + "coverage" + "defusedxml" + ]; - # 'aiosqlite' is also checked when building the wheel - pypaBuildFlags = [ "--skip-dependency-check" ]; - - build-system = [ flit-core ]; + build-system = [ hatchling ]; dependencies = [ aiofiles aiohttp - aiosqlite asyncprawcore - mock + coverage + defusedxml update-checker ]; nativeCheckInputs = [ pytestCheckHook - pytest-asyncio_0 + pytest-asyncio pytest-vcr vcrpy - requests-toolbelt ]; disabledTestPaths = [ @@ -70,7 +65,7 @@ buildPythonPackage rec { meta = { description = "Asynchronous Python Reddit API Wrapper"; homepage = "https://asyncpraw.readthedocs.io/"; - changelog = "https://github.com/praw-dev/asyncpraw/blob/v${version}/CHANGES.rst"; + changelog = "https://github.com/praw-dev/asyncpraw/blob/${src.rev}/CHANGES.rst"; license = lib.licenses.bsd2; maintainers = [ lib.maintainers.amadejkastelic ]; }; diff --git a/pkgs/development/python-modules/asyncprawcore/default.nix b/pkgs/development/python-modules/asyncprawcore/default.nix index bc8c34f86a01..b6a34a6a2b9a 100644 --- a/pkgs/development/python-modules/asyncprawcore/default.nix +++ b/pkgs/development/python-modules/asyncprawcore/default.nix @@ -4,43 +4,35 @@ buildPythonPackage, fetchFromGitHub, flit-core, - mock, pytestCheckHook, - pytest-asyncio_0, + pytest-asyncio, pytest-vcr, - requests, - requests-toolbelt, - testfixtures, vcrpy, yarl, }: buildPythonPackage rec { pname = "asyncprawcore"; - version = "2.4.0"; + version = "3.0.2"; pyproject = true; src = fetchFromGitHub { owner = "praw-dev"; repo = "asyncprawcore"; tag = "v${version}"; - hash = "sha256-FDQdtnNjsbiEp9BUYdQFMC/hkyJDhCh2WHhQWSQwrFY="; + hash = "sha256-0FOMY/0LXGcHwDe4t+NMAovMhX83/mMv8sWvIf5gxok="; }; build-system = [ flit-core ]; dependencies = [ - requests aiohttp yarl ]; nativeCheckInputs = [ - testfixtures - mock - requests-toolbelt pytestCheckHook - pytest-asyncio_0 + pytest-asyncio pytest-vcr vcrpy ]; @@ -51,6 +43,11 @@ buildPythonPackage rec { "tests/integration/test_sessions.py" ]; + disabledTests = [ + # Test requires network access + "test_initialize" + ]; + pythonImportsCheck = [ "asyncprawcore" ]; meta = {