Show More
@@ -316,22 +316,22 b' def gettimer(ui, opts=None):' | |||
|
316 | 316 | limitspec = ui.configlist(b"perf", b"run-limits", []) |
|
317 | 317 | limits = [] |
|
318 | 318 | for item in limitspec: |
|
319 | parts = item.split('-', 1) | |
|
319 | parts = item.split(b'-', 1) | |
|
320 | 320 | if len(parts) < 2: |
|
321 | ui.warn(('malformatted run limit entry, missing "-": %s\n' | |
|
321 | ui.warn((b'malformatted run limit entry, missing "-": %s\n' | |
|
322 | 322 | % item)) |
|
323 | 323 | continue |
|
324 | 324 | try: |
|
325 | time_limit = float(parts[0]) | |
|
325 | time_limit = float(pycompat.sysstr(parts[0])) | |
|
326 | 326 | except ValueError as e: |
|
327 | ui.warn(('malformatted run limit entry, %s: %s\n' | |
|
328 | % (e, item))) | |
|
327 | ui.warn((b'malformatted run limit entry, %s: %s\n' | |
|
328 | % (pycompat.bytestr(e), item))) | |
|
329 | 329 | continue |
|
330 | 330 | try: |
|
331 | run_limit = int(parts[1]) | |
|
331 | run_limit = int(pycompat.sysstr(parts[1])) | |
|
332 | 332 | except ValueError as e: |
|
333 | ui.warn(('malformatted run limit entry, %s: %s\n' | |
|
334 | % (e, item))) | |
|
333 | ui.warn((b'malformatted run limit entry, %s: %s\n' | |
|
334 | % (pycompat.bytestr(e), item))) | |
|
335 | 335 | continue |
|
336 | 336 | limits.append((time_limit, run_limit)) |
|
337 | 337 | if not limits: |
@@ -260,7 +260,8 b' error case are ignored' | |||
|
260 | 260 | malformatted run limit entry, missing "-": 500 |
|
261 | 261 | ! wall * comb * user * sys * (best of 5) (glob) |
|
262 | 262 | $ hg perfparents --config perf.stub=no --config perf.run-limits='aaa-12, 0.000000001-5' |
|
263 | malformatted run limit entry, could not convert string to float: aaa: aaa-12 | |
|
263 | malformatted run limit entry, could not convert string to float: aaa: aaa-12 (no-py3 !) | |
|
264 | malformatted run limit entry, could not convert string to float: 'aaa': aaa-12 (py3 !) | |
|
264 | 265 | ! wall * comb * user * sys * (best of 5) (glob) |
|
265 | 266 | $ hg perfparents --config perf.stub=no --config perf.run-limits='12-aaaaaa, 0.000000001-5' |
|
266 | 267 | malformatted run limit entry, invalid literal for int() with base 10: 'aaaaaa': 12-aaaaaa |
General Comments 0
You need to be logged in to leave comments.
Login now