use absolute imports for compatibility with python 2.5

This commit is contained in:
Pablo Hoffman 2010-10-26 16:37:16 -02:00
parent 41a85f9d14
commit a09dd18bbb
1 changed files with 6 additions and 6 deletions

View File

@ -11,11 +11,11 @@ lxml will be used.
from scrapy.conf import settings
if settings['SELECTORS_BACKEND'] == 'lxml':
from .lxmlsel import *
from scrapy.selector.lxmlsel import *
elif settings['SELECTORS_BACKEND'] == 'libxml2':
from .libxml2sel import *
from scrapy.selector.libxml2sel import *
elif settings['SELECTORS_BACKEND'] == 'dummy':
from .dummysel import *
from scrapy.selector.dummysel import *
else:
try:
import libxml2
@ -23,8 +23,8 @@ else:
try:
import lxml
except ImportError:
from .dummysel import *
from scrapy.selector.dummysel import *
else:
from .lxmlsel import *
from scrapy.selector.lxmlsel import *
else:
from .libxml2sel import *
from scrapy.selector.libxml2sel import *