[wingide-users] Autocomplete doesn't recognize file()Rene Pijlman rene at lab.applinet.nl
Sun, 16 Feb 2003 14:34:36 +0100
Hello, When typing the following code, autocomplete doesn't work on f. : f = file(r"D:\x.txt","w") assert isinstance(f,file) f. However, it works fine when file() is replaced by open(): f = open(r"D:\x.txt","w") assert isinstance(f,file) f. In fact, in the second case it works fine even without the assert isinstance(). It appears there are 2 bugs in this case: 1) file() isn't recognized like open(), even though the Python manual more or less recommends the use of file() ("The file() constructor is new in Python 2.2. The previous spelling, open(), is retained for compatibility, and is an alias for file()." http://www.python.org/dev/doc/devel/lib/built-in-funcs.html). 2) The isinstance() as recommended by the WingIDE manual doesn't seem to work in this case. Is there anything I can do to make autocomplete work on objects produced by file()? Can this be fixed in WingIDE? I'm evaluating WingIDE 1.1.7 with Python 2.2.2 (python.org distribution) on Windows 2000 Professional. Regards, René Pijlman
Run by Mailman v 2.0.8
Copyright (c) 2000-2002, Archaeopteryx Software, Inc.