[Pydev-code] pydev Code Analyser error
Brought to you by:
fabioz
|
From: Bartosz <ga...@po...> - 2011-12-13 12:13:18
|
Hi.
I found an error in pydev Code Analyser.
The following code works perfectly, and the pydev Code Analysis also parse this file without problem.
class TestConstants:
DICT1 = {'id':1}
DICT2 = {'id':2}
LIST_OF_DICTS = ["DICT1", "DICT2"]
for testName in TestConstants.LIST_OF_DICTS:
print(TestConstants.__dict__[testName])
Unfortunately when we split this code, into two separate files, and we add import, the pydev CodeAnalyser is displaying error (python code works correclty):
FILE01:
class TestConstants:
DICT1 = {'id':1}
DICT2 = {'id':2}
LIST_OF_DICTS = ["DICT1", "DICT2"]
FILE02:
from Constants import TestConstants
for testName in TestConstants.LIST_OF_DICTS:
print(TestConstants.__dict__[testName])
The full source code is in attachment.
Is it possible to fix this error, or it too complicated to fix it?
Thanks in advance
Bartosz
|