classification
Title: CSV output of benchmark runner tries to write to binary file
Type: behavior Stage: resolved
Components: Benchmarks Versions:
process
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 2013-09-28 17:13 by pitrou. This issue is now closed.

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

Index: perf.py
===================================================================
--- perf.py     (Revision 80409)
+++ perf.py     (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
http://hg.python.org/benchmarks/rev/07a8440b3987
msg198533 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2013-09-28 17:13
Fixed!
History
Date User Action Args
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