Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SyntaxError: unqualified exec is not allowed in function '__call__' it contains a nested function with free variables #75

Open
zopyx opened this issue May 16, 2018 · 2 comments

Comments

@zopyx
Copy link
Member

zopyx commented May 16, 2018

My Travis testrunner for zopyx.plone.persistentlogger suddenly fails with plone.protect 3.1.3:

https://travis-ci.org/zopyx/zopyx.plone.persistentlogger/jobs/379640548


odule: zopyx.plone.persistentlogger.tests.test_logger
Traceback (most recent call last):
  File "/home/travis/build/zopyx/zopyx.plone.persistentlogger/zopyx/plone/persistentlogger/tests/test_logger.py", line 12, in <module>
    from .base import TestBase
  File "/home/travis/build/zopyx/zopyx.plone.persistentlogger/zopyx/plone/persistentlogger/tests/base.py", line 11, in <module>
    import plone.api
  File "/home/travis/build/zopyx/zopyx.plone.persistentlogger/eggs/plone.api-1.8.3-py2.7.egg/plone/api/__init__.py", line 6, in <module>
    from plone.api import group
  File "/home/travis/build/zopyx/zopyx.plone.persistentlogger/eggs/plone.api-1.8.3-py2.7.egg/plone/api/group.py", line 7, in <module>
    from plone.api.user import get as user_get
  File "/home/travis/build/zopyx/zopyx.plone.persistentlogger/eggs/plone.api-1.8.3-py2.7.egg/plone/api/user.py", line 16, in <module>
    from Products.PlonePAS.interfaces.plugins import ILocalRolesPlugin
  File "/home/travis/build/zopyx/zopyx.plone.persistentlogger/eggs/Products.PlonePAS-5.0.15-py2.7.egg/Products/PlonePAS/__init__.py", line 18, in <module>
    from Products.PlonePAS.tools.membership import MembershipTool
  File "/home/travis/build/zopyx/zopyx.plone.persistentlogger/eggs/Products.PlonePAS-5.0.15-py2.7.egg/Products/PlonePAS/tools/membership.py", line 34, in <module>
    from plone.protect.interfaces import IDisableCSRFProtection
  File "/home/travis/build/zopyx/zopyx.plone.persistentlogger/eggs/plone.protect-3.1.3-py2.7.egg/plone/protect/__init__.py", line 6, in <module>
    from plone.protect.utils import protect
SyntaxError: unqualified exec is not allowed in function '__call__' it contains a nested function with free variables (utils.py, line 63)

@davisagli
Copy link
Member

See #74

@zopyx
Copy link
Member Author

zopyx commented May 16, 2018

The Python version here is 2.7.14

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants