1
0
Fork 0
forked from github/pelican
pelican-theme/pelican
Steve Schwarz 8a6d96b289 pelican_import fix for bs4
Quick fix for this traceback:
$ pelican-import --wpfile ~/Downloads/mysite.wordpress.2013-02-24.xml 
Traceback (most recent call last):
  File "/Users/me/.virtualenvs/pelican/bin/pelican-import", line 8, in <module>
    load_entry_point('pelican==3.2', 'console_scripts', 'pelican-import')()
  File "/Users/me/.virtualenvs/pelican/src/pelican/pelican/tools/pelican_import.py", line 363, in main
    disable_slugs=args.disable_slugs or False)
  File "/Users/me/.virtualenvs/pelican/src/pelican/pelican/tools/pelican_import.py", line 238, in fields2pelican
    for title, content, filename, date, author, categories, tags, in_markup in fields:
  File "/Users/me/.virtualenvs/pelican/src/pelican/pelican/tools/pelican_import.py", line 37, in wp2fields
    if item.fetch('wp:status')[0].contents[0] == "publish":
TypeError: 'NoneType' object is not callable

I'm a BeautifulSoup novice but these changes allowed me to import two of my wordpress.xml files.
2013-03-03 21:17:42 -08:00
..
plugins update summary plugin so that tests are fixed (hopefully) 2013-03-01 12:59:26 +01:00
themes Strip tags from title in simple index. Fixes #612 2012-12-02 16:10:11 -08:00
tools pelican_import fix for bs4 2013-03-03 21:17:42 -08:00
__init__.py Manual pass on sources for better standards. 2013-03-03 20:12:31 -08:00
contents.py Manual pass on sources for better standards. 2013-03-03 20:12:31 -08:00
generators.py Don't overwrite output_path. Fix #750 2013-03-03 21:00:52 -08:00
log.py Manual pass on sources for better standards. 2013-03-03 20:12:31 -08:00
paginator.py Port pelican to python 3. 2013-01-11 03:20:09 +01:00
readers.py Manual pass on sources for better standards. 2013-03-03 20:12:31 -08:00
rstdirectives.py Port pelican to python 3. 2013-01-11 03:20:09 +01:00
server.py Manual pass on sources for better standards. 2013-03-03 20:12:31 -08:00
settings.py Manual pass on sources for better standards. 2013-03-03 20:12:31 -08:00
signals.py Add a pages_generator_finalized signal. 2013-02-10 12:42:54 -08:00
utils.py Manual pass on sources for better standards. 2013-03-03 20:12:31 -08:00
writers.py Manual pass on sources for better standards. 2013-03-03 20:12:31 -08:00