Bug 1659831

Summary: saving to the file fails with TypeError: write() argument must be str, not bytes
Product: [Fedora] Fedora Reporter: Alan Pevec (Fedora) <apevec>
Component: python-qrcodeAssignee: Fabian Affolter <mail>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: 7d28c752, mail, michel, tomspur
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: python-qrcode-6.1-1.fc30 python-qrcode-6.1-1.fc29 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-06-04 02:00:20 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Alan Pevec (Fedora) 2018-12-16 21:56:01 UTC
Description of problem:
saving to the file fails

Version-Release number of selected component (if applicable):
python3-qrcode-5.1-13.fc29.noarch


How reproducible:
always

Steps to Reproduce:
1. $ echo whatever |qr > /tmp/qr.png
Traceback (most recent call last):
  File "/usr/bin/qr", line 11, in <module>
    load_entry_point('qrcode==5.1', 'console_scripts', 'qr')()
  File "/usr/lib/python3.7/site-packages/qrcode/console_scripts.py", line 59, in main
    img.save(sys.stdout)
  File "/usr/lib/python3.7/site-packages/qrcode/image/pil.py", line 32, in save
    self._img.save(stream, kind)
  File "/usr/lib64/python3.7/site-packages/PIL/Image.py", line 1969, in save
    save_handler(self, fp, filename)
  File "/usr/lib64/python3.7/site-packages/PIL/PngImagePlugin.py", line 734, in _save
    fp.write(_MAGIC)
TypeError: write() argument must be str, not bytes

Comment 1 Alan Pevec (Fedora) 2018-12-16 21:59:27 UTC
FWIW this was actually reported via ABRT in bug 1599847 against F27 and marked EOL.

Comment 2 Fedora Update System 2019-05-26 15:40:34 UTC
python-qrcode-6.1-1.fc30 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-27f1118d0c

Comment 3 Fedora Update System 2019-05-26 16:00:18 UTC
python-qrcode-6.1-1.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-3cf44a74c9

Comment 4 Fedora Update System 2019-05-27 01:47:59 UTC
python-qrcode-6.1-1.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-27f1118d0c

Comment 5 Fedora Update System 2019-05-27 04:11:46 UTC
python-qrcode-6.1-1.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-3cf44a74c9

Comment 6 Fabian Affolter 2019-06-01 18:33:17 UTC
*** Bug 1661256 has been marked as a duplicate of this bug. ***

Comment 7 Fedora Update System 2019-06-04 02:00:20 UTC
python-qrcode-6.1-1.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.

Comment 8 Fedora Update System 2019-06-04 02:22:03 UTC
python-qrcode-6.1-1.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.