From f68c50acc514d46eb9ab078ff932fc6fe0f635d6 Mon Sep 17 00:00:00 2001 From: jbrockmendel Date: Thu, 21 Nov 2019 15:07:01 -0800 Subject: [PATCH] CLN: catch ValueError instead of Exceeption --- pandas/io/html.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pandas/io/html.py b/pandas/io/html.py index ed2b21994fdca..5f38f866e1643 100644 --- a/pandas/io/html.py +++ b/pandas/io/html.py @@ -896,7 +896,7 @@ def _parse(flavor, io, match, attrs, encoding, displayed_only, **kwargs): try: tables = p.parse_tables() - except Exception as caught: + except ValueError as caught: # if `io` is an io-like object, check if it's seekable # and try to rewind it before trying the next parser if hasattr(io, "seekable") and io.seekable():