nixpkgs/pkgs/development/python-modules/spyder/3.nix
Marcus Boyd da760cf7a0 python3Packages.spyder_3: Added spyder_3
cq-editor currently requires spyder v3.x
2020-03-19 07:38:56 +01:00

71 lines
2.1 KiB
Nix

{ stdenv, buildPythonPackage, fetchPypi, makeDesktopItem, jedi, pycodestyle,
psutil, pyflakes, rope, numpy, scipy, matplotlib, pylint, keyring, numpydoc,
qtconsole, qtawesome, nbconvert, mccabe, pyopengl, cloudpickle, pygments,
spyder-kernels_0_5, qtpy, pyzmq, chardet
, pyqtwebengine
}:
buildPythonPackage rec {
pname = "spyder";
version = "3.3.6";
src = fetchPypi {
inherit pname version;
sha256 = "1z7qw1h3rhca12ycv8xrzw6z2gf81v0j6lfq9kpwh472w4vk75v1";
};
nativeBuildInputs = [ pyqtwebengine.wrapQtAppsHook ];
propagatedBuildInputs = [
jedi pycodestyle psutil pyflakes rope numpy scipy matplotlib pylint keyring
numpydoc qtconsole qtawesome nbconvert mccabe pyopengl cloudpickle spyder-kernels_0_5
pygments qtpy pyzmq chardet pyqtwebengine
];
# There is no test for spyder
doCheck = false;
desktopItem = makeDesktopItem {
name = "Spyder";
exec = "spyder";
icon = "spyder";
comment = "Scientific Python Development Environment";
desktopName = "Spyder";
genericName = "Python IDE";
categories = "Application;Development;Editor;IDE;";
};
postPatch = ''
# remove dependency on pyqtwebengine
# this is still part of the pyqt 5.11 version we have in nixpkgs
sed -i /pyqtwebengine/d setup.py
substituteInPlace setup.py --replace "pyqt5<5.13" "pyqt5"
'';
# Create desktop item
postInstall = ''
mkdir -p $out/share/icons
cp spyder/images/spyder.svg $out/share/icons
cp -r $desktopItem/share/applications/ $out/share
'';
dontWrapQtApps = true;
preFixup = ''
makeWrapperArgs+=("''${qtWrapperArgs[@]}")
'';
meta = with stdenv.lib; {
description = "Scientific python development environment";
longDescription = ''
Spyder (previously known as Pydee) is a powerful interactive development
environment for the Python language with advanced editing, interactive
testing, debugging and introspection features.
'';
homepage = "https://github.com/spyder-ide/spyder/";
license = licenses.mit;
platforms = platforms.linux;
maintainers = with maintainers; [ gebner ];
};
}