pbfy0 / visvis

Automatically exported from code.google.com/p/visvis
Other
0 stars 0 forks source link

No module named utils.guisupport #45

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Install visvis from latest sources
2. Run python
3. import visvis

What is the expected output? What do you see instead?

What version of the product are you using? On what operating system?

Please provide any additional information below.

$ python
Python 2.7.2 (v2.7.2:8527427914a2, Jun 11 2011, 15:22:34) 
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import visvis
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/rougier/local/lib/python2.7/site-packages/visvis/__init__.py", line 52, in <module>
    import visvis.utils.guisupport
ImportError: No module named utils.guisupport

Original issue reported on code.google.com by Nicolas.Rougier@gmail.com on 13 Aug 2012 at 8:26

GoogleCodeExporter commented 9 years ago
I have done some refactoring but have not yet updated the install script... You 
can always run visvis by just placing it somewhere on your PYTHONPATH.

Original comment by almar.klein@gmail.com on 13 Aug 2012 at 8:31

GoogleCodeExporter commented 9 years ago
It's far from ideal...

Here is the modified packages list:

    packages = ['visvis',
                'visvis.functions',
                'visvis.backends', 
                'visvis.processing',
                'visvis.vvmovie',
                'visvis.io',
                'visvis.utils',
                'visvis.utils.ssdf',
                'visvis.text',
                'visvis.text.freetype',
                'visvis.core',
                'visvis.wibjects',
                'visvis.wobjects'],

I also had problem with import ".xxx" syntax. I think it's far better to 
specify the whole path: 

visvis/text/__init__.py:

from visvis.text.text_base import AtlasTexture, FontManager, BaseText
from visvis.text.text_base import Text, Label

from visvis.text.text_prerendered import PrerenderedFontManager

visvis/text/text_freetype.py:

from visvis.core.misc import getResourceDir, getOpenGlCapable

import subprocess

from visvis.core.shaders import Shader, ShaderCodePart

from visvis.text.text_base import AtlasTexture, FontManager, Text, Label
from visvis.text.text_base import correctVertices, simpleTextureDraw

from visvis.text.freetype import ( Face, Vector, Matrix, FT_KERNING_UNFITTED,
                        FT_LOAD_RENDER, FT_LOAD_FORCE_AUTOHINT )

Nicolas

Original comment by Nicolas.Rougier@gmail.com on 13 Aug 2012 at 8:43

GoogleCodeExporter commented 9 years ago
What kind of problems did you have? 

I changed it to absolute. But there is some code elsewhere in visvis where 
relative imports are used and hard to remove. Let me know if you still have 
problems...

Original comment by almar.klein@gmail.com on 16 Aug 2012 at 2:35