Bug#892240: diffoscope: crashes comparing directories with python3-xattr installed

2018-03-08 Thread Chris Lamb
tags 892240 + pending
thanks

Fixed in Git, pending upload. Thanks!

  
https://anonscm.debian.org/git/reproducible/diffoscope.git/commit/?id=ec51d78da0bbc32fac09cf5b0f56039b8f79c696


Regards,

-- 
  ,''`.
 : :'  : Chris Lamb
 `. `'`  la...@debian.org / chris-lamb.co.uk
   `-

___
Reproducible-builds mailing list
Reproducible-builds@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/reproducible-builds


Bug#892240: diffoscope: crashes comparing directories with python3-xattr installed

2018-03-07 Thread Doug Freed
python3-xattr has an xattr class that can be used like a dict (and
thus call .items() to behave like pyxattr's xattr.get_all()).  A
wrapper function like this would work:

def xattr_get_all(path):
try:
return xattr.get_all(path)
except AttributeError:
return xattr.xattr(path).items()

--
dwfreed

___
Reproducible-builds mailing list
Reproducible-builds@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/reproducible-builds


Bug#892240: diffoscope: crashes comparing directories with python3-xattr installed

2018-03-06 Thread Paul Wise
Package: diffoscope
Version: 91
Severity: wishlist 
Usertags: crash

diffoscope crashes when comparing directories when the python3-xattr
package is installed but the python3-pyxattr package is not installed.

I would suggest that diffoscope should either conflict with the
incompatible python3-xattr package (as python3-pyxattr does), or
add support for the API provided by the python3-xattr package.

Personally I would prefer the latter, since python3-xattr has a
useful command-line tool in the xattr package that I sometimes use.

$ mkdir foo bar
$ diffoscope foo bar
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/diffoscope/main.py", line 422, in main
sys.exit(run_diffoscope(parsed_args))
  File "/usr/lib/python3/dist-packages/diffoscope/main.py", line 394, in 
run_diffoscope
difference = compare_root_paths(path1, path2)
  File 
"/usr/lib/python3/dist-packages/diffoscope/comparators/utils/compare.py", line 
62, in compare_root_paths
return compare_directories(path1, path2)
  File "/usr/lib/python3/dist-packages/diffoscope/comparators/directory.py", 
line 165, in compare_directories
return FilesystemDirectory(path1).compare(FilesystemDirectory(path2))
  File "/usr/lib/python3/dist-packages/diffoscope/comparators/directory.py", 
line 216, in compare
differences.extend(compare_meta(self.name, other.name))
  File "/usr/lib/python3/dist-packages/diffoscope/comparators/directory.py", 
line 161, in compare_meta
differences.append(xattr(path1, path2))
  File "/usr/lib/python3/dist-packages/diffoscope/comparators/directory.py", 
line 124, in xattr
fn(path1), fn(path2), path1, path2, source='extended file attributes',
  File "/usr/lib/python3/dist-packages/diffoscope/comparators/directory.py", 
line 121, in fn
) for k, v in sorted(xattr.get_all(x)))
AttributeError: module 'xattr' has no attribute 'get_all'

-- System Information:
Debian Release: buster/sid
  APT prefers testing-debug
  APT policy: (900, 'testing-debug'), (900, 'testing'), (800, 
'unstable-debug'), (800, 'unstable'), (790, 'buildd-unstable'), (700, 
'experimental-debug'), (700, 'experimental'), (690, 'buildd-experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 4.14.0-3-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_AU.utf8, LC_CTYPE=en_AU.utf8 (charmap=UTF-8), 
LANGUAGE=en_AU.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages diffoscope depends on:
ii  python33.6.4-1
ii  python3-distro 1.0.1-2
ii  python3-libarchive-c   2.1-3.1
ii  python3-magic  2:0.4.15-1
ii  python3-pkg-resources  38.4.0-1

Versions of packages diffoscope recommends:
ii  abootimg 0.6-1+b2
ii  acl  2.2.52-3+b1
ii  apktool  2.3.1+dfsg-1
ii  binutils-multiarch   2.30-5
ii  bzip21.0.6-8.1
ii  caca-utils   0.99.beta19-2+b2
ii  colord   1.3.3-2
ii  db-util  5.3.1
ii  default-jdk [java-sdk]   2:1.8-59
ii  default-jdk-headless 2:1.8-59
pn  device-tree-compiler 
pn  docx2txt 
ii  e2fsprogs1.43.9-2
ii  enjarify 1:1.0.3-3
ii  fontforge-extras 0.3-4
pn  fp-utils 
ii  genisoimage  9:1.1.11-3+b2
ii  gettext  0.19.8.1-4
ii  ghc  8.0.2-11
ii  ghostscript  9.22~dfsg-2
ii  giflib-tools 5.1.4-2
ii  gnupg2.2.5-1
ii  imagemagick  8:6.9.9.34+dfsg-3
ii  imagemagick-6.q16 [imagemagick]  8:6.9.9.34+dfsg-3
ii  jsbeautifier 1.6.4-6
pn  libarchive-tools 
ii  llvm 1:4.0-40
pn  mono-utils   
pn  odt2txt  
pn  oggvideotools
ii  openjdk-8-jdk [java-sdk] 8u151-b12-1
ii  openssh-client   1:7.6p1-4
ii  pdftk2.02-4+b2
ii  pgpdump  0.31-0.2
ii  poppler-utils0.61.1-2
pn  procyon-decompiler   
ii  python3-argcomplete  1.8.1-1
ii  python3-binwalk  2.1.1-16
ii  python3-debian   0.1.32
pn  python3-defusedxml   
pn  python3-guestfs  
ii  python3-jsondiff 1.1.1-1
ii  python3-progressbar  2.3-4
ii  python3-rpm  4.14.0+dfsg1-2
ii  python3-tlsh 3.4.4+20151206-1+b3
ii  python3-xattr [python3-pyxattr]  0.9.3-1
pn  r-base-core  
ii  rpm2cpio 4.14.0+dfsg1-2
ii  sng  1.1.0-1+b1
ii  sqlite3  3.22.0-1
ii  squashfs-tools