bug? NoneType' object is not iterable from # Fix Issue #1028

5 views
Skip to first unread message

Dave

unread,
Jul 8, 2016, 6:54:11 PM7/8/16
to nikola-discuss

TaskError - taskid:render_archive:output/archives/2016/07/index-3.html
PythonAction Error
Traceback (most recent call last):
 
File "/home/usr/nikola/test/py_3.5.0/lib/python3.5/site-packages/doit/action.py", line 383, in execute
    returned_value
= self.py_callable(*self.args, **kwargs)
 
File "/home/usr/nikola/test/py_3.5.0/lib/python3.5/site-packages/nikola/nikola.py", line 1163, in render_template
   
self.rewrite_links(doc, src, context['lang'])
 
File "/home/usr/nikola/test/py_3.5.0/lib/python3.5/site-packages/nikola/nikola.py", line 1171, in rewrite_links
    doc
.rewrite_links(lambda dst: self.url_replacer(src, dst, lang), resolve_base_href=False)
 
File "/home/usr/nikola/test/py_3.5.0/lib/python3.5/site-packages/lxml/html/__init__.py", line 483, in rewrite_links
    new_link
= link_repl_func(link.strip())
 
File "/home/usr/nikola/test/py_3.5.0/lib/python3.5/site-packages/nikola/nikola.py", line 1171, in <lambda>
    doc
.rewrite_links(lambda dst: self.url_replacer(src, dst, lang), resolve_base_href=False)
 
File "/home/usr/nikola/test/py_3.5.0/lib/python3.5/site-packages/nikola/nikola.py", line 1209, in url_replacer
    dst
= self.link(dst_url.netloc, dst_url.path.lstrip('/'), lang)
 
File "/home/usr/nikola/test/py_3.5.0/lib/python3.5/site-packages/nikola/nikola.py", line 1499, in link
    url
= self.path(*args, is_link=True)
 
File "/home/usr/nikola/test/py_3.5.0/lib/python3.5/site-packages/nikola/nikola.py", line 1419, in path
    path
= [os.path.normpath(p) for p in path if p != '.']  # Fix Issue #1028
TypeError: 'NoneType' object is not iterable



not sure if you want possible bug submissions here, but this just came up, usually I would assume I have broken something, but the comment #fix issue #1028 made me think you might want to know



Chris Warrick

unread,
Jul 9, 2016, 4:32:00 AM7/9/16
to Nikola—Discuss
> --
> You received this message because you are subscribed to the Google Groups
> "nikola-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to nikola-discus...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

We’d prefer bug reports on GitHub. In file
/home/usr/nikola/test/py_3.5.0/lib/python3.5/site-packages/nikola/nikola.py,
before line 1418 (before `path` is defined for the first time), add:

print(kind, name, lang, self.path_handlers[kind])

and run

nikola build -v 2

Post the output here (or create a GitHub issue).

--
Chris Warrick <https://chriswarrick.com/>
PGP: 5EAAEA16
Reply all
Reply to author
Forward
0 new messages