Yesha Vora created ZEPPELIN-1133: ------------------------------------ Summary: python interpreter can not handle functions in certain format Key: ZEPPELIN-1133 URL: https://issues.apache.org/jira/browse/ZEPPELIN-1133 Project: Zeppelin Issue Type: Bug Reporter: Yesha Vora
Python interpreter can not handle a syntax where function is called right after function definition is finished. (formatA). However, if a new line is added after function definition, that syntax works fine with python interpreter. We should not need to add a line after function is defined. In python, we do not require to add a line after function is defined. Thus, zeppelin interpreter is not handling this situation correctly. Zeppelin user should be able to run above commandlines without additional space. {code:title=formatA} %python def greet(name): print 'Hello', name greet('Jack') greet('Jill') greet('Bob'){code} {code:title=output} File "<stdin>", line 3 greet('Jack') ^ SyntaxError: invalid syntax Traceback (most recent call last): File "<stdin>", line 1, in <module> NameError: name 'greet' is not defined Traceback (most recent call last): File "<stdin>", line 1, in <module> NameError: name 'greet' is not defined{code} {code:title=formatB} %python def greet(name): print 'Hello', name greet('Jack') greet('Jill') greet('Bob'){code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)