Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit a447613

Browse files
committed
handled sf bugs 2831556 and 2830525; better bar error messages and backend driver configs
svn path=/branches/v0_99_maint/; revision=7334
1 parent 7aa827f commit a447613

2 files changed

Lines changed: 8 additions & 8 deletions

File tree

examples/tests/backend_driver.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,7 @@ def drive(backend, directories, python=['python'], switches = []):
374374
if backend in rcsetup.interactive_bk:
375375
tmpfile.write('show()')
376376
else:
377-
tmpfile.write('\nsavefig("%s", dpi=150)' % outfile)
377+
tmpfile.write('\nsavefig(r"%s", dpi=150)' % outfile)
378378

379379
tmpfile.close()
380380
start_time = time.time()
@@ -458,7 +458,7 @@ def parse_options():
458458
python = ['valgrind', '--tool=memcheck', '--leak-check=yes',
459459
'--log-file=%(name)s', 'python']
460460
elif sys.platform == 'win32':
461-
python = [r'c:\Python24\python.exe']
461+
python = [sys.executable]
462462
else:
463463
python = ['python']
464464

lib/matplotlib/axes.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4229,20 +4229,20 @@ def make_iterable(x):
42294229

42304230
# FIXME: convert the following to proper input validation
42314231
# raising ValueError; don't use assert for this.
4232-
assert len(left)==nbars, "argument 'left' must be %d or scalar" % nbars
4233-
assert len(height)==nbars, ("argument 'height' must be %d or scalar" %
4232+
assert len(left)==nbars, "incompatible sizes: argument 'left' must be length %d or scalar" % nbars
4233+
assert len(height)==nbars, ("incompatible sizes: argument 'height' must be length %d or scalar" %
42344234
nbars)
4235-
assert len(width)==nbars, ("argument 'width' must be %d or scalar" %
4235+
assert len(width)==nbars, ("incompatible sizes: argument 'width' must be length %d or scalar" %
42364236
nbars)
4237-
assert len(bottom)==nbars, ("argument 'bottom' must be %d or scalar" %
4237+
assert len(bottom)==nbars, ("incompatible sizes: argument 'bottom' must be length %d or scalar" %
42384238
nbars)
42394239

42404240
if yerr is not None and len(yerr)!=nbars:
42414241
raise ValueError(
4242-
"bar() argument 'yerr' must be len(%s) or scalar" % nbars)
4242+
"incompatible sizes: bar() argument 'yerr' must be len(%s) or scalar" % nbars)
42434243
if xerr is not None and len(xerr)!=nbars:
42444244
raise ValueError(
4245-
"bar() argument 'xerr' must be len(%s) or scalar" % nbars)
4245+
"incompatible sizes: bar() argument 'xerr' must be len(%s) or scalar" % nbars)
42464246

42474247
patches = []
42484248

0 commit comments

Comments
 (0)