Skip to content

Commit

Permalink
lazy extractors: Fix building with python2.6
Browse files Browse the repository at this point in the history
  • Loading branch information
jaimeMF committed Feb 21, 2016
1 parent eee1aca commit a4126fd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions devscripts/make_lazy_extractors.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class {name}(LazyLoadExtractor):
make_valid_template = '''
@classmethod
def _make_valid_url(cls):
return {!r}
return {valid_url!r}
'''


Expand All @@ -44,7 +44,7 @@ def build_lazy_ie(ie, name):
s += getsource(ie.suitable)
if hasattr(ie, '_make_valid_url'):
# search extractors
s += make_valid_template.format(ie._make_valid_url())
s += make_valid_template.format(valid_url=ie._make_valid_url())
return s

names = []
Expand All @@ -55,7 +55,7 @@ def build_lazy_ie(ie, name):
names.append(name)

module_contents.append(
'_ALL_CLASSES = [{}]'.format(', '.join(names)))
'_ALL_CLASSES = [{0}]'.format(', '.join(names)))

module_src = '\n'.join(module_contents)

Expand Down

0 comments on commit a4126fd

Please sign in to comment.