TST: update pre-commit config to only exclude extension from bare pytest.raises check (#38973)
TST: update pre-commit config to only exclude extension from bare pytest.raises check (#38973)

Co-authored-by: Marco Gorelli <6db2da83a2d1aabf2ecda2acf5ab66b030b8d1ef@protonmail.com>
pandas-dev/pandas,dsm054/pandas,rs2/pandas,gfyoung/pandas,jorisvandenbossche/pandas,gfyoung/pandas,gfyoung/pandas,rs2/pandas,pandas-dev/pandas,jorisvandenbossche/pandas,jorisvandenbossche/pandas,dsm054/pandas,gfyoung/pandas,gfyoung/pandas,pandas-dev/pandas,rs2/pandas,datapythonista/pandas,dsm054/pandas,datapythonista/pandas,pandas-dev/pandas,rs2/pandas,dsm054/pandas,jorisvandenbossche/pandas,datapythonista/pandas,dsm054/pandas,datapythonista/pandas