CADSWES Maintenance Accomplishment Report Compilation -- October 2017
Phil Weinstein, edit 11-08-2017, initial writing in progress

October 2017 Maintenance Highlights:

  1. One Patch Release: 7.1.4 (10-17-2017)
  2. Fourteen (14) completed bug fixes.
  3. New CADSWES Linux Server, progress on Gnats bug tracking system.
  4. Ongoing: Monitoring and maintaining daily RiverWare regression tests.
  5. Ongoing: Installation Process and Licensing development and administration.

Report contributors:

(II) RiverWare Software Maintenance

  1. Releases, Patches and Snapshots
  2. Software Updates, Bug fixes (not associated with new development)
  3. Development tool improvements; issue tracking software; modelcomp
  4. Enhancements or changes to regression tests (not part of development tasks)
  5. Download, Install and Release Processes
  6. Updates to license software/procedures
  7. Updates to download/install/configure user documentation
  8. Modification to Web pages for downloads and installs

(II.A) Releases, Patches and Snapshots

The following release was generated this month:

Summary of Changes in RiverWare Patch Release 7.1.4

Bugs:
The following issues were addressed:

  • 5171 / 5203: The MRM input DMI repeat setting was not applied as expected in certain cases.
  • 5889: An internal error could occur within consecutive MRM.
  • 6000: The run time was reported incorrectly in the diagnostics output after stopping a run after Initialization only.
  • 6010: Within an Excel Database DMI, a NaN in Excel was imported as an integer.
  • 6013: The Apply Series Notes to slots did not always set the chosen note.
  • 6014: Within RPL, error messages for data type mismatch was not helpful.
  • 6017: A crash could occur when unloading RPL sets with a script.
  • 6020 / 6021: Deleting a slot or object and then using a plot could cause a crash.

(II.B) Software Updates, Bug fixes (not associated with new development)

The following fourteen bugs were fixed:

  1. Bug 5735: Typing value into Edit Account dialog reports errors.
  2. Bug 5866: DSS paired data
  3. Bug 5988: Deleting link to multislot with slot open fails assertion.
  4. Bug 6006: Object Viewer and Open Slot Issues (see also below).
  5. Bug 6014: Invalid function error message for data type mismatch is unhelpful
  6. Bug 6015: RPL Viewer - closing a rule also closes the rule to the right
  7. Bug 6016: 3D Table Interpolation issues warning with bad max value for 32-bit only
  8. Bug 6017: Crash when unloading RPL sets with a script
  9. Bug 6018: Excel and table series slot row labels
  10. Bug 6020: Crash opening Plot dialog when slots in plots have been deleted.
  11. Bug 6021: Crash when scaling a Plot that includes slots from a deleted object.
  12. Bug 6023: Investigation: Crash with large memory usage from numerous diagnostic messages (see also below).
  13. Bug 6024: Issues with Water Balance (see also below).
  14. Bug 6025: Add Text and Add Image dialogs open on the upper left corner.

Remove Slot Dialog Creation and Management from Open Object Dialogs / Bug 6006

In RiverWare 7.2, the life-cycle of Slot Dialogs is no longer tied to the parent simulation object's Open Object Dialog. Slot Dialogs will no longer be closed when the Object Viewer or associated Object Dialog is closed. There was a lot to this change, as the life-cycle of Slot Dialogs has been very fundamentally based on a legacy parent/child dialog mechanism involving a lot of interaction between the dialogs and dialog managers.

In order to more directly address Bug 6006, we had initially experimented with deleting and recreating Slot Dialogs as their slot's containing simulation objects were moved between the new Object Viewer and single-object Open Object dialogs. That was somewhat successful, but some user interface state information was lost when Slot Dialogs were recreated (e.g. the vertical, time, scroll position). Separating out the management of Slot Dialogs was a broader way of addressing the problems described in Bug 6006.

Investigation: Crash with large memory usage from numerous diagnostic messages / Bug 6023

When a model with many slots and many timesteps has informational diagnostics enabled for all slots, millions of diagnostic messages may be generated.  As a result, RiverWare crashes when allocating memory for the data structure that holds the messages.

