lxml-stubs icon indicating copy to clipboard operation
lxml-stubs copied to clipboard

type definition for _ErrorLog missing

Open svniemeijer opened this issue 2 years ago • 0 comments

I am using an error reporting approach similar to Example #1 on this page:

        except etree.DocumentInvalid as exc:
            for error in exc.error_log:
                logger.error(f"{error.filename}:{error.line}: {error.message}")

However, this gives:

error: "_ErrorLog" has no attribute "__iter__" (not iterable)  [attr-defined]

svniemeijer avatar Aug 10 '23 09:08 svniemeijer