autocomplete doesn't work

12 months ago by
Hi expert,

   I try below codes, and autocomplete doesn't work.

import matplotlib.pyplot as plt
fig = plt.figure()

  here in the last line, when I type fig.add , wing ide doesn't show the hint for autocompletion (expect it give hint to show add_subplot).

could you please help to comment?

by the way, I use Anaconda 4.4.0 64bits windows. (the project setting is 
Python Executable : D:\Software\Anaconda2\python
Python Path: D:\Software\Anaconda2

Community: Wing Python IDE

1 Answer

12 months ago by
In this case Wing's static analyzer is unable to determine the return type of plt.figure() and can't offer autocomplete suggestions.  An option in cases like this is to run to a breakpoint and then add code.  When a debug process is a active, Wing will inspect the runtime state of the debug process and use this information to determine the type of fig.

More information on helping Wing analyze code is in the manual at
Please login to add an answer/comment or follow this question.

Similar posts:
Search »