Are there some files missing from the plugins example? When I run
main.py from the plugins example, I get:
Traceback (most recent call last):
File "main.py", line 3, in <module>
from recipes.plugins import RecipeChooserPlugin
File "/home/darren/Projects/dip/doc/examples/plugins/recipes/__init__.py",
line 4, in <module>
from .i_recipe_chooser import IRecipeChooser
File
"/home/darren/Projects/dip/doc/examples/plugins/recipes/i_recipe_chooser.py",
line 3, in <module>
from stock import IStockLevels
ImportError: No module named stock
I think there may be two issues: the stock module/package is not
included in the sources/hg repo, and an absolute import is being used
rather than a relative import:
$ grep -r StockLevels .
./recipes/plugins/recipe_chooser_plugin.py:from stock import IStockLevels
./recipes/plugins/recipe_chooser_plugin.py: stock_levels =
self.service(IStockLevels)
./recipes/i_recipe_chooser.py:from stock import IStockLevels
./recipes/i_recipe_chooser.py: stock_levels = Instance(IStockLevels)
Darren
_______________________________________________
PyQt mailing list [email protected]
http://www.riverbankcomputing.com/mailman/listinfo/pyqt