Skip to content

Commit a69c1b8

Browse files
committed
Address @jsiirola 's comments and apply black
1 parent ee92b70 commit a69c1b8

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

Diff for: pyomo/network/foqus_graph.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -359,8 +359,8 @@ def scc_calculation_order(self, sccNodes, ie, oe):
359359
for i in range(len(sccNodes)):
360360
for j in range(len(sccNodes)):
361361
for in_e in ie[i]:
362-
for oute in oe[j]:
363-
if in_e == oute:
362+
for out_e in oe[j]:
363+
if in_e == out_e:
364364
adj[j].append(i)
365365
adjR[i].append(j)
366366
done = True

Diff for: pyomo/solvers/plugins/solvers/GAMS.py

+6-2
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,9 @@ def solve(self, *args, **kwds):
349349
# Always name working directory or delete files,
350350
# regardless of any errors.
351351
if keepfiles:
352-
print("\nGAMS WORKING DIRECTORY: %s\n" % workspace.working_directory)
352+
print(
353+
"\nGAMS WORKING DIRECTORY: %s\n" % workspace.working_directory
354+
)
353355
elif tmpdir is not None:
354356
# Garbage collect all references to t1.out_db
355357
# So that .gdx file can be deleted
@@ -398,7 +400,9 @@ def solve(self, *args, **kwds):
398400
extract_rc = 'rc' in model_suffixes
399401

400402
results = SolverResults()
401-
results.problem.name = os.path.join(workspace.working_directory, t1.name + '.gms')
403+
results.problem.name = os.path.join(
404+
workspace.working_directory, t1.name + '.gms'
405+
)
402406
results.problem.lower_bound = t1.out_db["OBJEST"].find_record().value
403407
results.problem.upper_bound = t1.out_db["OBJEST"].find_record().value
404408
results.problem.number_of_variables = t1.out_db["NUMVAR"].find_record().value

0 commit comments

Comments
 (0)