1{ lib, python, buildPythonPackage, fetchPypi, isPy3k }:
2
3buildPythonPackage rec {
4 pname = "demjson";
5 version = "2.2.4";
6
7 src = fetchPypi {
8 inherit pname version;
9 sha256 = "0ygbddpnvp5lby6mr5kz60la3hkvwwzv3wwb3z0w9ngxl0w21pii";
10 };
11
12 checkPhase = lib.optionalString isPy3k ''
13 ${python.interpreter} -m lib2to3 -w test/test_demjson.py
14 '' + ''
15 ${python.interpreter} test/test_demjson.py
16 '';
17
18 meta = with lib; {
19 description = "Encoder/decoder and lint/validator for JSON (JavaScript Object Notation)";
20 homepage = "https://github.com/dmeranda/demjson";
21 license = licenses.lgpl3Plus;
22 maintainers = with maintainers; [ bjornfor ];
23 platforms = platforms.all;
24 };
25}