From 9297e65eac6dd8e97a8739b1c4419db74f9cb03d Mon Sep 17 00:00:00 2001 From: Graham Higgins Date: Fri, 24 Dec 2021 16:49:49 +0000 Subject: [PATCH] Fix `self.line` typos in call to BadSyntax. Fix for issue #821 Invalid URI crashes without BadSyntax error --- rdflib/plugins/parsers/notation3.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rdflib/plugins/parsers/notation3.py b/rdflib/plugins/parsers/notation3.py index 2bd856887..64e4a7f04 100755 --- a/rdflib/plugins/parsers/notation3.py +++ b/rdflib/plugins/parsers/notation3.py @@ -1362,7 +1362,7 @@ def qname(self, argstr, i, res): if c not in escapeChars: raise BadSyntax( self._thisDoc, - self.line, + self.lines, argstr, i, "illegal escape " + c, @@ -1374,7 +1374,7 @@ def qname(self, argstr, i, res): ): raise BadSyntax( self._thisDoc, - self.line, + self.lines, argstr, i, "illegal hex escape " + c, @@ -1386,7 +1386,7 @@ def qname(self, argstr, i, res): if lastslash: raise BadSyntax( - self._thisDoc, self.line, argstr, i, "qname cannot end with \\" + self._thisDoc, self.lines, argstr, i, "qname cannot end with \\" ) if argstr[i - 1] == ".":