Skip to content

Commit 70a52ec

Browse files
committed
Fallback to get a fixture name
Not really getting anything useful from crashing there. It's an ugly crash that should be caught somewhere else.
1 parent 4d4f160 commit 70a52ec

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

eth/tools/fixtures/generation.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,11 @@ def idfn(fixture_params: Iterable[Any]) -> str:
2525
"""
2626
Function for pytest to produce uniform names for fixtures.
2727
"""
28-
return ":".join(str(item) for item in fixture_params)
28+
try:
29+
return ":".join(str(item) for item in fixture_params)
30+
except TypeError:
31+
# In case params are not iterable for some reason...
32+
return str(fixture_params)
2933

3034

3135
def get_fixtures_file_hash(all_fixture_paths: Iterable[str]) -> str:

0 commit comments

Comments
 (0)