Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.03 84 lines 1.5 kB view raw
1{ lib, buildPythonPackage, fetchPypi, isPy27 2, cssselect 3, dateutil 4, feedparser 5, futures 6, gdata 7, gnupg 8, google_api_python_client 9, html2text 10, libyaml 11, lxml 12, mechanize 13, nose 14, pdfminer 15, pillow 16, prettytable 17, pyqt5 18, pyyaml 19, requests 20, simplejson 21, termcolor 22, unidecode 23}: 24 25buildPythonPackage rec { 26 pname = "weboob"; 27 version = "1.5"; 28 29 src = fetchPypi { 30 inherit pname version; 31 sha256 = "1c9z9gid1mbm1cakb2wj6jjkbrmji8y8ac46iqpih9x1h498bhbs"; 32 }; 33 34 postPatch = '' 35 # Disable doctests that require networking: 36 sed -i -n -e '/^ *def \+pagination *(.*: *$/ { 37 p; n; p; /"""\|'\'\'\'''/!b 38 39 :loop 40 n; /^ *\(>>>\|\.\.\.\)/ { h; bloop } 41 x; /^ *\(>>>\|\.\.\.\)/bloop; x 42 p; /"""\|'\'\'\'''/b 43 bloop 44 }; p' weboob/browser/browsers.py weboob/browser/pages.py 45 ''; 46 47 setupPyBuildFlags = ["--qt" "--xdg"]; 48 49 checkInputs = [ nose ]; 50 51 nativeBuildInputs = [ pyqt5 ]; 52 53 propagatedBuildInputs = [ 54 cssselect 55 dateutil 56 feedparser 57 gdata 58 gnupg 59 google_api_python_client 60 html2text 61 libyaml 62 lxml 63 mechanize 64 pdfminer 65 pillow 66 prettytable 67 pyqt5 68 pyyaml 69 requests 70 simplejson 71 termcolor 72 unidecode 73 ] ++ lib.optionals isPy27 [ futures ]; 74 75 checkPhase = '' 76 nosetests 77 ''; 78 79 meta = { 80 homepage = http://weboob.org; 81 description = "Collection of applications and APIs to interact with websites without requiring the user to open a browser"; 82 license = lib.licenses.agpl3; 83 }; 84}