pipe2py icon indicating copy to clipboard operation
pipe2py copied to clipboard

union has no conf and therefore can't be iterated

Open gorenje opened this issue 13 years ago • 7 comments

Hi,

this is the error i get:

Traceback (most recent call last):
  File "testbasics.py", line 495, in test_fetchpage
    p = pipe2py.compile.parse_and_build_pipe(self.context, pipe_def)
  File "..../pipe2py/compile.py", line 298, in parse_and_build_pipe
    pb = build_pipe(context, pipe)
  File "..../pipe2py/compile.py", line 113, in build_pipe
    if 'prompt' in module['conf'] and context.describe_input:
TypeError: argument of type 'NoneType' is not iterable

after looking at the json for the pipe:

{u'type': u'union', u'id': u'sw-174', u'conf': None}

PipeId: MDbjmHcE3BGSFcldouNLYQ

Offending line: https://github.com/ggaughan/pipe2py/blob/master/compile.py#L110

This happens when creating a unit test and having the json being load + parsed. Creating a working pipe from the pipeid is no problem.

gorenje avatar Apr 28 '11 19:04 gorenje