Message334807
Travis provides a "3.8-dev" python, which is updated regularly to track cpython master. When running our tests on this Python, specifically version
python: 3.8.0a0 (heads/master:f75d59e, Feb 3 2019, 07:27:24)
we just started getting tracebacks:
TypeError Traceback (most recent call last)
/opt/python/3.8-dev/lib/python3.8/codeop.py in __call__(self, source, filename, symbol)
131
132 def __call__(self, source, filename, symbol):
--> 133 codeob = compile(source, filename, symbol, self.flags, 1)
134 for feature in _features:
135 if codeob.co_flags & feature.compiler_flag:
TypeError: required field "type_ignores" missing from Module
(Full log: https://travis-ci.org/python-trio/trio/jobs/488312057)
Grepping through git diffs for 'type_ignores' suggests that this is probably related to bpo-35766.
I haven't dug into this in detail, but it seems to be happening on tests using IPython. The lack of further traceback suggests to me that the exception is happening inside IPython's guts (it has some hacks to try to figure out which parts of the traceback are in user-defined code versus its own internal code, and tries to hide the latter when printing tracebacks). The crash is in codeop.Compile.__call__, and IPython does create ast.Module objects and pass them to codeop.Compile.__call__:
https://github.com/ipython/ipython/blob/512d47340c09d184e20811ca46aaa2f862bcbafe/IPython/core/interactiveshell.py#L3199-L3200
Maybe ast.Module needs to default-initialize the new type_ignores field, or compile() needs to be tolerant of it being missing? |
|
Date |
User |
Action |
Args |
2019-02-04 05:05:51 | njs | set | recipients:
+ njs, gvanrossum, brett.cannon, benjamin.peterson, yselivanov |
2019-02-04 05:05:47 | njs | set | messageid: <1549256747.48.0.424452103214.issue35894@roundup.psfhosted.org> |
2019-02-04 05:05:47 | njs | link | issue35894 messages |
2019-02-04 05:05:47 | njs | create | |
|