def __setstate__(self, state):
     Script.__setstate__(self, state)
     if (getattr(self, 'Python_magic', None) != Python_magic
             or getattr(self, 'Script_magic', None) != Script_magic):
         global _log_complaint
         if _log_complaint:
             LOG.info(_log_complaint)
             _log_complaint = 0
         # Changes here won't get saved, unless this Script is edited.
         body = self._body.rstrip()
         if body:
             self._body = body + '\n'
         self._compile()
         self._v_change = 1
     elif self._code is None:
         self._v_ft = None
     else:
         self._newfun(marshal.loads(self._code))
Example #2
0
 def __setstate__(self, state):
     Script.__setstate__(self, state)
     if (getattr(self, 'Python_magic', None) != Python_magic or
         getattr(self, 'Script_magic', None) != Script_magic):
         global _log_complaint
         if _log_complaint:
             LOG.info(_log_complaint)
             _log_complaint = 0
         # Changes here won't get saved, unless this Script is edited.
         body = self._body.rstrip()
         if body:
             self._body = body + '\n'
         self._compile()
         self._v_change = 1
     elif self._code is None:
         self._v_ft = None
     else:
         self._newfun(marshal.loads(self._code))
Example #3
0
 def __call__(self, *args, **kw):
     '''Calls the script.'''
     self._updateFromFS()
     return Script.__call__(self, *args, **kw)
Example #4
0
 def __render_with_namespace__(self, namespace):
     '''Calls the script.'''
     self._updateFromFS()
     return Script.__render_with_namespace__(self, namespace)
Example #5
0
 def __call__(self, *args, **kw):
     '''Calls the script.'''
     self._updateFromFS()
     return Script.__call__(self, *args, **kw)
Example #6
0
 def __render_with_namespace__(self, namespace):
     '''Calls the script.'''
     self._updateFromFS()
     return Script.__render_with_namespace__(self, namespace)
Example #7
0
 def __call__(self, *args, **kw):
     """Calls the script."""
     self._updateFromFS()
     return Script.__call__(self, *args, **kw)
 def __call__(self, *args, **kw):
     """Calls the script."""
     self._updateFromFS()
     return Script.__call__(self, *args, **kw)