-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdefault.nix
163 lines (143 loc) · 4.68 KB
/
default.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
{ pkgs ? import <nixpkgs> {}
, stdenv ? pkgs.stdenv
}:
let
local = rec {
callPackage = pkgs.lib.callPackageWith collection;
collection = rec {
python = pkgs.python38Packages;
mypython = pkgs.python38.withPackages (
pp: let
pyls = pp.python-language-server.override { providers=["pycodestyle"]; };
pyls-mypy = pp.pyls-mypy.override { python-language-server=pyls; };
altair-data-server = pp.buildPythonPackage rec {
name = "altair-data-server";
src = pp.fetchPypi {
version = "0.4.1";
pname = "altair_data_server";
sha256 = "sha256:0azbkakgbjwxvkfsvdcw2vnpjn44ffwrqwsqzhh80rxjiaj0b4mk";
};
buildInputs = with pp; [ altair portpicker tornado jinja2 pytest ];
};
altair-viewer = pp.buildPythonPackage rec {
name = "altair-viewer";
src = pp.fetchPypi {
version = "0.3.0";
pname = "altair_viewer";
sha256 = "sha256:0fa4ab233jbx11jfim35qys9yz769pdhkmfrvliyfnvwdggdnr19";
};
buildInputs = with pp; [ altair altair-data-server portpicker tornado
jinja2 pytest ipython ];
};
altair-saver = pp.buildPythonPackage rec {
name = "altair-saver";
src = pp.fetchPypi {
version = "0.5.0";
pname = "altair_saver";
sha256 = "sha256:15c7p23m8497jpvabg49bd858nsip31lv408n4fs2fwfhvvbr660";
};
# preConfigure = ''
# sed -i 's/"chrome"/"chromium"/g' ./altair_saver/savers/_selenium.py
# '';
propagatedBuildInputs = with pp; [ altair-viewer pkgs.nodejs altair-data-server
altair portpicker tornado jinja2 pytest selenium
pillow pypdf2];
};
bespon = pp.buildPythonPackage rec {
pname = "bespon_py";
version = "0.6.0";
# propagatedBuildInputs = with mypython.pkgs ; [nr-types pyyaml];
# doCheck = false; # local HTTP requests don't work
src = pkgs.fetchFromGitHub {
owner = "gpoore";
repo = pname;
rev = "183d0a49146025969266fc1b4157392d5ffda609";
sha256 = "sha256:0x1ifklhh88fa6i693zgpb63646jxsyhj4j64lrvarckrb31wk23";
};
};
codebraid = pp.buildPythonPackage rec {
pname = "codebraid";
version = "0.5.0";
propagatedBuildInputs = [ bespon ];
src = pkgs.fetchFromGitHub {
owner = "gpoore";
repo = pname;
rev = "21ef9399918e750852e5aa70c443e44052250d78";
sha256 = "sha256:05754y0rbj6qcm2r772r3asln8rp2n958mi04s29my18mrjqwdhn";
};
};
in with pp; [
ipython
hypothesis
pytest
pytest-mypy
pytest_xdist
coverage
codebraid
pyls
pyls-mypy
pyyaml
wheel
multipledispatch
graph-tool
pygobject3
ipdb
scipy
matplotlib
pyqt5
plotly
altair
altair-data-server
altair-viewer
altair-saver
selenium
# (projectq_ pp)
pylatexenc
ipywidgets
pygraphviz
pydot
z3
dataclasses-json
sympy
setuptools_scm
]);
inherit (pkgs) cudatoolkit cudnn magma;
shell = pkgs.mkShell {
name = "shell";
buildInputs = with pkgs; [
mypython
pandoc
poppler
poppler_utils
cairo
feh
python.grip
imagemagick
gnome3.eog
gobject-introspection
gtk3
gdb
(let
mytexlive = pkgs.texlive.override { python3=mypython; };
in
mytexlive.combine {
scheme-medium = mytexlive.scheme-medium;
inherit (mytexlive) fvextra upquote xstring pgfopts currfile
collection-langcyrillic makecell ftnxtra minted catchfile framed
pdflscape environ trimspaces mdframed zref needspace import
beamerposter qcircuit xypic standalone preview amsmath thmtools
tocloft tocbibind varwidth;
}
)
];
shellHook = with pkgs; ''
if test -f ./env.sh ; then
. ./env.sh
export QT_QPA_PLATFORM_PLUGIN_PATH=`echo ${pkgs.qt5.qtbase.bin}/lib/qt-*/plugins/platforms/`
fi
'';
};
};
};
in
local.collection