Example #1
0
 def _call_init(self, *options, **kwds):
     if not 'data' in kwds:
         if len(options) > 0:
             if len(options) > 1:
                 raise RuntimeError("A FunctorTask instance can only be executed with a single non-keyword argument")
             kwds['data'] = options[0]
             #options = options[1:]
         elif not self.inputs.data.optional:
             raise RuntimeError("A FunctorTask instance must be executed with at 'data' argument")
     self._kwds = kwds
     return TaskPlugin._call_init(self, **kwds)
Example #2
0
 def _call_init(self, *options, **kwds):
     if not 'data' in kwds:
         if len(options) > 0:
             if len(options) > 1:
                 raise RuntimeError(
                     "A FunctorTask instance can only be executed with a single non-keyword argument"
                 )
             kwds['data'] = options[0]
             #options = options[1:]
         elif not self.inputs.data.optional:
             raise RuntimeError(
                 "A FunctorTask instance must be executed with at 'data' argument"
             )
     self._kwds = kwds
     return TaskPlugin._call_init(self, **kwds)