[wingide-users] Source code browser

Adrian Klaver adrian.klaver at gmail.com
Fri Feb 1 10:41:51 EST 2013

On 02/01/2013 07:29 AM, Wingware Support wrote:
> Adrian Klaver wrote:
>>> If the effective current directory ('', which can be set with Debug >
>>> Initial Directory project property and defaults to project location) is
>>> the same as /home/aklaver/software_projects/greenhouse_app then maybe
>>> it's leading to duplication somehow.
>> There is no Initial Directory set, so from the tool tip it should be
>> defaulting to the project root listed above.
> The default is either the location of the main debug file (if one is
> defined) or the location of the project.  (And not the root of the
> project tree, as I think you are saying, although these may of course be
> the same in some cases)
>>> This would be a bug, however.  Contrary to what I wrote yesterday, the
>>> Source Browser doesn't look at Python Path but only what's in the
>>> project.  That is why it shows one entry for each copy of a file/class.
>> That would seem to at odds with the documentation:
>> "..set PYTHONPATH so Wing's source analyzer and debugger can find your
>> files, and set any other necessary runtime environment for your code ..."
>> and with what I am seeing. When I removed the code from site-packages it
>> disappeared from the Source Browser.
> The Source Browser is not the same thing as the source analyzer.  The
> latter is the engine that finds and analyzes your code.  It essentially
> starts in project files and traces down any imports using the defined
> PYTHONPATH (which can of course lead it to files that are not listed in
> the Project view).

All I can go by is what I saw. When I had the package in site-packages 
those files showed up in the Source Browser. I could right click on a 
file and select Go To and depending on which one I chose it would take 
me either to the file in the source tree or to the one in site-packages. 
The files showed up as file name Copy #1 or Copy #2 and had different 
content. Removing the package from site-packages solved that problem. I 
now have duplicate entries that resolve to the same file.

> I saw John also replied privately to get some more info so let's see
> what that turns up.


> Thanks,

Adrian Klaver
adrian.klaver at gmail.com

More information about the wingide-users mailing list