Source: python-click
Version: 6.7-3.1
Severity: wishlist
Tags: patch
User: reproducible-bui...@lists.alioth.debian.org
Usertags: randomness
X-Debbugs-Cc: reproducible-b...@lists.alioth.debian.org

Hi,

Whilst working on the Reproducible Builds effort [0], we noticed
that python-click could not be built reproducibly as it contains
non-determistic outputs in the documentation examples.

Patch attached.

 [0] https://reproducible-builds.org/


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      la...@debian.org / chris-lamb.co.uk
       `-
--- a/debian/patches/reproducible_build.patch   1970-01-01 01:00:00.000000000 
+0100
--- b/debian/patches/reproducible_build.patch   2018-04-09 09:07:02.161010552 
+0100
@@ -0,0 +1,28 @@
+Description: Make the build reproducible
+Author: Chris Lamb <la...@debian.org>
+Last-Update: 2018-04-09
+
+--- python-click-6.7.orig/docs/advanced.rst
++++ python-click-6.7/docs/advanced.rst
+@@ -295,8 +295,8 @@ In the end you end up with something lik
+     @click.option('-v', '--verbose', is_flag=True, help='Enables verbose 
mode')
+     @click.argument('timeit_args', nargs=-1, type=click.UNPROCESSED)
+     def cli(verbose, timeit_args):
+-        """A wrapper around Python's timeit."""
+-        cmdline = ['python', '-mtimeit'] + list(timeit_args)
++        """A fake wrapper around Python's timeit."""
++        cmdline = ['echo', 'python', '-mtimeit'] + list(timeit_args)
+         if verbose:
+             click.echo('Invoking: %s' % ' '.join(cmdline))
+         call(cmdline)
+--- python-click-6.7.orig/docs/complex.rst
++++ python-click-6.7/docs/complex.rst
+@@ -210,7 +210,7 @@ As such it runs standalone:
+     @click.command()
+     @pass_repo
+     def cp(repo):
+-        click.echo(repo)
++        click.echo(isinstance(repo, Repo))
+ 
+ As you can see:
+ 
--- a/debian/patches/series     2018-04-09 09:03:39.167924322 +0100
--- b/debian/patches/series     2018-04-09 09:07:33.397177858 +0100
@@ -1 +1,2 @@
 skip_test_legacy_callbacks.patch
+reproducible_build.patch

Reply via email to