Skip to content

Commit e5b416f

Browse files
committed
cleanup of ModelVariables
1 parent bfed876 commit e5b416f

File tree

1 file changed

+5
-10
lines changed

1 file changed

+5
-10
lines changed

idaes/core/util/structfs/runner_actions.py

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -384,15 +384,11 @@ def _extract_vars(self, m):
384384
continue # ignore other components
385385
# start new block
386386
b = [subtype]
387-
# add values
388-
# if isinstance(c, pyo.NumericValue):
389-
# b.append(False)
390-
# b.append([None, c.value])
391-
# else:
387+
# add its variables
392388
items = []
393389
indexed = False
394-
# add each value from an indexed var/param,
395-
# this also works ok for non-indexed ones
390+
# add each value from an indexed var/param,
391+
# this also works ok for non-indexed ones
396392
for index in c:
397393
v = c[index]
398394
indexed = index is not None
@@ -405,11 +401,10 @@ def _extract_vars(self, m):
405401
items.append(item)
406402
b.append(indexed)
407403
b.append(items)
408-
# add block to list
409-
# model_vars.append(b)
404+
# add block to tree
410405
self._add_block(var_tree, c.name, b)
411406

412-
self._vars = var_tree # {"components": model_vars}
407+
self._vars = var_tree
413408

414409
@staticmethod
415410
def is_var(c):

0 commit comments

Comments
 (0)