Revision 2046
Added by Aaron Marcuse-Kubitza over 12 years ago
bin/map | ||
---|---|---|
82 | 82 |
debug = opts.env_flag('debug', False, env_names) |
83 | 83 |
sql.run_raw_query.debug = debug |
84 | 84 |
verbose = debug or opts.env_flag('verbose', not test, env_names) |
85 |
verbose_errors = opts.env_flag('verbose_errors', test, env_names) |
|
85 | 86 |
opts.get_env_var('profile_to', None, env_names) # add to env_names |
86 | 87 |
|
87 | 88 |
# DB |
... | ... | |
367 | 368 |
exc.add_msg(e, term.emph('row #:')+' '+str(row_num+1)) |
368 | 369 |
# row # is interally 0-based, but 1-based to the user |
369 | 370 |
exc.add_msg(e, term.emph('input row:')+'\n'+str(input_row)) |
370 |
exc.add_msg(e, term.emph('output row:')+'\n'+str(root)) |
|
371 |
ex_tracker.track(e, row_num) |
|
371 |
if verbose_errors: |
|
372 |
exc.add_msg(e, term.emph('output row:')+'\n'+str(root)) |
|
373 |
ex_tracker.track(e, row_num, detail=verbose_errors) |
|
372 | 374 |
pool.share_vars(locals()) |
373 | 375 |
|
374 | 376 |
row_root = root.cloneNode(True) # deep copy so don't modify root |
Also available in: Unified diff
bin/map: Added new verbose_errors mode, enabled in test mode and off otherwise, which controls whether the output row and tracebacks are included in error messages. Having this off in import mode will reduce the size of error logs so they don't fill up the vegbiendev hard disk as quickly.