You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I'm using FixtureRequest and it's associated param value when writing tests. When I run pytest file_name.py I get the following error message: AttributeError: type object 'FixtureRequest' has no attribute 'param'. I believe this is because I am type-hinting with FixtureRequest.param. I saw the notes from #10133 on using when parameterizing fixtures, which I believe I am doing here (let me know if not!). See the code block below to understand how I am using it and the screenshot for my pytest version/pip list output. Thank you!
a detailed description of the bug or problem you are having
output of pip list from the virtual environment you are using
I don't quite follow what your goal is with that annotation, but indeed FixtureRequest.param does not exist at runtime and it doesn't make sense to use as a type annotation. Something like Iterator[Tuple[str, str]] would probably be the correct thing to use.
Hello, I'm using
FixtureRequest
and it's associatedparam
value when writing tests. When I runpytest file_name.py
I get the following error message:AttributeError: type object 'FixtureRequest' has no attribute 'param'
. I believe this is because I am type-hinting withFixtureRequest.param
. I saw the notes from #10133 on using when parameterizing fixtures, which I believe I am doing here (let me know if not!). See the code block below to understand how I am using it and the screenshot for my pytest version/pip list
output. Thank you!pip list
from the virtual environment you are usingCode block:
pip list
output:My env:
macOS-13.4
Python 3.8.17
The text was updated successfully, but these errors were encountered: