Skip to content

Commit

Permalink
Fix new E721 and F811 errors from ruff 0.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
nsoranzo committed Jul 3, 2024
1 parent cb61230 commit e61f2e8
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 4 deletions.
1 change: 0 additions & 1 deletion lib/galaxy/datatypes/genetics.py
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,6 @@ def regenerate_primary_file(self, dataset: DatasetProtocol) -> None:
]
for fname in flist:
sfname = os.path.split(fname)[-1]
f, e = os.path.splitext(fname)
rval.append(f'<li><a href="{sfname}">{sfname}</a></li>')
rval.append("</ul></body></html>")
with open(dataset.get_file_name(), "w") as f:
Expand Down
1 change: 0 additions & 1 deletion lib/galaxy/datatypes/spaln.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,6 @@ def regenerate_primary_file(self, dataset: DatasetProtocol) -> None:
]
for fname in flist:
sfname = os.path.split(fname)[-1]
f, e = os.path.splitext(fname)
rval.append(f'<li><a href="{sfname}">{sfname}</a></li>')
rval.append("</ul></body></html>")
with open(dataset.get_file_name(), "w") as f:
Expand Down
4 changes: 3 additions & 1 deletion lib/galaxy/web_stack/message.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,9 @@ def _merge_class_tuples(self):
names = set()
for cls in reversed(self.__class__.mro()):
names.update(
[x for x in dir(cls) if x.startswith("_") and not x.startswith("__") and type(getattr(cls, x)) == tuple]
x
for x in dir(cls)
if x.startswith("_") and not x.startswith("__") and type(getattr(cls, x)) == tuple # noqa: E721
)
for name in names:
setattr(self.__class__, name.lstrip("_"), property(lambda self, name=name: self._get_list_from_mro(name)))
Expand Down
1 change: 0 additions & 1 deletion test/unit/data/model/test_model_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -1215,7 +1215,6 @@ def import_archive(archive_path, app, user, import_options=None):
dest_dir = CompressedFile(archive_path).extract(dest_parent)

import_options = import_options or store.ImportOptions()
new_history = None
model_store = store.get_import_model_store_for_directory(
dest_dir,
app=app,
Expand Down

0 comments on commit e61f2e8

Please sign in to comment.