Two items were investigated: 1) Why does RiverWare crash when the memory usage is not yet at the machine limit, and 2) What can we do to show a warning message and exit gracefully before a crash like this occurs.

Item 1: RiverWare is adding a large chunk of messages all at the same time to the diagnostic window during a run state called INIT_SUSPENDED.  In order to do this, Qt must resize the QVector (internal to QTreeView) that holds the messages.  QVector requires contiguous memory and if there is no available chunk of contiguous memory, Qt throws a fatal error.  While current memory use is not yet at the machine limit, the request for a large contiguous amount of memory fails because the contiguous space is not available.

Item 2: A possible way to prevent the crash might be to use a configurable max number of diagnostic messages with a default of, say, one million.  If this threshold is detected, RiverWare would stop displaying diagnostic messages and present a pop-up window indicating the max number of diagnostic messages has been reached and that no more would be written.  This would allow the run to continue.

Maintain Mass Balance Summary slot references through name changes / Bug 6024

In RiverWare 7.1 and prior versions, changes to the names of any slots referenced from a Mass Balance Summary Slot (including changes to the names of containing SimObjs and Accounts) did not result in updating those slot references. Those broken slot references resulted in errors being reported when the Mass Balance Summary Slot was evaluated. (See Bug 6024).

In most other places in RiverWare, slot references are represented with "live" C++ pointers to Slot data structures. In that context, the only thing that needs to be done when a slot is renamed is updating the user interface. But slot references from Mass Balance Summary Slots are maintained as character strings (the full name of the referenced slot). So, the Mass Balance Summary Slot's slot references need to be explicitly updated -- whether or not the Mass Balance Summary Slot is being shown in the user interface. (The user interface also needs to be updated). This was completed for RiverWare 7.2.

Move method rwSetting::resolveSymbolicDateTime to a more appropriate location.

During the project to introduce symbolic dates to expression slots, it came to light that a utility method designed to resolve date strings was residing within the rwSettings class.  This location was not appropriate for a date-time utility method, and the method was relocated to the Date_Time class.  Related code changes were made within the DateTimeQtSpinner, SlotQtDialog, Workspace, UberSymbolDateTimeEdit, RplApplication, ModelReportItem, and Slot classes.

RiverWare Software Maintenance / FY 2017 Report

A report draft summarizing all CADSWES maintenance work for FY 2017 (Oct. 2016 through Sept. 2017) was prepared. This document is available here:

(II.C) Development tool improvements; issue tracking software; modelcomp

New CADSWES Linux Server

CADSWES bug tracking system (for RiverWare, RiverWISE and RiverSMART) is a collection of home grown Perl scripts running from an Apache web server on the front end and the Gnats bug tracking system on the back end. The Perl scripts:

The Perl scripts are intended to be run from a web server but can be run from the command line, provided the forms they’re creating are relatively simple.

The bug tracking system is being ported from the current Linux server, Alamosa, to the new Linux server, Animas. The port includes four components:

All four components have been problematic during the port, unfortunately the first component is the only one where we can fix problems. The others require that we email the CU Office of Information Technology (OIT) and wait – sometimes hours, sometimes days – for the current problem to be fixed.

In October we were able to accomplish the following in this difficult environment:

The discrepancy in the second bullet item is because from the web server scripts run as the pseudo-user "apache" while from the command line scripts run as the currently logged in user. SELinux has different access control security policies for the different users, hence the different behaviors.

(II.D) Enhancements or changes to regression tests (not part of development tasks)

The regression tests continue to be maintained on a daily basis. This involves updating the regression tests to exercise new developments in the code. Also, as new code is added to the development area, the model comparisons performed in the nightly regression tests usually show differences (for example, because a new method category may have been added). When this occurs, the regression tests need to be updated to reflect the current state of the development area so model comparisons do not fail. In addition, every week, the daily history of each regression test is analyzed to determine if the run time or model size has significantly changed because of new development.

In October,

(II.E) Download, Install and Release Processes

(II.F) Updates to license software/procedures

(II.G) Updates to download/install/configure user documentation

(II.H) Modification to Web pages for downloads and installs

None reported for October 2017.

--- (end) ---