Opened 4 years ago

Closed 4 years ago

#3996 closed defect (fixed)

Error thrown in cms when generating static pages

Reported by: greiner Assignee: trev
Priority: P2 Milestone:
Module: Infrastructure Keywords:
Cc: trev, matze Blocked By:
Blocking: #3987 Platform: Unknown / Cross platform
Ready: yes Confidential: no
Tester: Unknown Verified working: no
Review URL(s):

Description (last modified by trev)


Ubuntu 14.04
Python 2.7.6
cms 407299178497

How to reproduce

  1. Try to generate static pages for revision 52f7df39b043 of

Observed behaviour

According to this comment the following error is thrown:

Traceback (most recent call last):
  File "/usr/lib/python2.7/", line 162, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/", line 72, in _run_code
    exec code in run_globals
  File "/opt/cms/cms/bin/", line 154, in <module>
    generate_pages(repo, output_dir)
  File "/opt/cms/cms/bin/", line 118, in generate_pages
    pagedata = process_page(source, locale, page)
  File "/opt/cms/cms/", line 91, in process_page
    site_url_override, localized_string_callback),
  File "/opt/cms/cms/", line 76, in get_page_params
    params["head"], params["body"] = converter()
  File "/opt/cms/cms/", line 283, in __call__
    result = self.resolve_includes(result)
  File "/opt/cms/cms/", line 278, in resolve_includes
  File "/usr/lib/python2.7/", line 151, in sub
    return _compile(pattern, flags).sub(repl, string, count)
  File "/opt/cms/cms/", line 266, in resolve_include
    result = converter()
  File "/opt/cms/cms/", line 282, in __call__
    result = self.get_html(*self._params[self._key])
  File "/opt/cms/cms/", line 334, in get_html
    result = md.convert(result)
  File "/usr/lib/python2.7/dist-packages/markdown/", line 280, in convert
    self.lines =
  File "/usr/lib/python2.7/dist-packages/markdown/", line 175, in run
    if self.markdown_in_raw and 'markdown' in attrs.keys():
AttributeError: 'tuple' object has no attribute 'keys'

This is which has been fixed in Markdown 2.2.0 - our servers are running the extremely outdated version 2.1.1 of this Python module however.

Expected behaviour

No errors are thrown and static pages are successfully created.

What to change

Update Markdown module on our servers.

Change History (8)

comment:1 Changed 4 years ago by greiner

  • Blocking 3987 added

comment:2 Changed 4 years ago by trev

Server is running version 2.1.1 of the markdown module which is rather old. This might be the reason.

comment:3 Changed 4 years ago by trev

  • Cc matze added
  • Component changed from Sitescripts to Infrastructure
  • Description modified (diff)

Indeed, this is (triggered by HTML comment) - fixed in version 2.2.0. I'd consider this an infrastructure issue then, we should update to a current version.

comment:4 Changed 4 years ago by trev

  • Owner set to trev

comment:5 Changed 4 years ago by trev

  • Review URL(s) modified (diff)
  • Status changed from new to reviewing

comment:6 Changed 4 years ago by matze

  • Priority changed from Unknown to P2
  • Ready set

comment:7 Changed 4 years ago by abpbot

A commit referencing this issue has landed:

comment:8 Changed 4 years ago by trev

  • Resolution set to fixed
  • Status changed from reviewing to closed


Note: See TracTickets for help on using tickets.