at 23.11-beta 61 lines 1.5 kB view raw
1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, pythonOlder 5, pytestCheckHook 6, pyqt5 7, pyqt3d 8, pyqtchart 9, pyqtdatavisualization 10, pyqtwebengine 11}: 12 13buildPythonPackage rec { 14 pname = "PyQt5-stubs"; 15 version = "5.15.6.0"; 16 format = "setuptools"; 17 disabled = pythonOlder "3.7"; 18 19 src = fetchFromGitHub { 20 owner = "python-qt-tools"; 21 repo = "PyQt5-stubs"; 22 rev = version; 23 hash = "sha256-qWnvlHnFRy8wbZJ28C0pYqAxod623Epe5z5FZufheDc="; 24 }; 25 postPatch = '' 26 # pulls in a dependency to mypy, but we don't want to run linters 27 rm tests/test_stubs.py 28 '' + lib.optionalString (!pyqt5.connectivityEnabled) '' 29 rm tests/qflags/test_QtBluetooth_* 30 rm tests/qflags/test_QtNfc_* 31 '' + lib.optionalString (!pyqt5.locationEnabled) '' 32 rm tests/qflags/test_QtLocation_* 33 rm tests/qflags/test_QtPositioning_* 34 '' + lib.optionalString (!pyqt5.multimediaEnabled) '' 35 rm tests/qflags/test_QtMultimedia_* 36 '' + lib.optionalString (!pyqt5.serialPortEnabled) '' 37 rm tests/qflags/test_QtSerialPort_* 38 '' + lib.optionalString (!pyqt5.toolsEnabled) '' 39 rm tests/qflags/test_QtDesigner_* 40 ''; 41 42 pythonImportsCheck = [ 43 "PyQt5-stubs" 44 ]; 45 46 nativeCheckInputs = [ 47 pytestCheckHook 48 pyqt5 49 pyqt3d 50 pyqtchart 51 pyqtdatavisualization 52 pyqtwebengine 53 ]; 54 55 meta = with lib; { 56 description = "Stubs for PyQt5 "; 57 homepage = "https://github.com/python-qt-tools/PyQt5-stubs"; 58 license = licenses.gpl3; 59 maintainers = with maintainers; [ _999eagle ]; 60 }; 61}