Source: flask-limiter
Version: 0.9.3-1
Severity: wishlist
Tags: patch
User: reproducible-bui...@lists.alioth.debian.org
Usertags: buildpath
X-Debbugs-Cc: reproducible-b...@lists.alioth.debian.org

Hi,

Whilst working on the Reproducible Builds effort [0], we noticed
that flask-limiter could not be built reproducibly.

It was previously using the current build path to parse its own
version number. There might be a cleaner, more general, solution
so this could be considered a WIP patch.


Patch attached.

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


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      la...@debian.org / chris-lamb.co.uk
       `-
diff --git a/versioneer.py b/versioneer.py
index 3b03c13..59acbb7 100644
--- a/versioneer.py
+++ b/versioneer.py
@@ -491,6 +491,12 @@ def write_to_version_file(filename, versions):
 
 
 def get_versions(default=DEFAULT, verbose=False):
+    import subprocess
+    debian_version = subprocess.check_output(('dpkg-parsechangelog', 
'-SVersion'))
+    return {
+        'full': '', 
+        'version': debian_version.split('-', 1)[0],
+    }
     # returns dict with two keys: 'version' and 'full'
     assert versionfile_source is not None, "please set 
versioneer.versionfile_source"
     assert tag_prefix is not None, "please set versioneer.tag_prefix"

Reply via email to