#858 Code Completion fails on Import From

1.4.3
closed
5
2014-08-23
2009-02-20
clayk
No

Eclipse SDK
Version: 3.4.1
Build id: M20080911-1700

PyDev
1.4.3.2627

OS
Windows XP SP2
(Can be tested on CentOS 5 platform if needbe)

I am unable to get code completion to work on the following file when imported:

class test1:

value1 = None
value2 = None

def __init__(self):
from project.sub.sub2.value1 import value1
from project.sub.sub2.value2 import value2

self.value1 = value1()
self.value2 = value2()

However, a change of the file to the following will allow code completion to work but fail on an undefined self variable

class test1:

self.value1 = None
self.value2 = None

def __init__(self):
from project.sub.sub2.value1 import value1
from project.sub.sub2.value2 import value2

self.value1 = value1()
self.value2 = value2()

Discussion

  • Fabio Zadrozny

    Fabio Zadrozny - 2009-02-20
    • status: open --> pending
     
  • Fabio Zadrozny

    Fabio Zadrozny - 2009-02-20

    I didn't understand exactly what you were expecting (which completions were you expecting with which code that imported that module?)

     
  • clayk

    clayk - 2009-02-20

    The file above is imported in another file with the following statement and
    creates an instance of it after a class definition:

    from project.sub.sub2.container.support import test1 as xt1

    class dataobject:
    test1 = xti()

    That file is then imported into a file where I am trying to get code
    completion with the following:

    from project.sub.sub2.dataobject import dataobject

    In that file I create the following and do not get code completion for the
    objects of class test1:

    ao = dataobject.test.value1
    ao.

    I am expecting code completion for ao which is an instance of value1.
    Which was imported in and defined in the original portion of the bug I
    filed.

     
  • Fabio Zadrozny

    Fabio Zadrozny - 2009-03-07

    Sorry again. I'm still not following (it works for some tests I did, so, I'm probably overlooking something). Can you attach a zip with a sample containing an example with source-code (and folder structure) of what's not working?

     
  • SourceForge Robot

    This Tracker item was closed automatically by the system. It was
    previously set to a Pending status, and the original submitter
    did not respond within 14 days (the time period specified by
    the administrator of this Tracker).

     
  • SourceForge Robot

    • status: pending --> closed
     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks