Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pythonPackages.dateparser: 0.6.0 -> 0.7.0 #34768

Merged
merged 1 commit into from
Feb 9, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
35 changes: 14 additions & 21 deletions pkgs/development/python-modules/dateparser/default.nix
Original file line number Diff line number Diff line change
@@ -1,47 +1,40 @@
{ stdenv, fetchFromGitHub, buildPythonPackage, isPy3k
{ lib, fetchPypi, buildPythonPackage, isPy3k
, nose
, parameterized
, mock
, glibcLocales
, six
, jdatetime
, pyyaml
, dateutil
, umalqurra
, pytz
, tzlocal
, regex
, ruamel_yaml }:

buildPythonPackage rec {
pname = "dateparser";
version = "0.6.0";
version = "0.7.0";

src = fetchFromGitHub {
owner = "scrapinghub";
repo = pname;
rev = "refs/tags/v${version}";
sha256 = "0q2vyzvlj46r6pr0s6m1a0md1cpg9nv1n3xw286l4x2cc7fj2g3y";
src = fetchPypi {
inherit pname version;
sha256 = "940828183c937bcec530753211b70f673c0a9aab831e43273489b310538dff86";
};

# Replace nose-parameterized by parameterized
prePatch = ''
sed -i s/nose_parameterized/parameterized/g tests/*.py
sed -i s/nose-parameterized/parameterized/g tests/requirements.txt
'';

# Upstream Issue: https://github.com/scrapinghub/dateparser/issues/364
disabled = isPy3k;

checkInputs = [ nose parameterized mock glibcLocales ];
checkInputs = [ nose mock parameterized six glibcLocales ];
preCheck =''
# skip because of missing convertdate module, which is an extra requirement
rm tests/test_jalali.py
'';

propagatedBuildInputs = [ six jdatetime pyyaml dateutil
umalqurra pytz tzlocal regex ruamel_yaml ];
propagatedBuildInputs = [
# install_requires
dateutil pytz regex tzlocal
# extra_requires
jdatetime ruamel_yaml umalqurra
];

meta = with stdenv.lib;{
meta = with lib; {
description = "Date parsing library designed to parse dates from HTML pages";
homepage = https://github.com/scrapinghub/dateparser;
license = licenses.bsd3;
Expand Down