Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.03 71 lines 2.2 kB view raw
1{ stdenv, buildPythonPackage, fetchPypi, makeDesktopItem, jedi, pycodestyle, 2 psutil, pyflakes, rope, numpy, scipy, matplotlib, pylint, keyring, numpydoc, 3 qtconsole, qtawesome, nbconvert, mccabe, pyopengl, cloudpickle, pygments, 4 spyder-kernels, qtpy, pyzmq, chardet 5, pyqtwebengine 6}: 7 8buildPythonPackage rec { 9 pname = "spyder"; 10 version = "4.0.0"; 11 12 src = fetchPypi { 13 inherit pname version; 14 sha256 = "f2bfece9743188e3d1da68f02271a7c6eb7f0a3b692c3df4952458ab96b037a8"; 15 }; 16 17 nativeBuildInputs = [ pyqtwebengine.wrapQtAppsHook ]; 18 19 propagatedBuildInputs = [ 20 jedi pycodestyle psutil pyflakes rope numpy scipy matplotlib pylint keyring 21 numpydoc qtconsole qtawesome nbconvert mccabe pyopengl cloudpickle spyder-kernels 22 pygments qtpy pyzmq chardet pyqtwebengine 23 ]; 24 25 # There is no test for spyder 26 doCheck = false; 27 28 desktopItem = makeDesktopItem { 29 name = "Spyder"; 30 exec = "spyder"; 31 icon = "spyder"; 32 comment = "Scientific Python Development Environment"; 33 desktopName = "Spyder"; 34 genericName = "Python IDE"; 35 categories = "Application;Development;Editor;IDE;"; 36 }; 37 38 postPatch = '' 39 # remove dependency on pyqtwebengine 40 # this is still part of the pyqt 5.11 version we have in nixpkgs 41 sed -i /pyqtwebengine/d setup.py 42 substituteInPlace setup.py --replace "pyqt5<5.13" "pyqt5" 43 ''; 44 45 # Create desktop item 46 postInstall = '' 47 mkdir -p $out/share/icons 48 cp spyder/images/spyder.svg $out/share/icons 49 cp -r $desktopItem/share/applications/ $out/share 50 ''; 51 52 dontWrapQtApps = true; 53 54 preFixup = '' 55 makeWrapperArgs+=("''${qtWrapperArgs[@]}") 56 ''; 57 58 meta = with stdenv.lib; { 59 description = "Scientific python development environment"; 60 longDescription = '' 61 Spyder (previously known as Pydee) is a powerful interactive development 62 environment for the Python language with advanced editing, interactive 63 testing, debugging and introspection features. 64 ''; 65 homepage = "https://github.com/spyder-ide/spyder/"; 66 license = licenses.mit; 67 platforms = platforms.linux; 68 maintainers = with maintainers; [ gebner ]; 69 broken = true; 70 }; 71}