Skip to content

Commit e6d818c

Browse files
Apply ruff/flynt rule FLY002
FLY002 Consider f-string instead of string join
1 parent 4cbb17e commit e6d818c

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/zarr/core/group.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -676,7 +676,7 @@ async def _members(
676676
async for child_key, val in obj._members(
677677
max_depth=max_depth, current_depth=current_depth + 1
678678
):
679-
yield "/".join([key, child_key]), val
679+
yield f"{key}/{child_key}", val
680680
except KeyError:
681681
# keyerror is raised when `key` names an object (in the object storage sense),
682682
# as opposed to a prefix, in the store under the prefix associated with this group

src/zarr/store/remote.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,6 +234,6 @@ async def list_prefix(self, prefix: str) -> AsyncGenerator[str, None]:
234234
AsyncGenerator[str, None]
235235
"""
236236

237-
find_str = "/".join([self.path, prefix])
237+
find_str = f"{self.path}/{prefix}"
238238
for onefile in await self.fs._find(find_str, detail=False, maxdepth=None, withdirs=False):
239239
yield onefile.removeprefix(find_str)

0 commit comments

Comments
 (0)