From: Guido van Rossum Date: Thu, 17 Aug 2006 09:10:09 +0000 (+0000) Subject: Use explicit relative import to make this work again. X-Git-Tag: v3.0a1~1400 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3b271054d7b2300d94f7f1bd3cb48d513d371c70;p=thirdparty%2FPython%2Fcpython.git Use explicit relative import to make this work again. --- diff --git a/Lib/xml/sax/__init__.py b/Lib/xml/sax/__init__.py index 6b1b1ba00712..054064c4a6cb 100644 --- a/Lib/xml/sax/__init__.py +++ b/Lib/xml/sax/__init__.py @@ -19,9 +19,9 @@ xmlreader -- Base classes and constants which define the SAX 2 API for expatreader -- Driver that allows use of the Expat parser with SAX. """ -from xmlreader import InputSource -from handler import ContentHandler, ErrorHandler -from _exceptions import SAXException, SAXNotRecognizedException, \ +from .xmlreader import InputSource +from .handler import ContentHandler, ErrorHandler +from ._exceptions import SAXException, SAXNotRecognizedException, \ SAXParseException, SAXNotSupportedException, \ SAXReaderNotAvailable diff --git a/Lib/xml/sax/saxutils.py b/Lib/xml/sax/saxutils.py index a4965192fa83..b5b9ff336273 100644 --- a/Lib/xml/sax/saxutils.py +++ b/Lib/xml/sax/saxutils.py @@ -4,8 +4,8 @@ convenience of application and driver writers. """ import os, urlparse, urllib, types -import handler -import xmlreader +from . import handler +from . import xmlreader try: _StringTypes = [types.StringType, types.UnicodeType] diff --git a/Lib/xml/sax/xmlreader.py b/Lib/xml/sax/xmlreader.py index 9a2361e349d0..1cade65fe0c7 100644 --- a/Lib/xml/sax/xmlreader.py +++ b/Lib/xml/sax/xmlreader.py @@ -1,9 +1,9 @@ """An XML Reader is the SAX 2 name for an XML parser. XML Parsers should be based on this code. """ -import handler +from . import handler -from _exceptions import SAXNotSupportedException, SAXNotRecognizedException +from ._exceptions import SAXNotSupportedException, SAXNotRecognizedException # ===== XMLREADER ===== @@ -113,7 +113,7 @@ class IncrementalParser(XMLReader): XMLReader.__init__(self) def parse(self, source): - import saxutils + from . import saxutils source = saxutils.prepare_input_source(source) self.prepareParser(source)