Uh oh!
There was an error while loading. Please reload this page.
Incorrect isinstance(..., 'str') check, test _pyproject_toml - #413
Conversation
isinstance(readme, 'str') checkisinstance(..., 'str') checkIf I find more similarly obvious issues, I will create one PR for them to avoid flooding the PR here. |
hugovk
commented
Sep 15, 2025
Looks like we're missing tests for this bit of code. Would it be possible to add something? |
| def test_parse_project_with_readme_string(self): | ||
| with tempfile.TemporaryDirectory() as tmpdir: | ||
| tmp_path = pathlib.Path(tmpdir) | ||
| toml_content = """ |
There was a problem hiding this comment.
* main: Add `ruff format` to pre-commit, run it, except the benchmarks (python#410)
isinstance(..., 'str') checkisinstance(..., 'str') check, test _pyproject_tomlhugovk
commented
Sep 30, 2025
I think that's fine here.
Yeah, given the comment at the top of pyperformance/pyperformance/_pyproject_toml.py Lines 1 to 2 in 553aa5d |
Uh oh!
There was an error while loading. Please reload this page.
'str'is incorrect there:Reference: