Something went wrong. Try again.
What happens if I push all of nixpkgs
Something went wrong. Try again.
2.0 kB · 89 lines
Nix
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990{ lib, buildPythonPackage, fetchFromGitHub,
# build-system setuptools,
# dependencies chardet, regex, packaging,
# optionals faust-cchardet, pandas, tabview, # TODO: , wilderness
# tests python, pytestCheckHook,}:
buildPythonPackage rec { pname = "clevercsv"; version = "0.8.3"; pyproject = true;
src = fetchFromGitHub { owner = "alan-turing-institute"; repo = "CleverCSV"; tag = "v${version}"; hash = "sha256-T4eYTr3+MUr1fPWE490v1m8THdZrBUP4wODftjpvnLQ="; };
build-system = [ setuptools ];
dependencies = [ chardet regex packaging ];
optional-dependencies = { full = [ faust-cchardet pandas tabview # TODO: wilderness ]; };
nativeCheckInputs = [ pytestCheckHook ] ++ optional-dependencies.full;
pythonImportsCheck = [ "clevercsv" "clevercsv.cparser" ];
preCheck = '' # by linking the installed version the tests also have access to compiled native libraries rm -r clevercsv ln -s $out/${python.sitePackages}/clevercsv/ clevercsv '';
# their ci only runs unit tests, there are also integration and fuzzing tests enabledTestPaths = [ "./tests/test_unit" ];
disabledTestPaths = [ # ModuleNotFoundError: No module named 'wilderness' "tests/test_unit/test_console.py" ];
meta = with lib; { description = "CleverCSV is a Python package for handling messy CSV files"; mainProgram = "clevercsv"; longDescription = '' CleverCSV is a Python package for handling messy CSV files. It provides a drop-in replacement for the builtin CSV module with improved dialect detection, and comes with a handy command line application for working with CSV files. ''; homepage = "https://github.com/alan-turing-institute/CleverCSV"; changelog = "https://github.com/alan-turing-institute/CleverCSV/blob/${src.rev}/CHANGELOG.md"; license = licenses.mit; maintainers = with maintainers; [ hexa ]; };}