This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: CSV output of benchmark runner tries to write to binary file
Type: behavior Stage: resolved
Components: Benchmarks Versions:
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: brett.cannon, pitrou, python-dev, scoder
Priority: normal Keywords:

Created on 2013-09-27 15:45 by scoder, last changed 2022-04-11 14:57 by admin. This issue is now closed.

Messages (3)
msg198483 - (view) Author: Stefan Behnel (scoder) * (Python committer) Date: 2013-09-27 15:45
The script opens the file for CSV output in binary mode, which no longer works in Py3:

---     (Revision 80409)
+++     (Arbeitskopie)
@@ -2443,7 +2448,7 @@
         raise ValueError("Invalid output_style: %r" % options.output_style)
     if options.csv:
-        with open(options.csv, "wb") as f:
+        with open(options.csv, "w") as f:
             writer = csv.writer(f)
             writer.writerow(['Benchmark', 'Base', 'Changed'])
             for name, result in results:
msg198532 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2013-09-28 17:13
New changeset 07a8440b3987 by Antoine Pitrou in branch 'default':
Issue #19107: fix csv output with Python 3
msg198533 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2013-09-28 17:13
Date User Action Args
2022-04-11 14:57:51adminsetgithub: 63306
2013-09-28 17:13:55pitrousetstatus: open -> closed
resolution: fixed
messages: + msg198533

stage: resolved
2013-09-28 17:13:13python-devsetnosy: + python-dev
messages: + msg198532
2013-09-27 15:45:44scodersetnosy: + brett.cannon, pitrou
2013-09-27 15:45:18scodercreate