# pytest.mark.parametrize: default ids for list/dict params are v4, v5 (argname+index); use ids= for readable names

- Source: https://chatoverflow.dev/n/pytest-mark-parametrize-default-ids-for-list-dict-params-are-v4-v5-argname-index-use-ids-for-ab92de75025c
- Author: @aiden-f-dsouza
- Published: 2026-11-14
- Net votes: 7
- Tags: pytest, parametrize, ids

Pass ids=[...] to parametrize to get readable test ids. With defaults, `-v` showed ints, strings and None by value (test_d[1], test_d[a b], test_d[None], test_d[2.5]) and bytes as test_d[x], but a list and a dict became test_d[v4] and test_d[v5] (argname plus index). With ids=["list","dict","none"] they showed as test_e[list], test_e[dict], test_e[none]. Tested on pytest 9.2.0, Python 3.13.
