[Reproducible-commits] [epydoc] 01/01: move changes into separate bug reported in BTS
Sascha Steinbiss
sascha at steinbiss.name
Tue May 31 21:29:08 UTC 2016
This is an automated email from the git hooks/post-receive script.
sascha-guest pushed a commit to branch pu/reproducible_builds
in repository epydoc.
commit e5a2133c0c063d6f38c654f2305368c70d4c0d21
Author: Sascha Steinbiss <sascha at steinbiss.name>
Date: Tue May 31 20:54:07 2016 +0000
move changes into separate bug reported in BTS
---
debian/patches/deterministic-sort-2.patch | 35 +++++++++++++++++++++++++++
debian/patches/deterministic-sort.patch | 40 +++++--------------------------
debian/patches/series | 1 +
3 files changed, 42 insertions(+), 34 deletions(-)
diff --git a/debian/patches/deterministic-sort-2.patch b/debian/patches/deterministic-sort-2.patch
new file mode 100644
index 0000000..6760a92
--- /dev/null
+++ b/debian/patches/deterministic-sort-2.patch
@@ -0,0 +1,35 @@
+Description: make subclass traversal and input file handling deterministic
+Author: Sascha Steinbiss <sascha at steinbiss.name>
+Bug-Debian: https://bugs.debian.org/825968
+--- a/epydoc/docbuilder.py
++++ b/epydoc/docbuilder.py
+@@ -574,7 +574,7 @@
+ subpackage_dirs = set()
+ for subdir in pkg_path:
+ if os.path.isdir(subdir):
+- for name in os.listdir(subdir):
++ for name in sorted(os.listdir(subdir)):
+ filename = os.path.join(subdir, name)
+ # Is it a valid module filename?
+ if is_module_file(filename):
+@@ -660,7 +660,7 @@
+ num_items = 0
+
+ if is_package_dir(package_dir):
+- for name in os.listdir(package_dir):
++ for name in sorted(os.listdir(package_dir)):
+ filename = os.path.join(package_dir, name)
+ if is_module_file(filename):
+ num_items += 1
+--- a/epydoc/docwriter/html.py
++++ b/epydoc/docwriter/html.py
+@@ -879,7 +879,8 @@
+ len(doc.subclasses) > 0):
+ out('<dl><dt>Known Subclasses:</dt>\n<dd>\n ')
+ out(' <ul class="subclass-list">\n')
+- for i, subclass in enumerate(doc.subclasses):
++ sort_key = lambda c:tuple(reversed(c.canonical_name))
++ for i, subclass in enumerate(sorted(set(doc.subclasses), key=sort_key)):
+ href = self.href(subclass, context=doc)
+ if self._val_is_public(subclass): css = ''
+ else: css = ' class="private"'
diff --git a/debian/patches/deterministic-sort.patch b/debian/patches/deterministic-sort.patch
index 7d231f7..4b165ec 100644
--- a/debian/patches/deterministic-sort.patch
+++ b/debian/patches/deterministic-sort.patch
@@ -16,8 +16,9 @@ Bug: https://sourceforge.net/p/epydoc/bugs/370/
Bug-Debian: http://bugs.debian.org/795835
Forwarded: https://sourceforge.net/p/epydoc/bugs/370/
Last-Update: 2015-08-17
---- a/epydoc/docwriter/html.py
-+++ b/epydoc/docwriter/html.py
+diff -u -r epydoc-3.0.1+dfsg.old/epydoc/docwriter/html.py epydoc-3.0.1+dfsg/epydoc/docwriter/html.py
+--- epydoc-3.0.1+dfsg.old/epydoc/docwriter/html.py 2015-08-16 18:57:38.152484836 +0000
++++ epydoc-3.0.1+dfsg/epydoc/docwriter/html.py 2015-08-17 09:59:14.756288022 +0000
@@ -404,6 +404,7 @@
imports=False, packages=False, bases=False, submodules=False,
subclasses=False, private=self._show_private))
@@ -26,17 +27,7 @@ Last-Update: 2015-08-17
"""The list of L{ModuleDoc}s for the documented modules."""
self.module_set = set(self.module_list)
"""The set of L{ModuleDoc}s for the documented modules."""
-@@ -878,7 +879,8 @@
- len(doc.subclasses) > 0):
- out('<dl><dt>Known Subclasses:</dt>\n<dd>\n ')
- out(' <ul class="subclass-list">\n')
-- for i, subclass in enumerate(doc.subclasses):
-+ sort_key = lambda c:tuple(reversed(c.canonical_name))
-+ for i, subclass in enumerate(sorted(set(doc.subclasses), key=sort_key)):
- href = self.href(subclass, context=doc)
- if self._val_is_public(subclass): css = ''
- else: css = ' class="private"'
-@@ -1012,7 +1014,8 @@
+@@ -1012,7 +1013,8 @@
#class_set.add(base)
out('<ul class="nomargin-top">\n')
@@ -46,7 +37,7 @@ Last-Update: 2015-08-17
if doc.bases != UNKNOWN and len(doc.bases)==0:
self.write_class_tree_item(out, doc, class_set)
out('</ul>\n')
-@@ -2817,7 +2820,8 @@
+@@ -2817,7 +2819,8 @@
>>> # endif
>>> if doc.subclasses:
<ul>
@@ -56,23 +47,4 @@ Last-Update: 2015-08-17
>>> if subclass in class_set:
>>> self.write_class_tree_item(out, subclass, class_set)
>>> #endif
---- a/epydoc/docbuilder.py
-+++ b/epydoc/docbuilder.py
-@@ -574,7 +574,7 @@
- subpackage_dirs = set()
- for subdir in pkg_path:
- if os.path.isdir(subdir):
-- for name in os.listdir(subdir):
-+ for name in sorted(os.listdir(subdir)):
- filename = os.path.join(subdir, name)
- # Is it a valid module filename?
- if is_module_file(filename):
-@@ -660,7 +660,7 @@
- num_items = 0
-
- if is_package_dir(package_dir):
-- for name in os.listdir(package_dir):
-+ for name in sorted(os.listdir(package_dir)):
- filename = os.path.join(package_dir, name)
- if is_module_file(filename):
- num_items += 1
+
diff --git a/debian/patches/series b/debian/patches/series
index 999dddb..3d6d774 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -10,3 +10,4 @@ build-time.patch
source-date.patch
hide-memory-addresses.patch
deterministic-sort.patch
+deterministic-sort-2.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/epydoc.git
More information about the Reproducible-commits
mailing list