@@ -1,29 +1,30 @@
1−{ lib, python3 }:
1+# dateparser tests fail on pyton37: https://github.com/NixOS/nixpkgs/issues/52766
2+{ lib, python36, glibcLocales }:
23
3−python3.pkgs.buildPythonApplication rec {
4+python36.pkgs.buildPythonApplication rec {
45 pname = "homeassistant-cli";
5− version = "0.3.0";
6+ version = "0.4.2";
67
7− src = python3.pkgs.fetchPypi {
8+ src = python36.pkgs.fetchPypi {
89 inherit pname version;
9− sha256 = "42d7cb008801d7a448b62aed1fc46dd450ee67397bf16faabb02f691417db4b2";
10+ sha256 = "e0b05af9e49baf88a44f1b36c3446a106223016dceefd5f9910e204af5901f44";
1011 };
1112
1213 postPatch = ''
1314 # Ignore pinned versions
14− sed -i "s/'\(.*\)==.*'/'\1'/g" setup.py
15+ sed -i "s/'\(.*\)\(==\|>=\).*'/'\1'/g" setup.py
1516 '';
1617
17− propagatedBuildInputs = with python3.pkgs; [
18− requests pyyaml netdisco click click-log tabulate idna jsonpath_rw jinja2
18+ propagatedBuildInputs = with python36.pkgs; [
19+ requests pyyaml netdisco click click-log tabulate idna jsonpath_rw jinja2 dateparser
1920 ];
2021
21− checkInputs = with python3.pkgs; [
22− pytest requests-mock
22+ checkInputs = with python36.pkgs; [
23+ pytest requests-mock glibcLocales
2324 ];
2425
2526 checkPhase = ''
26− pytest
27+ LC_ALL=en_US.UTF-8 pytest
2728 '';
2829
2930 meta = with lib; {