Control: tag -1 + upstream fixed-upstream Control: severity -1 serious Hi,
On Tue, Dec 22, 2020 at 05:56:35PM -0800, David M. Cooke wrote: > The upcoming 0.18 release of jedi should be compatible with parso 0.8.x. > 0.18 is now available :-) > In particular, parso 0.8 switched to using pathlib.Path for path names, > instead > of strings, so anything that ends up touching a path name in jedi may break. > > I've found that completion in IPython is completely broken, for instance. > > Here's some code (from the Jedi manual) that breaks: > > >>> import jedi > >>> code = '''import json; json.l''' > >>> script = jedi.Script(code, path='example.py') > >>> script > <Script: 'example.py' <SameEnvironment: 3.9.1 in /usr>> > >>> completions = script.complete(1, 19) > Traceback (most recent call last): > File "<stdin>", line 1, in <module> > ... > File "/usr/lib/python3/dist-packages/jedi/inference/value/module.py", line > 159, in is_stub > if self._path is not None and self._path.endswith('.pyi'): > AttributeError: 'PosixPath' object has no attribute 'endswith' > > (However, if the 'path' argument to Script is dropped, Jedi will compute the > expected result.) > Confirmed, this makes Elpy (Python IDE for Emacs) RC buggy, so I've upgraded the severity. Merry Christmas! Nicholas
signature.asc
Description: PGP signature