1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, nose
5, pythonOlder
6}:
7
8buildPythonPackage rec {
9 pname = "ofxtools";
10 version = "0.9.5";
11
12 disabled = pythonOlder "3.8";
13
14 # PyPI distribution does not include tests
15 src = fetchFromGitHub {
16 owner = "csingley";
17 repo = pname;
18 rev = version;
19 hash = "sha256-NsImnD+erhpakQnl1neuHfSKiV6ipNBMPGKMDM0gwWc=";
20 };
21
22 nativeCheckInputs = [ nose ];
23 # override $HOME directory:
24 # error: [Errno 13] Permission denied: '/homeless-shelter'
25 checkPhase = ''
26 HOME=$TMPDIR nosetests tests/*.py
27 '';
28
29 meta = with lib; {
30 homepage = "https://github.com/csingley/ofxtools";
31 description = "Library for working with Open Financial Exchange (OFX) formatted data used by financial institutions";
32 license = licenses.mit;
33 };
34}