Skip to content

Broken with current Chameleon #2

Closed

Description

@jamadden

All 13 Tests fail with the same error:

======================================================================
ERROR: test_translation (z3c.ptcompat.tests.HTMLTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "///lib/python2.7/site-packages/zope/pagetemplate/tests/test_htmltests.py", line 135, in test_translation
    out = t(msg=msg)
  File "////lib/python2.7/site-packages/zope/pagetemplate/pagetemplate.py", line 110, in __call__
    return self.pt_render(self.pt_getContext(args, kwargs))
  File "///lib/python2.7/site-packages/zope/pagetemplate/pagetemplate.py", line 128, in pt_render
    raise PTRuntimeError(str(self._v_errors))
PTRuntimeError: ['Compilation failed', "exceptions.AttributeError: 'NoneType' object has no attribute 'rfind'"]

This leads to downsteam test failures in z3c.template

Activity

  1. jamadden commented on Oct 16, 2017

    @jamadden
    MemberAuthor

    Underlying error is

    Traceback (most recent call last):
      File "//z3c.template/.tox/py27/lib/python2.7/site-packages/zope/pagetemplate/pagetemplate.py", line 229, in _cook
        source_file, self._text, pt_engine, self.content_type)
      File "//z3c.template/.tox/py27/lib/python2.7/site-packages/z3c/ptcompat/engine.py", line 52, in cook
        text, filename=source_file, keep_body=True,
      File "//z3c.template/.tox/py27/lib/python2.7/site-packages/chameleon/zpt/template.py", line 192, in __init__
        super(PageTemplate, self).__init__(body, **config)
      File "//z3c.template/.tox/py27/lib/python2.7/site-packages/chameleon/template.py", line 116, in __init__
        self.write(body)
      File "//z3c.template/.tox/py27/lib/python2.7/site-packages/chameleon/template.py", line 209, in write
        self.cook(body)
      File "//z3c.template/.tox/py27/lib/python2.7/site-packages/chameleon/template.py", line 145, in cook
        digest = self.digest(body, names)
      File "//z3c.template/.tox/py27/lib/python2.7/site-packages/chameleon/zpt/template.py", line 304, in digest
        hex = super(PageTemplate, self).digest(body, names)
      File "//z3c.template/.tox/py27/lib/python2.7/site-packages/chameleon/template.py", line 246, in digest
        digest = os.path.splitext(self.filename)[0] + '-' + digest
      File "//z3c.template/.tox/py27/bin/../lib/python2.7/posixpath.py", line 98, in splitext
        return genericpath._splitext(p, sep, altsep, extsep)
      File "//z3c.template/.tox/py27/bin/../lib/python2.7/genericpath.py", line 99, in _splitext
        sepIndex = p.rfind(sep)
    AttributeError: 'NoneType' object has no attribute 'rfind'
    
  2. added a commit that references this issue on Oct 16, 2017
    676adb5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions