** Description changed: + [Impact] + python-qrencode is currently broken for all users in yakkety due to the removal of Image.fromstring from pillow. + + The fix is to replace all calls to Image.fromstring with + Image.frombytes. + + [Test Case] + Run the following script and see if it ends in an exception: + + ``` + import qrencode + qrencode.encode_scaled("foo", 1) + ``` + + [Regression Potential] + It's unlikely that python-qrencode can regress any further, because in its current state, both exported python methods are completely broken and will throw an exception unconditionally with the pillow version in Yakkety. + + [Other Info] + rdeps may also be broken if they use Image.tostring on the output. So far, the only known rdep that is broken is qreator. + + Below is the stack trace and exception thrown by the broken version of + qrencode. + In [5]: qrencode.encode_scaled("foo",1) --------------------------------------------------------------------------- Exception Traceback (most recent call last) <ipython-input-5-be07c22beab2> in <module>() ----> 1 qrencode.encode_scaled("foo",1) /usr/lib/python2.7/dist-packages/qrencode/__init__.pyc in encode_scaled(data, size, version, level, hint, case_sensitive) - 67 the QR-code. - 68 """ + 67 the QR-code. + 68 """ ---> 69 version, src_size, im = encode(data, version, level, hint, case_sensitive) - 70 if size < src_size: - 71 size = src_size + 70 if size < src_size: + 71 size = src_size /usr/lib/python2.7/dist-packages/qrencode/__init__.pyc in encode(data, version, level, hint, case_sensitive) - 45 version, size, data = _encode(data, version, level, hint, False) - 46 + 45 version, size, data = _encode(data, version, level, hint, False) + 46 ---> 47 im = Image.fromstring('L', (size, size), data) - 48 return (version, size, im) - 49 + 48 return (version, size, im) + 49 /usr/lib/python2.7/dist-packages/PIL/Image.pyc in fromstring(*args, **kw) - 2061 def fromstring(*args, **kw): - 2062 raise Exception("fromstring() has been removed. " + + 2061 def fromstring(*args, **kw): + 2062 raise Exception("fromstring() has been removed. " + -> 2063 "Please call frombytes() instead.") - 2064 - 2065 + 2064 + 2065 Exception: fromstring() has been removed. Please call frombytes() instead. In [6]: ProblemType: Bug DistroRelease: Ubuntu 16.04 Package: python-qrencode 1.01-5 Uname: Linux 4.6.0-040600-generic x86_64 ApportVersion: 2.20.1-0ubuntu2.1 Architecture: amd64 CurrentDesktop: GNOME Date: Tue May 31 07:40:21 2016 InstallationDate: Installed on 2015-12-02 (180 days ago) InstallationMedia: Ubuntu-GNOME 16.04 LTS "Xenial Xerus" - Alpha amd64 (20151027) SourcePackage: python-qrencode UpgradeStatus: No upgrade log present (probably fresh install)
-- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1587249 Title: PIL exception fromstring To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/python-qrencode/+bug/1587249/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs