[docs] [issue35001] ImportFrom level cannot be optional

thautwarm report at bugs.python.org
Wed Oct 17 04:21:25 EDT 2018


thautwarm <yaoxiansamma at gmail.com> added the comment:

Hi, Serhiy, for Python-asdl has made `level` able to optional, certainly we could construct an ImportFrom AST without giving `level`.

Moreover, this might evidence that `level` cannot be optional in fact:

https://github.com/python/cpython/blob/8e73ad38ab7d218b9ef8976032865928dfad00f1/Python/compile.c#L2918

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue35001>
_______________________________________


More information about the docs mailing list