-- [ You are subscribed to pyqt...@googlegroups.com. To unsubscribe, send email to pyqtgraph+...@googlegroups.com ]
importAll('graphicsItems')
importAll('widgets', excludes=['MatplotlibWidget', 'RemoteGraphicsView'])
importAll('graphicsItems')
importAll('graphicsItems/ViewBox', ('axisCtrlTemplate_pyqt', 'axisCtrlTemplate_pyside'))
importAll('graphicsItems/PlotItem', ('plotConfigTemplate_pyqt', 'plotConfigTemplate_pyside'))
importAll('widgets', excludes=['MatplotlibWidget', 'RemoteGraphicsView'])
def importAll(path, excludes=()):
d = os.path.join(os.path.split(__file__)[0], path)
files = []
for f in os.listdir(d):
if os.path.isdir(os.path.join(d, f)) and f != '__pycache__':
files.append(f)
elif f[-3:] == '.py' and f != '__init__.py':
files.append(f[:-3])
# we have to use a "package.package.module" notation...
path = path.replace("/", ".")
for modName in files:
if modName in excludes:
continue
mod = __import__(path+"."+modName, globals(), locals(), fromlist=['*'])
if hasattr(mod, '__all__'):
names = mod.__all__
else:
names = [n for n in dir(mod) if n[0] != '_']
for k in names:
if hasattr(mod, k):
globals()[k] = getattr(mod, k)
Traceback (most recent call last):
File "pyqtgraph\GraphicsScene\exportDialog.pyc", line 122, in exportClicked
AttributeError: 'NoneType' object has no attribute 'export'
from pyqtgraphBundleUtils import *
# problem with scipy...
from email.mime import message, image, text, multipart, audio
try:
import scipy.weave
USE_WEAVE = True
except ImportError:
USE_WEAVE = False
I thought that maybe the changes had already been pushed and updated to version 204. My program still runs directly, but now when I bundle the application and try to run it I get pages and pages errors reference scipy.weave:Traceback (most recent call last):File "pyqtgraph\graphicsItems\PlotCurveItem.pyc", line 324, in boundingRectFile "pyqtgraph\graphicsItems\GraphicsItem.pyc", line 188, in pixelVectorsFile "pyqtgraph\functions.pyc", line 1380, in invertQTransformException: This function depends on scipy.weave library, but it does not appear to be usable.
Sorry, that's a new bug; fixed in r205.
Great. I love real time bug fixing :-)
Speaking of releases, the current versioning model is to just use the revision number in source control.
I would suggest at some point use a major.minor numbering scheme, and each new version under that scheme should undergo a bit more validation, eg. ensure it can be bundled with Py2exe and Py2app, and all the features work reasonably well in either mode (bundled or not), on Mac, Linux, and Windows.
Currently, the latest version is a development release, always evolving. It would be nice to have a 1.0 at some time, which would constitute a good reference point, and a way to differentiate with the always up-to-date development releases. Also a 1.0 represents something people know is solid and they can safely use for production.
Of course this is not a rant :-)
Great.
Once we have a release with this, the bundling guide can be greatly simplified.
I was wondering...
Many issues when in frozen environment are due to not importing modules the standard way. For example some modules are imported directly into the root pyqtgraph namespace, even though these modules are located in packages 1 level or more below.
Why does pyqtgraph have to dynamically import modules in some directories? Can't all the modules be imported into the code with regular import statements, with the proper package path (eg. ".graphicsItems.TextItem")?
Luke