S*******s 发帖数: 13043 | 1 My test script runs well in PyDev. but in the IDE, it marks error in the
line import Sybase, with description Unresolved import: Sybase
again, it runs well, which means the python is able to find the egg while
pydev can not. Where shall I direct pydev to solve the reference? |
S*******s 发帖数: 13043 | 2 screen shot
【在 S*******s 的大作中提到】 : My test script runs well in PyDev. but in the IDE, it marks error in the : line import Sybase, with description Unresolved import: Sybase : again, it runs well, which means the python is able to find the egg while : pydev can not. Where shall I direct pydev to solve the reference?
|
l*******m 发帖数: 1096 | 3 right click on your project -> properties -> Pydev-pythonpath -> external
libraries -> add ...
【在 S*******s 的大作中提到】 : screen shot
|
S*******s 发帖数: 13043 | 4 i did so. I added both the folder and the egg. then I got the snapshot in
the previous post.
【在 l*******m 的大作中提到】 : right click on your project -> properties -> Pydev-pythonpath -> external : libraries -> add ...
|
l*******m 发帖数: 1096 | 5 em your OS is win
there are other approaches:
1) use sys.path to add the path, such as
import sys
sys.path.append('/path/to/package')
2) or you can ignore the error by using #@UnresolvedImport. e.g.
import xxx #@UnresolvedImport
【在 S*******s 的大作中提到】 : i did so. I added both the folder and the egg. then I got the snapshot in : the previous post.
|