bblfsh / python-driver

GNU General Public License v3.0
10 stars 16 forks source link

EOF in multiline statement #203

Open ncordon opened 5 years ago

ncordon commented 5 years ago

From the latest bblfsh logs:

Traceback (most recent call last):\n  
File \"/opt/driver/bin/.local/lib/python3.6/site-packages/python_driver/requestprocessor.py\", line 155, in process_request\n    ast = AstImprover(code, orig_ast).parse()\n  
File \"/opt/driver/bin/.local/lib/python3.6/site-packages/python_driver/astimprove.py\", line 26, in __init__\n    self._tokens: List[Token] = [Token(*i) for i in tokenize.tokenize(BytesIO(codestr.encode('utf-8')).readline)]\n  
File \"/opt/driver/bin/.local/lib/python3.6/site-packages/python_driver/astimprove.py\", line 26, in <listcomp>\n    self._tokens: List[Token] = [Token(*i) for i in tokenize.tokenize(BytesIO(codestr.encode('utf-8')).readline)]\n  
File \"/usr/local/lib/python3.6/tokenize.py\", line 602, in _tokenize\n    raise TokenError(\"EOF in multi-line statement\", (lnum, 0))\ntokenize.TokenError: ('EOF in multi-line statement', (10, 0))\n

Examples of files that triggered the error:

tags/0.9/macsetup.py
tags/0.9.3/macsetup.py
tags/0.9-rc3/macsetup.py
tags/0.9.3.1/macsetup.py
tags/0.9.1/macsetup.py
tags/0.9.4/macsetup.py
tags/0.9-rc2/macsetup.py
tags/0.9.2/macsetup.py