-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathnotebooks.nix
320 lines (276 loc) · 7.69 KB
/
notebooks.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
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
final: prev:
let
inherit (prev) buildPythonPackage fetchPypi;
inherit (prev) poetry-core pytestCheckHook;
inherit (prev.lib) licenses maintainers;
inherit (prev.pkgs) fetchFromGitHub texlive;
in
rec {
dataframe-image =
let
tex = texlive.combine {
inherit (texlive) scheme-small latex-bin;
};
in
buildPythonPackage rec {
pname = "dataframe-image";
version = "0.1.11";
format = "setuptools";
src = fetchFromGitHub {
owner = "dexplo";
repo = "dataframe_image";
rev = "refs/tags/v${version}";
hash = "sha256-XxoUooMtpprBfVURvtAMwducVrd2yQxkpbkp9ziMBag=";
};
postPatch = ''
substituteInPlace ./setup.py \
--replace "use_scm_version=True," 'version="${version}",' \
--replace 'setup_requires=["setuptools_scm"],' ""
'';
propagatedBuildInputs = with prev; [
aiohttp
beautifulsoup4
cssutils
html2image
lxml
matplotlib
mistune
nbconvert
packaging
pandas
pillow
requests
tex
];
nativeCheckInputs = [
pytestCheckHook
tex
];
doCheck = false;
pythonImportsCheck = [ "dataframe_image" ];
meta = {
description = "Embed pandas DataFrames as images in pdf and markdown files when converting from Jupyter Notebooks";
homepage = "https://github.com/dexplo/dataframe_image";
license = licenses.mit;
maintainers = with maintainers; [ jpetrucciani ];
};
};
html2image = buildPythonPackage rec {
pname = "html2image";
version = "2.0.3";
pyproject = true;
src = fetchPypi {
inherit pname version;
hash = "sha256-/WxrhnwbHrzasls4R/HdInHhHBzduLWxGwmyXgmx8dA=";
};
nativeBuildInputs = [
poetry-core
];
postPatch = ''
sed -i -E 's#(poetry)>=0.12#\1-core#g' ./pyproject.toml
substituteInPlace ./pyproject.toml --replace "poetry.masonry" "poetry.core.masonry"
'';
pythonImportsCheck = [ "html2image" ];
meta = {
description = "Generate images from URLs and from HTML+CSS strings or files";
homepage = "https://github.com/vgalin/html2image";
license = licenses.mit;
maintainers = with maintainers; [ jpetrucciani ];
};
};
ipyaggrid = buildPythonPackage rec {
pname = "ipyaggrid";
version = "0.4.0";
pyproject = true;
src = fetchPypi {
inherit pname version;
hash = "sha256-unwV+xjQ8X8pjb/IK1DRJ4Ks9SzsDT9+aWqTgc8+XQM=";
};
postPatch = ''
sed -i -E 's#(requires =).*#\1["jupyterlab"]#g' ./pyproject.toml
'';
nativeBuildInputs = with prev; [
jupyter-packaging
jupyterlab
setuptools
wheel
];
propagatedBuildInputs = with prev; [
ipywidgets
pandas
simplejson
];
pythonImportsCheck = [ "ipyaggrid" ];
meta = {
description = "Jupyter widget - ag-grid in the notebook";
homepage = "https://github.com/widgetti/ipyaggrid";
license = licenses.mit;
maintainers = with maintainers; [ jpetrucciani ];
};
};
jupyterlab-code-formatter = buildPythonPackage rec {
pname = "jupyterlab-code-formatter";
version = "1.6.1";
pyproject = true;
src = fetchPypi {
pname = "jupyterlab_code_formatter";
inherit version;
hash = "sha256-3fCEODKSzs7dyq4EP0xiuT0nqFhQV4ooD4/e2aG5OjI=";
};
postPatch = ''
sed -i -E 's#(requires =).*#\1["jupyterlab"]#g' ./pyproject.toml
'';
nativeBuildInputs = with prev; [
jupyter-packaging
jupyterlab
setuptools
wheel
];
pythonImportsCheck = [ "jupyterlab_code_formatter" ];
meta = {
description = "Code formatter for JupyterLab";
homepage = "https://github.com/ryantam626/jupyterlab_code_formatter";
license = licenses.mit;
maintainers = with maintainers; [ jpetrucciani ];
};
};
jupyterlab-execute-time =
let
pname = "jupyterlab-execute-time";
version = "2.3.1";
format = "wheel";
src = fetchPypi {
inherit version;
pname = "jupyterlab_execute_time";
format = "wheel";
python = "py3";
dist = "py3";
platform = "any";
hash = "sha256-l10U+f6VyBaJrXTj84XaDBqDqdHm4J6dwC9ms60Fml4=";
};
in
buildPythonPackage {
inherit pname src version format;
nativeBuildInputs = with prev; [
jupyter-packaging
jupyterlab
];
propagatedBuildInputs = with prev; [
jupyter-server
];
pythonImportsCheck = [ "jupyterlab_execute_time" ];
meta = {
description = "Display cell timings in Jupyter Lab";
homepage = "https://github.com/deshaw/jupyterlab-execute-time";
license = licenses.bsd3;
maintainers = with maintainers; [ jpetrucciani ];
};
};
jupyterlab-templates =
let
pname = "jupyterlab-templates";
version = "0.4.1";
format = "wheel";
src = fetchPypi {
inherit version;
pname = "jupyterlab_templates";
format = "wheel";
python = "py3";
dist = "py3";
platform = "any";
hash = "sha256-BUURbe7BQCHH0hmygppbsL7+mqju9XV8JSSxntrVd7U=";
};
in
buildPythonPackage {
inherit pname src version format;
nativeBuildInputs = with prev; [
jupyter-packaging
jupyterlab
];
propagatedBuildInputs = with prev; [
jupyter-server
];
pythonImportsCheck = [ "jupyterlab_templates" ];
meta = {
description = "Support for jupyter notebook templates in jupyterlab";
homepage = "https://github.com/finos/jupyterlab_templates";
license = licenses.asl20;
maintainers = with maintainers; [ jpetrucciani ];
};
};
voila =
let
pname = "voila";
version = "0.5.4";
format = "wheel";
src = fetchPypi {
inherit pname version;
format = "wheel";
python = "py3";
dist = "py3";
platform = "any";
hash = "sha256-98rEqUgh3kDSg0Rz5tO/0gAJJ0B8U4VIaWZDSi4fbZg=";
};
in
buildPythonPackage {
inherit pname src version format;
nativeBuildInputs = with prev; [
hatchling
hatch-jupyter-builder
jupyter-core
jupyterlab
];
propagatedBuildInputs = with prev; [
jupyter-client
jupyter-core
jupyter-server
jupyterlab_server
nbclient
nbconvert
traitlets
websockets
];
passthru.optional-dependencies = with prev; {
dev = [
black
hatch
jupyter-releaser
pre-commit
];
test = [
ipykernel
ipywidgets
matplotlib
mock
numpy
pandas
papermill
pytest
pytest-tornasync
];
};
pythonImportsCheck = [ "voila" ];
meta = {
description = "Turn Jupyter notebooks into standalone web applications";
homepage = "https://github.com/voila-dashboards/voila";
license = licenses.bsd3;
maintainers = with maintainers; [ jpetrucciani ];
};
};
xalglib = buildPythonPackage rec {
pname = "xalglib";
version = "3.16.0";
format = "setuptools";
src = fetchPypi {
inherit pname version;
hash = "sha256-n1hqnFwqm6mf75grehqOBbp589GtPXkZOeCVhrME4gM=";
};
pythonImportsCheck = [ "xalglib" ];
meta = {
description = "ALGLIB is a cross-platform numerical analysis and data processing library";
homepage = "https://www.alglib.net/";
license = with licenses; [ ];
maintainers = with maintainers; [ jpetrucciani ];
};
};
}