GNU bug report logs - #25998
[PATCH] gnu: Add python-faker.

Previous Next

Package: guix-patches;

Reported by: Marius Bakke <mbakke <at> fastmail.com>

Date: Mon, 6 Mar 2017 13:42:02 UTC

Severity: normal

Tags: patch

Done: Marius Bakke <mbakke <at> fastmail.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 25998 in the body.
You can then email your comments to 25998 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#25998; Package guix-patches. (Mon, 06 Mar 2017 13:42:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Marius Bakke <mbakke <at> fastmail.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Mon, 06 Mar 2017 13:42:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Marius Bakke <mbakke <at> fastmail.com>
To: guix-patches <at> gnu.org
Cc: Marius Bakke <mbakke <at> fastmail.com>
Subject: [PATCH] gnu: Add python-faker.
Date: Mon,  6 Mar 2017 14:40:54 +0100
* gnu/packages/patches/python-fake-factory-fix-build-32bit.patch: Adjust
paths. Also rename to ...
* gnu/packages/patches/python-faker-fix-build-32bit.patch: ... this.
* gnu/local.mk (dist_patch_DATA): Adjust accordingly.
* gnu/packages/python.scm (python-faker, python2-faker): New variables.
(python-fake-factory)[properties]: Superseded by PYTHON-FAKER.
(python2-fake-factory)[properties]: Superseded by PYTHON2-FAKER.
(python-orator, python2-orator)[propagated-inputs]: Replace
PYTHON-FAKE-FACTORY with PYTHON-FAKER.
---
 gnu/local.mk                                       |  2 +-
 ...it.patch => python-faker-fix-build-32bit.patch} |  6 +--
 gnu/packages/python.scm                            | 55 +++++++++++++++++++++-
 3 files changed, 57 insertions(+), 6 deletions(-)
 rename gnu/packages/patches/{python-fake-factory-fix-build-32bit.patch => python-faker-fix-build-32bit.patch} (94%)

diff --git a/gnu/local.mk b/gnu/local.mk
index c88892df5..12e5e4d9b 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -863,7 +863,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/python2-rdflib-drop-sparqlwrapper.patch	\
   %D%/packages/patches/python-statsmodels-fix-tests.patch	\
   %D%/packages/patches/python-configobj-setuptools.patch	\
-  %D%/packages/patches/python-fake-factory-fix-build-32bit.patch	\
+  %D%/packages/patches/python-faker-fix-build-32bit.patch	\
   %D%/packages/patches/python-paste-remove-website-test.patch	\
   %D%/packages/patches/python-paste-remove-timing-test.patch	\
   %D%/packages/patches/python-pygit2-disable-network-tests.patch	\
diff --git a/gnu/packages/patches/python-fake-factory-fix-build-32bit.patch b/gnu/packages/patches/python-faker-fix-build-32bit.patch
similarity index 94%
rename from gnu/packages/patches/python-fake-factory-fix-build-32bit.patch
rename to gnu/packages/patches/python-faker-fix-build-32bit.patch
index cb60896fa..466b28901 100644
--- a/gnu/packages/patches/python-fake-factory-fix-build-32bit.patch
+++ b/gnu/packages/patches/python-faker-fix-build-32bit.patch
@@ -2,10 +2,10 @@ These tests fail on 32-bit due to an overflow.
 
 Upstream bug URL: https://github.com/joke2k/faker/issues/408
 
-diff --git a/faker/tests/__init__.py b/faker/tests/__init__.py
+diff --git a/tests/__init__.py b/tests/__init__.py
 index 6026772..58b6b83 100644
---- a/faker/tests/__init__.py
-+++ b/faker/tests/__init__.py
+--- a/tests/__init__.py
++++ b/tests/__init__.py
 @@ -384,7 +384,6 @@ class FactoryTestCase(unittest.TestCase):
          provider = Provider
          # test century
diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 5631c7ac0..caf16a75f 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -11312,6 +11312,55 @@ parsing UK postcodes.")
 (define-public python2-ukpostcodeparser
   (package-with-python2 python-ukpostcodeparser))
 
