Skip to content

Commit f953e92

Browse files
PEP8 standard RET504 (#249)
1 parent d31b5e7 commit f953e92

File tree

3 files changed

+2
-5
lines changed

3 files changed

+2
-5
lines changed

pyproject.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,6 @@ lint.ignore = [
9090
# FIXME: those are ignored for now, should be fixed eventually
9191
"E501", # Ignore line too long
9292
"ERA001", # Found commented-out code
93-
"RET504", # Unnecessary assignment before `return`
9493
"T201", # `print` found"
9594
"SIM105", # Use `contextlib.suppress`
9695
"S110", # `try`-`except`-`pass` detected, consider logging the exception

src/petab_gui/models/pandas_table_model.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -245,8 +245,7 @@ def headerData(self, section, orientation, role=Qt.DisplayRole):
245245
section - self.column_offset
246246
]
247247
if role == Qt.ToolTipRole:
248-
tooltip_header = header_tip(self.table_type, col_label)
249-
return tooltip_header
248+
return header_tip(self.table_type, col_label)
250249
if role == Qt.WhatsThisRole:
251250
return column_whats_this(self.table_type, col_label)
252251
return col_label

src/petab_gui/models/sbml_model.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,5 +69,4 @@ def _get_model_id(self):
6969
"""Extract the model ID from the SBML text."""
7070
document = libsbml.readSBMLFromString(self.sbml_text)
7171
model = document.getModel()
72-
model_id = model.getIdAttribute() or "New_File"
73-
return model_id
72+
return model.getIdAttribute() or "New_File"

0 commit comments

Comments
 (0)