diff --git a/wflow-py/_version.py b/wflow-py/_version.py index f7f78077..9ccdd41e 100644 --- a/wflow-py/_version.py +++ b/wflow-py/_version.py @@ -1,4 +1,4 @@ -# This file is made by mkversion_buildserver.py, do not edit!VERSION="1.0.master.1" +# This file is made by mkversion.py, do not edit!VERSION="1.0.master.1" MVERSION="1.0.master" NVERSION="1.0.1" -BUILD="2017-06-01 15:37:12.049000" +BUILD="2017-06-13 10:10:58.703000" diff --git a/wflow-py/make_wflow_exe_cx.py b/wflow-py/make_wflow_exe_cx.py index 55b895c2..d6ca43d2 100644 --- a/wflow-py/make_wflow_exe_cx.py +++ b/wflow-py/make_wflow_exe_cx.py @@ -121,8 +121,6 @@ def mkdatatuples(thelist,destdir="."): data_files.extend(mkdatatuples(MKL_files,destdir=".")) # pcraster dll's ddir = "c:/pcraster/lib/" - # for teamcity - ddir = "D:/BuildAgent/work/wflow_exe/pcraster-4.1.0_x86-64" data_files.extend(mkdatatuples(glob.glob(ddir + "/*.dll"),destdir='.')) # GDAL data files diff --git a/wflow-py/wflow/__init__.py b/wflow-py/wflow/__init__.py index 30f8dc1f..02c3f907 100644 --- a/wflow-py/wflow/__init__.py +++ b/wflow-py/wflow/__init__.py @@ -2,21 +2,15 @@ __version__="1.0.master" __release__="1.0.master.1" __versionnr__="1.0.1" -__build__="2017-06-01 15:37:12.049000" +__build__="2017-06-13 10:10:58.703000" +import osgeo.gdal as gdal + import os, sys if hasattr(sys, "frozen"): - print('Frozen...') _ROOT = os.path.abspath(os.path.dirname(__file__)).split("library.zip")[0] os.environ['GDAL_DATA'] = os.path.join(_ROOT,'gdal-data') - os.environ['PATH'] = _ROOT + ';' + os.environ['PATH'] - os.environ['PYTHONPATH'] = _ROOT + ';' + os.environ['PYTHONPATH'] - sys.path.insert(0,_ROOT) - if _ROOT not in os.environ['PATH']: - print('Root dir of binary not insystem path. This may cause problems...') else: _ROOT = os.path.abspath(os.path.dirname(__file__)) -import osgeo.gdal as gdal - def get_data(path): return os.path.join(_ROOT, 'data', path) diff --git a/wflow-py/wflow/wf_DynamicFramework.py b/wflow-py/wflow/wf_DynamicFramework.py index cad312df..a07f3d5e 100644 --- a/wflow-py/wflow/wf_DynamicFramework.py +++ b/wflow-py/wflow/wf_DynamicFramework.py @@ -927,7 +927,7 @@ def createRunId(self, intbl="intbl", logfname="wflow.log", NoOverWrite=True, mod self.modelname = modelnamefromobject if modelnamefromobject != self.modelname: - self.logger.error("Ini file made for " + self.modelname + " but found " + modelnamefromobject + " in code.") + self.logger.warn("Ini file made for " + self.modelname + " but found " + modelnamefromobject + " in code.") self.runlengthdetermination = configget(self._userModel().config, 'run', 'runlengthdetermination', "steps") self.DT.update(timestepsecs=int(configget(self._userModel().config, 'run', 'timestepsecs', "86400")), @@ -2113,7 +2113,6 @@ def _runDynamic(self, firststep, laststep): while step <= self._userModel().nrTimeSteps(): self._incrementIndentLevel() self._atStartOfTimeStep(step) - # TODO: Check why the timestep setting doesn't work..... self._userModel()._setCurrentTimeStep(step) if hasattr(self._userModel(), 'dynamic'): @@ -2424,7 +2423,10 @@ def wf_readmap(self, name, default, verbose=True,fail=False,ncfilesource="not se if hasattr(self._userModel(), "_inDynamic"): if self._userModel()._inDynamic() or self._inUpdateWeight(): timestep = self._userModel().currentTimeStep() - newName = generateNameT(name, timestep) + if 'None' not in self.ncfile: + newName = name + else: + newName = generateNameT(name, timestep) if style == 1: # Normal reading of mapstack from DISK per via or via netcdf path = os.path.join(directoryPrefix, newName)