+(define-public python-faker
+  (package
+  (name "python-faker")
+  (version "0.7.9")
+  (source (origin
+            (method url-fetch)
+            (uri (pypi-uri "Faker" version))
+            (sha256
+             (base32
+              "1fh2p2yz0fsdr4fqwxgddwbvfb6qn6vp8yx0qwqzra27yq5d1wsm"))
+            (patches
+             (search-patches "python-faker-fix-build-32bit.patch"))
+            (modules '((guix build utils)))
+            (snippet
+             '(begin
+                (for-each delete-file (find-files "." "\\.pyc$"))
+                #t))))
+  (build-system python-build-system)
+  (arguments
+   '(#:phases
+     (modify-phases %standard-phases
+       (replace 'check
+         (lambda _
+           (zero? (system* "python" "-m" "unittest" "-v" "tests")))))))
+  (native-inputs
+   `(;; For testing
+     ("python-email-validator" ,python-email-validator)
+     ("python-mock" ,python-mock)
+     ("python-ukpostcodeparser" ,python-ukpostcodeparser)))
+  (propagated-inputs
+   `(("python-dateutil" ,python-dateutil)
+     ("python-six" ,python-six)))
+  (home-page "https://github.com/joke2k/faker")
+  (synopsis "Python package that generates fake data")
+  (description
+   "Faker is a Python package that generates fake data such as names,
+addresses, and phone numbers.")
+  (license license:expat)
+  (properties `((python2-variant . ,(delay python2-faker))))))
+
+(define-public python2-faker
+  (let ((base (package-with-python2 (strip-python2-variant
+                                     python-faker))))
+    (package
+      (inherit base)
+      (propagated-inputs
+       `(("python2-ipaddress" ,python2-ipaddress)
+         ,@(package-propagated-inputs base))))))
+
 (define-public python-fake-factory
   (package
   (name "python-fake-factory")
@@ -11346,13 +11395,15 @@ parsing UK postcodes.")
    "Faker is a Python package that generates fake data such as names,
 addresses, and phone numbers.")
   (license license:expat)
-  (properties `((python2-variant . ,(delay python2-fake-factory))))))
+  (properties `((python2-variant . ,(delay python2-fake-factory))
+                (superseded . ,python-faker)))))
 
 (define-public python2-fake-factory
   (let ((base (package-with-python2 (strip-python2-variant
                                      python-fake-factory))))
     (package
       (inherit base)
+      (properties `((superseded . ,python2-faker)))
       (propagated-inputs
        `(("python2-ipaddress" ,python2-ipaddress)
          ,@(package-propagated-inputs base))))))
@@ -11419,7 +11470,7 @@ mocks, stubs and fakes.")
      `(("python-arrow" ,python-arrow)
        ("python-blinker" ,python-blinker)
        ("python-cleo" ,python-cleo)
-       ("python-fake-factory" ,python-fake-factory)
+       ("python-faker" ,python-faker)
        ("python-inflection" ,python-inflection)
        ("python-lazy-object-proxy" ,python-lazy-object-proxy)
        ("python-pyaml" ,python-pyaml)
-- 
2.12.0





Information forwarded to guix-patches <at> gnu.org:
bug#25998; Package guix-patches. (Tue, 07 Mar 2017 04:24:01 GMT) Full text and rfc822 format available.

Message #8 received at 25998 <at> debbugs.gnu.org (full text, mbox):

From: Kei Kebreau <kei <at> openmailbox.org>
To: Marius Bakke <mbakke <at> fastmail.com>
Cc: 25998 <at> debbugs.gnu.org
Subject: Re: bug#25998: [PATCH] gnu: Add python-faker.
Date: Mon, 06 Mar 2017 23:23:17 -0500
[Message part 1 (text/plain, inline)]
Marius Bakke <mbakke <at> fastmail.com> writes:

> * gnu/packages/patches/python-fake-factory-fix-build-32bit.patch: Adjust
> paths. Also rename to ...
> * gnu/packages/patches/python-faker-fix-build-32bit.patch: ... this.
> * gnu/local.mk (dist_patch_DATA): Adjust accordingly.
> * gnu/packages/python.scm (python-faker, python2-faker): New variables.
> (python-fake-factory)[properties]: Superseded by PYTHON-FAKER.
> (python2-fake-factory)[properties]: Superseded by PYTHON2-FAKER.
> (python-orator, python2-orator)[propagated-inputs]: Replace
> PYTHON-FAKE-FACTORY with PYTHON-FAKER.
> ---
>  gnu/local.mk                                       |  2 +-
>  ...it.patch => python-faker-fix-build-32bit.patch} |  6 +--
>  gnu/packages/python.scm                            | 55 +++++++++++++++++++++-
>  3 files changed, 57 insertions(+), 6 deletions(-)
>  rename gnu/packages/patches/{python-fake-factory-fix-build-32bit.patch => python-faker-fix-build-32bit.patch} (94%)
>
> diff --git a/gnu/local.mk b/gnu/local.mk
> index c88892df5..12e5e4d9b 100644
> --- a/gnu/local.mk
> +++ b/gnu/local.mk
> @@ -863,7 +863,7 @@ dist_patch_DATA =						\
>    %D%/packages/patches/python2-rdflib-drop-sparqlwrapper.patch	\
>    %D%/packages/patches/python-statsmodels-fix-tests.patch	\
>    %D%/packages/patches/python-configobj-setuptools.patch	\
> -  %D%/packages/patches/python-fake-factory-fix-build-32bit.patch	\
> +  %D%/packages/patches/python-faker-fix-build-32bit.patch	\
>    %D%/packages/patches/python-paste-remove-website-test.patch	\
>    %D%/packages/patches/python-paste-remove-timing-test.patch	\
>    %D%/packages/patches/python-pygit2-disable-network-tests.patch	\
> diff --git a/gnu/packages/patches/python-fake-factory-fix-build-32bit.patch b/gnu/packages/patches/python-faker-fix-build-32bit.patch
> similarity index 94%
> rename from gnu/packages/patches/python-fake-factory-fix-build-32bit.patch
> rename to gnu/packages/patches/python-faker-fix-build-32bit.patch
> index cb60896fa..466b28901 100644
> --- a/gnu/packages/patches/python-fake-factory-fix-build-32bit.patch
> +++ b/gnu/packages/patches/python-faker-fix-build-32bit.patch
> @@ -2,10 +2,10 @@ These tests fail on 32-bit due to an overflow.
>  
>  Upstream bug URL: https://github.com/joke2k/faker/issues/408
>  
> -diff --git a/faker/tests/__init__.py b/faker/tests/__init__.py
> +diff --git a/tests/__init__.py b/tests/__init__.py
>  index 6026772..58b6b83 100644
> ---- a/faker/tests/__init__.py
> -+++ b/faker/tests/__init__.py
> +--- a/tests/__init__.py
> ++++ b/tests/__init__.py
>  @@ -384,7 +384,6 @@ class FactoryTestCase(unittest.TestCase):
>           provider = Provider
>           # test century
> diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
> index 5631c7ac0..caf16a75f 100644
> --- a/gnu/packages/python.scm
> +++ b/gnu/packages/python.scm
> @@ -11312,6 +11312,55 @@ parsing UK postcodes.")
>  (define-public python2-ukpostcodeparser
>    (package-with-python2 python-ukpostcodeparser))
>  
> +(define-public python-faker
> +  (package
> +  (name "python-faker")
> +  (version "0.7.9")
> +  (source (origin
> +            (method url-fetch)
> +            (uri (pypi-uri "Faker" version))
> +            (sha256
> +             (base32
> +              "1fh2p2yz0fsdr4fqwxgddwbvfb6qn6vp8yx0qwqzra27yq5d1wsm"))
> +            (patches
> +             (search-patches "python-faker-fix-build-32bit.patch"))
> +            (modules '((guix build utils)))
> +            (snippet
> +             '(begin
> +                (for-each delete-file (find-files "." "\\.pyc$"))
> +                #t))))
> +  (build-system python-build-system)
> +  (arguments
> +   '(#:phases
> +     (modify-phases %standard-phases
> +       (replace 'check
> +         (lambda _
> +           (zero? (system* "python" "-m" "unittest" "-v" "tests")))))))
> +  (native-inputs
> +   `(;; For testing
> +     ("python-email-validator" ,python-email-validator)
> +     ("python-mock" ,python-mock)
> +     ("python-ukpostcodeparser" ,python-ukpostcodeparser)))
> +  (propagated-inputs
> +   `(("python-dateutil" ,python-dateutil)
> +     ("python-six" ,python-six)))
> +  (home-page "https://github.com/joke2k/faker")
> +  (synopsis "Python package that generates fake data")
> +  (description
> +   "Faker is a Python package that generates fake data such as names,
> +addresses, and phone numbers.")
> +  (license license:expat)
> +  (properties `((python2-variant . ,(delay python2-faker))))))
> +
> +(define-public python2-faker
> +  (let ((base (package-with-python2 (strip-python2-variant
> +                                     python-faker))))
> +    (package
> +      (inherit base)
> +      (propagated-inputs
> +       `(("python2-ipaddress" ,python2-ipaddress)
> +         ,@(package-propagated-inputs base))))))
> +
>  (define-public python-fake-factory
>    (package
>    (name "python-fake-factory")
> @@ -11346,13 +11395,15 @@ parsing UK postcodes.")
>     "Faker is a Python package that generates fake data such as names,
>  addresses, and phone numbers.")
>    (license license:expat)
> -  (properties `((python2-variant . ,(delay python2-fake-factory))))))
> +  (properties `((python2-variant . ,(delay python2-fake-factory))
> +                (superseded . ,python-faker)))))
>  
>  (define-public python2-fake-factory
>    (let ((base (package-with-python2 (strip-python2-variant
>                                       python-fake-factory))))
>      (package
>        (inherit base)
> +      (properties `((superseded . ,python2-faker)))
>        (propagated-inputs
>         `(("python2-ipaddress" ,python2-ipaddress)
>           ,@(package-propagated-inputs base))))))
> @@ -11419,7 +11470,7 @@ mocks, stubs and fakes.")
>       `(("python-arrow" ,python-arrow)
>         ("python-blinker" ,python-blinker)
>         ("python-cleo" ,python-cleo)
> -       ("python-fake-factory" ,python-fake-factory)
> +       ("python-faker" ,python-faker)
>         ("python-inflection" ,python-inflection)
>         ("python-lazy-object-proxy" ,python-lazy-object-proxy)
>         ("python-pyaml" ,python-pyaml)

Builds and lints fine on my machine.
[signature.asc (application/pgp-signature, inline)]

Reply sent to Marius Bakke <mbakke <at> fastmail.com>:
You have taken responsibility. (Wed, 08 Mar 2017 17:34:02 GMT) Full text and rfc822 format available.

Notification sent to Marius Bakke <mbakke <at> fastmail.com>:
bug acknowledged by developer. (Wed, 08 Mar 2017 17:34:02 GMT) Full text and rfc822 format available.

Message #13 received at 25998-done <at> debbugs.gnu.org (full text, mbox):

From: Marius Bakke <mbakke <at> fastmail.com>
To: Kei Kebreau <kei <at> openmailbox.org>
Cc: 25998-done <at> debbugs.gnu.org
Subject: Re: bug#25998: [PATCH] gnu: Add python-faker.
Date: Wed, 08 Mar 2017 18:33:11 +0100
[Message part 1 (text/plain, inline)]
Kei Kebreau <kei <at> openmailbox.org> writes:

> Builds and lints fine on my machine.

Thanks for checking, pushed!

This is really just a case of upstream renaming the project, but I
wanted to give downstream users some time to migrate before removing the
old "python-fake-factory".
[signature.asc (application/pgp-signature, inline)]

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Thu, 06 Apr 2017 11:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 8 years and 134 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.