Skip to content

Commit

Permalink
- next round
Browse files Browse the repository at this point in the history
  • Loading branch information
dataflake committed Mar 19, 2019
1 parent 71d4441 commit c5962da
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 11 deletions.
3 changes: 1 addition & 2 deletions src/OFS/interfaces.py
Expand Up @@ -13,12 +13,11 @@
"""OFS interfaces.
"""

from persistent.interfaces import IPersistent

from AccessControl.interfaces import IOwned
from AccessControl.interfaces import IRoleManager
from Acquisition.interfaces import IAcquirer
from App.interfaces import INavigation
from persistent.interfaces import IPersistent
from zope.component.interfaces import IPossibleSite
from zope.container.interfaces import IContainer
from zope.deferredimport import deprecated
Expand Down
2 changes: 1 addition & 1 deletion src/Products/PageTemplates/Expressions.py
Expand Up @@ -18,12 +18,12 @@

import logging

from MultiMapping import MultiMapping
from six import binary_type
from six import text_type

import OFS.interfaces
from Acquisition import aq_base
from MultiMapping import MultiMapping
from Products.PageTemplates import ZRPythonExpr
from Products.PageTemplates.interfaces import IUnicodeEncodingConflictResolver
from zExceptions import NotFound
Expand Down
3 changes: 1 addition & 2 deletions src/Products/PageTemplates/ZRPythonExpr.py
Expand Up @@ -17,14 +17,13 @@

import sys

from RestrictedPython import compile_restricted_eval

from AccessControl import safe_builtins
from AccessControl.ZopeGuards import get_safe_globals
from AccessControl.ZopeGuards import guarded_getattr
from DocumentTemplate.DT_Util import InstanceDict
from DocumentTemplate.DT_Util import TemplateDict
from DocumentTemplate.security import RestrictedDTML
from RestrictedPython import compile_restricted_eval
from zope.tales.pythonexpr import PythonExpr


Expand Down
4 changes: 2 additions & 2 deletions src/Products/PageTemplates/expression.py
Expand Up @@ -4,8 +4,6 @@
from chameleon.astutil import Static
from chameleon.astutil import Symbol
from chameleon.codegen import template
from RestrictedPython import RestrictingNodeTransformer
from RestrictedPython.Utilities import utility_builtins
from six import class_types

from AccessControl.ZopeGuards import guarded_apply
Expand All @@ -15,6 +13,8 @@
from AccessControl.ZopeGuards import protected_inplacevar
from OFS.interfaces import ITraversable
from Products.PageTemplates.Expressions import render
from RestrictedPython import RestrictingNodeTransformer
from RestrictedPython.Utilities import utility_builtins
from z3c.pt import expressions
from zExceptions import NotFound
from zExceptions import Unauthorized
Expand Down
8 changes: 5 additions & 3 deletions src/Testing/ZopeTestCase/ZopeLite.py
Expand Up @@ -38,9 +38,6 @@
import ZODB # NOQA
import Zope2 # NOQA
import Zope2.Startup.run # NOQA
# Allow test authors to install Zope products into the test environment. Note
# that installProduct() must be called at module level -- never from tests.
from OFS.Application import get_folder_permissions # NOQA; NOQA
from OFS.Application import get_products
from OFS.Application import install_package
from OFS.Application import install_product
Expand All @@ -50,6 +47,11 @@
from ZODB.DemoStorage import DemoStorage # NOQA


# Allow test authors to install Zope products into the test environment. Note
# that installProduct() must be called at module level -- never from tests.
from OFS.Application import get_folder_permissions # NOQA; NOQA


# Allow code to tell it is run by the test framework
os.environ['ZOPETESTCASE'] = '1'

Expand Down
5 changes: 4 additions & 1 deletion src/ZTUtils/__init__.py
Expand Up @@ -13,7 +13,6 @@
"""Package of template utility classes and functions.
"""
from AccessControl.SecurityInfo import ModuleSecurityInfo
from ZTUtils.Zope import Batch # NOQA; NOQA
from ZTUtils.Zope import LazyFilter
from ZTUtils.Zope import make_hidden_input
from ZTUtils.Zope import make_query
Expand All @@ -27,6 +26,10 @@
from .Tree import encodeExpansion


from ZTUtils.Zope import Batch # NOQA; NOQA



security = ModuleSecurityInfo('ZTUtils')

security.declarePublic('encodeExpansion', 'decodeExpansion', 'a2b', 'b2a')
Expand Down

0 comments on commit c5962da

Please sign in to comment.