Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The rocoto_viewer script is updated to python3. In addition to making the necessary syntax updates like converting print statements into print functions (adding parentheses), this requried removing the dependency on produtils scripts (which are still in python2). This change will also make the script more portable. The largest chunk of changes to remove produtils revolves around making system calls to run rocoto. These are replaced with a simple wrapper function that calls subprocess, captures the output, and returns it as a string. This also allows for the streamlining of these portions of code. A fallback is added in case lxml is not available. This will only cause problems if lxml is not available and the user tries to read a workflow that uses external entities, in which case a message will be displayed notifying the user of the issue and providing instructions on how to install lxml with pip. A similar existing message for dateutil (used for UGCS's monthly increment) was updated similarly. Some incidental syntax updating and unused variable removal was done as they were encountered, but a more complete cleaning of these is still needed. Refs: #13, #14
- Loading branch information