Section 9 Minor Enhancements and Bug Fixes

9.1 2023-03-AA Minor Enhancements and Bug Fixes

9.1.1 Geo-Referenced Messages

The following messages are now geo-referenced in the 2023-03 Release:

9.1.2 Error Message When No Start or End Time is Specified

The 2023-03 release will produce ERROR 2570 if the user has not specified a start or end time. Previously these would default to a start time of zero hours and an end time of one hour.

9.1.3 Warning When 1D_IWL is Used in TCF or TGC

The 2023-03 release will produce WARNING 2073 if a 1d_IWL point is read in through the .tcf or .tgc, indicating it needs to be read in as a 1D command.

9.1.4 Fixes Issue with Return Characters in GIS Attributes

The 2023-03 release fixes a bug that would cause a “Should not be here” when a carriage return was present in a GIS attribute value. This would cause TUFLOW to produce ERROR 2148, however also cause a “Should not be here” while writing the error to the message_P.shp layer. In the 2023-03 release the ERROR 2148 is now written cleanly to the messages_P.shp file.

9.1.5 Package Model Functionality Copies Matrix Blockage Files

The 2023-03 release now copies matrix blockage .csv files, previously these were not copied.

9.1.6 TCF now Closed at End of Model Initialisation

All TUFLOW control files (.tcf, .tgc, and .tbc) are opened by TUFLOW as read only, however, these may not have been closed till the end of the simulation which could interfere with some backup or version control software. For 2023-03-AA onwards these control files (.tcf, .tgc, .tbc) are closed at the end of model initialisation.

9.2 2023-03-AB Minor Enhancements and Bug Fixes

9.2.1 Ability to Set Hardware via Command Line Argument

Build 2023-03-AB introduces the ability to set the hardware via a command line argument. The syntax is -hwgpu or -hwcpu and this will overwrite any “Hardware == ” command specified in the .tcf. This can be used in conjunction with the -nt (number of threads) or -pu (processing unit id) to provide full control over the hardware usage via the command line.

The following command could be used to run a model with CPU hardware on 8 threads:

TUFLOW_iSP_w64.exe -b -hwcpu -nt8 FS_Hardware_01.tcf

The following command could be used to on GPU hardware using 2 devices (GPU 0 and GPU1):

TUFLOW_iSP_w64.exe -b -hwgpu -pu0 -pu1 FS_Hardware_01.tcf

9.2.2 Bug Fix for External 1D Engines

Build 2023-03-AB fixes an issue which could cause ERROR 2570 (missing start time or end time) from spuriously being output when linked with external 1D engines (12D, Flood Modeller, or XP-SWMM).

9.2.3 File Path Length Errors

Build 2023-03-AB will trigger an appropriate TUFLOW error and meaningful message if a file path length error is encountered. Previously this could cause TUFLOW to hang indefinitely.

9.2.4 Enhancement to Processing of Tabs

Build 2023-03-AB changes the processing of tab characters within control file commands. These are now replaced with a space character, previously these were deleted. For example:

Map Output Data Types == h → d → t

Was previously interpreted as:

Map Output Data Types == hdt

In this instance h (water level) and dt (variable timestep) would be output instead of h (water level), d (depth) and t (viscosity).

9.3 2023-03-AD Minor Enhancements and Bug Fixes

9.3.1 TUFLOW HPC Crashing While Writing Outputs Mid-Simulation with Reporting Locations

Build 2023-03-AD fixes a bug where TUFLOW could crash due to a stack overflow error while writing outputs mid-simulation (i.e. at a map output interval) when using reporting locations. This could occur very rarely and only for HPC. This crash could also potentially happen when using evacuation routes, structure groups, gauge receptors, and operational structures.

9.3.2 Bug Fix Using Local Coordinate Reference System with Shape Files

Build 2023-03-AD fixes a bug where TUFLOW could incorrectly throw “ERROR 0305 - Projection of .shp file is different to that specified by the SHP Projection == command” if a local coordinate system was used. This only occurred when using “SHP Projection Check Method == PARSED” (which is the default).

9.3.3 Bug Fix Writing ERROR 2551

Build 2023-03-AD fixes a bug where TUFLOW could crash while writing “ERROR 2551 - PO type SQ is invalid for a structure group, please use QS”.

9.3.4 Speed Up of Package Model Routine

It is possible for models to include the same files from multiple places causing multiple references in the Package Model routine. Build 2023-03-AD speeds up the model packaging by eliminating duplicate references and copying the files once. Previous versions would recopy the file for each reference after the first one.

9.4 2023-03-AF Minor Enhancements and Bug Fixes

9.4.1 Bug Fix When Double Spaces are Present in File Path References

Build 2023-03-AF fixes a bug that was introduced in the 2023-03-AA build where file path references that included two or more spaces in a row could cause the filename to be read incorrectly. Where this occurred, TUFLOW was incorrectly replacing these locations with a single space, which would cause a “file not found” error.

9.4.2 Bug Fix for ‘Illegal Storage Errors’ when Running Linked Flood Modeller-TUFLOW Models

Build 2023-03-AF fixes an issue that was introduced in the 2023-03-AD build where linked Flood Modeller-TUFLOW models could occasionally fail, seemingly randomly, due to indexing errors. The failures provided either a run-time error ‘severe (157): Program Exception - access violation error’ or an ‘Illegal storage access at time x.xxx hrs.’ error within the Flood Modeller ZZD diagnostics file. Often, rerunning the simulation overcame the issue.

9.4.3 Removal of Duplicate Message 2904

Build 2023-03-AF fixes an issue with two different messages being assigned the same message number (2904). The following message has been changed from ERROR 2904 to ‘ERROR 2913 - Dangerous word found in user SQL: (dangerous word)’.

9.4.4 Fix for Model TUFLOW Release

Build 2023-03-AF updates the “Model TUFLOW Release == ” comparison version to “2023-03” for 2023-03 builds prior to 2023-03-AF, TUFLOW was expecting 2020-10. If “Model TUFLOW Release == 2023-03” was specified then ERROR 0012 was spuriously reported.