diff --git a/OMPython/ModelicaSystem.py b/OMPython/ModelicaSystem.py index 570c7b43..37687d77 100644 --- a/OMPython/ModelicaSystem.py +++ b/OMPython/ModelicaSystem.py @@ -1800,7 +1800,7 @@ def linearize( ) if self._inputs: - for key, data in self._inputs.items(): + for data in self._inputs.values(): if data is not None: for value in data: if value[0] < float(self._simulate_options["startTime"]): diff --git a/OMPython/OMCSession.py b/OMPython/OMCSession.py index 1e2a5383..5ed0fd8d 100644 --- a/OMPython/OMCSession.py +++ b/OMPython/OMCSession.py @@ -171,8 +171,6 @@ def getClassComment(self, className): logger.warning("Method 'getClassComment(%s)' failed; OMTypedParser error: %s", className, ex.msg) return 'No description available' - except OMCSessionException: - raise def getNthComponent(self, className, comp_id): """ returns with (type, name, description) """ @@ -201,8 +199,6 @@ def getParameterNames(self, className): logger.warning('OMPython error: %s', ex) # FIXME: OMC returns with a different structure for empty parameter set return [] - except OMCSessionException: - raise def getParameterValue(self, className, parameterName): try: @@ -211,8 +207,6 @@ def getParameterValue(self, className, parameterName): logger.warning("Method 'getParameterValue(%s, %s)' failed; OMTypedParser error: %s", className, parameterName, ex.msg) return "" - except OMCSessionException: - raise def getComponentModifierNames(self, className, componentName): return self._ask(question='getComponentModifierNames', opt=[className, componentName])