mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-01 17:53:14 +00:00
Merge pull request #127024 from pacien/visidata-deps
visidata: add missing deps, enable tests
This commit is contained in:
commit
c285ab05df
@ -1,17 +1,26 @@
|
|||||||
{ buildPythonApplication
|
{ stdenv
|
||||||
, lib
|
, lib
|
||||||
|
, buildPythonApplication
|
||||||
, fetchFromGitHub
|
, fetchFromGitHub
|
||||||
, dateutil
|
, dateutil
|
||||||
, pyyaml
|
, pandas
|
||||||
|
, requests
|
||||||
|
, lxml
|
||||||
, openpyxl
|
, openpyxl
|
||||||
, xlrd
|
, xlrd
|
||||||
, h5py
|
, h5py
|
||||||
, fonttools
|
, psycopg2
|
||||||
, lxml
|
|
||||||
, pandas
|
|
||||||
, pyshp
|
, pyshp
|
||||||
|
, fonttools
|
||||||
|
, pyyaml
|
||||||
|
, pdfminer
|
||||||
|
, vobject
|
||||||
|
, tabulate
|
||||||
|
, wcwidth
|
||||||
|
, zstandard
|
||||||
, setuptools
|
, setuptools
|
||||||
, withPcap ? true, dpkt ? null, dnslib ? null
|
, git
|
||||||
|
, withPcap ? true, dpkt, dnslib
|
||||||
}:
|
}:
|
||||||
buildPythonApplication rec {
|
buildPythonApplication rec {
|
||||||
pname = "visidata";
|
pname = "visidata";
|
||||||
@ -25,19 +34,62 @@ buildPythonApplication rec {
|
|||||||
};
|
};
|
||||||
|
|
||||||
propagatedBuildInputs = [
|
propagatedBuildInputs = [
|
||||||
|
# from visidata/requirements.txt
|
||||||
|
# packages not (yet) present in nixpkgs are commented
|
||||||
dateutil
|
dateutil
|
||||||
pyyaml
|
pandas
|
||||||
|
requests
|
||||||
|
lxml
|
||||||
openpyxl
|
openpyxl
|
||||||
xlrd
|
xlrd
|
||||||
h5py
|
h5py
|
||||||
fonttools
|
psycopg2
|
||||||
lxml
|
|
||||||
pandas
|
|
||||||
pyshp
|
pyshp
|
||||||
|
#mapbox-vector-tile
|
||||||
|
#pypng
|
||||||
|
fonttools
|
||||||
|
#sas7bdat
|
||||||
|
#xport
|
||||||
|
#savReaderWriter
|
||||||
|
pyyaml
|
||||||
|
#namestand
|
||||||
|
#datapackage
|
||||||
|
pdfminer
|
||||||
|
#tabula
|
||||||
|
vobject
|
||||||
|
tabulate
|
||||||
|
wcwidth
|
||||||
|
zstandard
|
||||||
setuptools
|
setuptools
|
||||||
] ++ lib.optionals withPcap [ dpkt dnslib ];
|
] ++ lib.optionals withPcap [ dpkt dnslib ];
|
||||||
|
|
||||||
doCheck = false;
|
checkInputs = [
|
||||||
|
git
|
||||||
|
];
|
||||||
|
|
||||||
|
# check phase uses the output bin, which is not possible when cross-compiling
|
||||||
|
doCheck = stdenv.buildPlatform == stdenv.hostPlatform;
|
||||||
|
|
||||||
|
checkPhase = ''
|
||||||
|
# disable some tests which require access to the network
|
||||||
|
rm tests/load-http.vd # http
|
||||||
|
rm tests/graph-cursor-nosave.vd # http
|
||||||
|
rm tests/messenger-nosave.vd # dns
|
||||||
|
|
||||||
|
# disable some tests which expect Python == 3.6 (not our current version)
|
||||||
|
# see https://github.com/saulpw/visidata/issues/1014
|
||||||
|
rm tests/describe.vd
|
||||||
|
rm tests/describe-error.vd
|
||||||
|
rm tests/edit-type.vd
|
||||||
|
|
||||||
|
# tests use git to compare outputs to references
|
||||||
|
git init -b "test-reference"
|
||||||
|
git config user.name "nobody"; git config user.email "no@where"
|
||||||
|
git add .; git commit -m "test reference"
|
||||||
|
|
||||||
|
substituteInPlace dev/test.sh --replace "bin/vd" "$out/bin/vd"
|
||||||
|
bash dev/test.sh
|
||||||
|
'';
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
inherit version;
|
inherit version;
|
||||||
|
Loading…
Reference in New Issue
Block a user