Ticket #65 (closed defect: fixed)

Opened 1 year ago

Last modified 1 year ago

exception after adding a package

Reported by: wrobe..@pld-linux.org Assigned to: arj..@yirdis.nl
Priority: major Milestone: Gaphor 0.12.0
Component: Gaphor Version:
Keywords: Cc:

Description

add a package using tree. exit gaphor, exception will be raised:

Traceback (most recent call last):
  File "setup.py", line 195, in <module>
    **platform_setup
  File "/usr/lib/python2.5/distutils/core.py", line 151, in setup
    dist.run_commands()
  File "/usr/lib/python2.5/distutils/dist.py", line 974, in run_commands
    self.run_command(cmd)
  File "/usr/lib/python2.5/distutils/dist.py", line 994, in run_command
    cmd_obj.run()
  File "./utils/command/run.py", line 132, in run
    starter()
  File "./gaphor/__init__.py", line 47, in main
    Application.shutdown()
  File "./gaphor/application.py", line 99, in shutdown
    srv.shutdown()
  File "./gaphor/UML/elementfactory.py", line 41, in shutdown
    self.flush()
  File "./gaphor/UML/elementfactory.py", line 143, in flush
    value.unlink()
  File "./gaphor/UML/element.py", line 79, in unlink
    component.handle(ElementDeleteEvent(self._factory, self))
  File "/home/wrobell/opt/share/python2.5/site-packages/zope.component-3.4dev_r72749-py2.5.egg/zope/component/_api.py", line 135, in handle
    for ignored in sitemanager.subscribers(objects, None):
  File "/home/wrobell/opt/share/python2.5/site-packages/zope.component-3.4dev_r72749-py2.5.egg/zope/component/registry.py", line 290, in subscribers
    return self.adapters.subscribers(objects, provided)
  File "/home/wrobell/opt/share/python2.5/site-packages/zope.interface-3.4.0b1-py2.5-linux-i686.egg/zope/interface/adapter.py", line 535, in subscribers
    subscription(*objects)
  File "./gaphor/ui/namespace.py", line 183, in _on_element_delete
    path = self.path_from_element(element)
  File "./gaphor/ui/namespace.py", line 77, in path_from_element
    return self.path_from_element(ns) + (n.index(e),)
ValueError: list.index(x): x not in list

Attachments

Change History

09/06/07 05:33:55 changed by arj..@yirdis.nl

  • milestone set to Gaphor 0.12.0.

This may be solved by destroying the namespace model properly on application exit.

09/07/07 00:57:12 changed by arj..@yirdis.nl

  • status changed from new to closed.
  • resolution set to fixed.

Seems to work okay now, since the namespace model is more relaxed about non-existent nodes.


Add/Change #65 (exception after adding a package)




Action