Opened 18 years ago

Closed 18 years ago

#142 closed defect (fixed)

small change in Data_manager that needs to be checked

Reported by: nick Owned by: Duncan
Priority: normal Milestone:
Component: Functionality and features Version: 1.0
Severity: minor Keywords:
Cc:

Description

Hi Dunc

This is tiny... But for some reason I was getting this error


nbartzis@cyclone:~/anuga/anuga_validation/automated_validation_tests/urs_mux_files_validation$ python validate_Bf.py

test_compare_URSsww_vs_EvolveANUGAsww (main.Test_Bf) ... Traceback (most recent call last):

File "run_Bf.py", line 99, in ?

fail_on_NaN= False)

File "/d/cit/1/cit/unixhome/nbartzis/anuga/anuga_core/source/anuga/shallow_water/data_manager.py", line 3891, in urs2sww

verbose=verbose)

File "/d/cit/1/cit/unixhome/nbartzis/anuga/anuga_core/source/anuga/shallow_water/data_manager.py", line 2754, in ferret2sww

print ' Start time: %f' %starttime

NameError?: global name 'starttime' is not defined


when i ran this code


urs2sww(boundaries_dir_name,boundaries_dir_name, mint=9200, maxt= 11200,

fail_on_NaN= False, verbose=True)


I changed data_manager.py line 2754 from

print ' Start time: %f' %starttime

to

print ' Start time: %f' %mint

# print ' Start time: %f' %starttime

i did have a look in the log for 'data_manager.py' to see if there were any changes and why but couldn't find anything

Question: Is this change Ok (all the tests still pass)? and do you know why this problem occured?

Can you review this asap?

Cheers Nick

Change History (1)

comment:1 Changed 18 years ago by Duncan <duncan@…>

  • Resolution set to fixed
  • Status changed from new to closed

I changed the code so it's ok.

This occurred since code in verbose sections is not unit tested.

I'm looking at setting up tests so the verbose section can be tested as well.

Note: See TracTickets for help on using tickets.