[PEAK] A question re peak.storage.xmi
Stephen Waterbury
golux at comcast.net
Tue Sep 28 00:10:42 EDT 2004
Any hints on what might be the problem in the session below?
Using the latest cvs version of PEAK:
Python 2.3.3 (#1, Dec 21 2003, 00:52:10)
[GCC 3.2.2 20030222 (Red Hat Linux 3.2.2-5)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from peak.api import storage
>>> dm = storage.xmi.fromFile('pgefenterprise.xmi', None)
>>> dm
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/usr/local/lib/python2.3/site-packages/peak/util/ListProxy.py", line 5, in __repr__
def __repr__(self): return repr(self.data)
File "/usr/local/lib/python2.3/site-packages/peak/storage/data_managers.py", line 318, in setstate
ob.__setstate__(self._load(oid,ob))
File "/usr/local/lib/python2.3/site-packages/peak/storage/xmi.py", line 785, in _load
return [
File "/usr/local/lib/python2.3/site-packages/peak/storage/data_managers.py", line 266, in __getitem__
ob = self._ghost(oid,state)
File "/usr/local/lib/python2.3/site-packages/peak/storage/xmi.py", line 751, in _ghost
klass = self.getClass(target._name)
File "/usr/local/lib/python2.3/site-packages/peak/storage/xmi.py", line 762, in getClass
return getattr(self.metamodel, name.split('/')[-1])
File "C:\cygwin\home\pje\PEAK\src/peak/binding/_once.pyx", line 112, in _once.BaseDescriptor.__get__
File "C:\cygwin\home\pje\PEAK\src/peak/binding/_once.pyx", line 100, in _once.__get__
File "/usr/local/lib/python2.3/site-packages/peak/binding/components.py", line 565, in computeValue
return self.targetName.findComponent(obj, self.default)
File "/usr/local/lib/python2.3/site-packages/peak/binding/components.py", line 349, in findComponent
else: ob = getattr(ob,attr)
File "C:\cygwin\home\pje\PEAK\src/peak/binding/_once.pyx", line 112, in _once.BaseDescriptor.__get__
File "C:\cygwin\home\pje\PEAK\src/peak/binding/_once.pyx", line 100, in _once.__get__
File "/usr/local/lib/python2.3/site-packages/peak/binding/once.py", line 498, in <lambda>
f = lambda s,d,a: func(s)
File "/usr/local/lib/python2.3/site-packages/peak/storage/xmi.py", line 708, in metamodel
return XMI_METAMODELS.of(self)[models[0]]
File "/usr/local/lib/python2.3/site-packages/peak/config/config_components.py", line 546, in __getitem__
ob = self.get(key,NOT_FOUND)
File "/usr/local/lib/python2.3/site-packages/peak/config/config_components.py", line 555, in get
return lookup(
File "/usr/local/lib/python2.3/site-packages/peak/config/config_components.py", line 87, in lookup
for value in iterValues(component, configKey):
File "/usr/local/lib/python2.3/site-packages/peak/config/config_components.py", line 60, in iterValues
adapt(
File "/usr/local/lib/python2.3/site-packages/peak/config/interfaces.py", line 145, in noMoreValues
raise exceptions.InvalidRoot(
peak.exceptions.InvalidRoot: Root component <peak.storage.xmi.XMIDocument object at 0x4008414c> does not implement 'IConfigurationRoot' (was looking up peak.xmi.metamodels.UML.1.3 for <peak.storage.xmi.XMIDocument object at 0x4008414c>)
More information about the PEAK
mailing list