Commit 3261fef
authored
fix(SU2_PY, SU2_CFD): Python 3 compatibility and C++ code quality improvements (#2643)
Python fixes:
- Replace deprecated .iteritems() with .items() in bunch.py,
ordered_bunch.py
- Replace deprecated .itervalues() with .values() in ordered_dict.py
- Replace keys().sort() with sorted(keys()) in bunch.py as
dict.keys() returns a view object in Python 3
- Replace unicode type with str in data.py (unicode was merged
into str in Python 3)
- Replace 'raise StopIteration' with 'return' in switch.py
(PEP 479: raising StopIteration inside a generator is deprecated
in Python 3.7+ and causes RuntimeError)
C++ fixes:
- Remove redundant '== true' boolean comparison in
CSpeciesFlameletSolver.cpp (line 443)
These changes ensure the SU2 Python utilities work correctly with
Python 3.x and improve C++ code quality.
Signed-off-by: shbhmexe <[email protected]>1 parent 2c0049f commit 3261fef
File tree
6 files changed
+11
-13
lines changed- SU2_CFD/src/solvers
- SU2_PY/SU2
- io
- util
6 files changed
+11
-13
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
440 | 440 | | |
441 | 441 | | |
442 | 442 | | |
443 | | - | |
| 443 | + | |
444 | 444 | | |
445 | 445 | | |
446 | 446 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
359 | 359 | | |
360 | 360 | | |
361 | 361 | | |
362 | | - | |
| 362 | + | |
363 | 363 | | |
364 | 364 | | |
365 | 365 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
194 | 194 | | |
195 | 195 | | |
196 | 196 | | |
197 | | - | |
198 | | - | |
| 197 | + | |
199 | 198 | | |
200 | 199 | | |
201 | 200 | | |
202 | 201 | | |
203 | 202 | | |
204 | | - | |
205 | | - | |
| 203 | + | |
206 | 204 | | |
207 | 205 | | |
208 | 206 | | |
| |||
247 | 245 | | |
248 | 246 | | |
249 | 247 | | |
250 | | - | |
| 248 | + | |
251 | 249 | | |
252 | 250 | | |
253 | 251 | | |
| |||
273 | 271 | | |
274 | 272 | | |
275 | 273 | | |
276 | | - | |
| 274 | + | |
277 | 275 | | |
278 | 276 | | |
279 | 277 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
265 | 265 | | |
266 | 266 | | |
267 | 267 | | |
268 | | - | |
| 268 | + | |
269 | 269 | | |
270 | 270 | | |
271 | 271 | | |
| |||
291 | 291 | | |
292 | 292 | | |
293 | 293 | | |
294 | | - | |
| 294 | + | |
295 | 295 | | |
296 | | - | |
| 296 | + | |
297 | 297 | | |
298 | 298 | | |
299 | 299 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
88 | | - | |
| 88 | + | |
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
41 | | - | |
| 41 | + | |
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
| |||
0 commit comments