-
-
Notifications
You must be signed in to change notification settings - Fork 188
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
v2.23 complains of invalid gaphor model in file that opens in v2.22 #2995
Comments
Hey @mikekidner, is it possible to share the model? |
Not publicly, but is there a way I can upload you a copy? |
I'm surprised it does open with 2.22. This check is in there for quite some time. An element should not reference itself in the model. In the model file, there should be a package with
If you remove the package tag with contents, the model should load again. |
@amolenaar, thanks for the pointer. I opened in v22.1 and noted on closing the following errors:
which agrees with the v2.23 errors. I extracted a sub set of the model, around the package that raised the initial errors, and this opened in v2.23. So I don't think its related to that area of the model. The model is quite large 24Mb, let me know if there is a spot I can upload it too if that helps resolve the issue. |
@mikekidner, what's your email address? I can share a OneDrive folder with you for you to upload it in. Or you could try using Warp to send it to us. |
Hi, I'm getting the same issue with a model I have, unfortunately, I can share the model. It opens in 2.22.1 but fails to open in 2.23.1 with the same error "This file does not contain a valid Gaphor model". I'm not sure how to see the error log because the window closes as soon as I close the error dialog. Running via the cmd line doesn't throw any errors. However loading via jupyter provides the following:
|
Thanks @mikekidner for the model and @tompkins-ct for the additional traceback, both of those were very helpful to debug this. I opened #3018 to resolve this. 👍 |
Closed by #3018. |
Thanks @danyeaw! It's a relief to be able to open that model again. |
Describe the bug
A (large) model that opens in v2.22 does not open in v2.23.
Gaphor version: 2.23.0
Operating System: Darwin (21.6.0)
Display: GdkMacosDisplay
Python version: 3.11.7
GTK version: 4.12.4
Adwaita version: 1.4.2
GtkSourceView version: 5.10.0
Cairo version: 1.18.0
Pango version: 1.50.14
PyGObject version: 3.46.0
Pycairo version: 1.25.1
pygit2/libgit2 version: 1.13.3 / 1.7.1
Errors:
Time since application startup: 0:00:55
|Traceback (most recent call last):
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/ui/errorhandler.pyc", line 42, in response
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/ui/filemanager.pyc", line 234, in
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/core/eventmanager.pyc", line 83, in handle
| File "/Applications/Gaphor.app/Contents/Frameworks/generic/event.pyc", line 61, in handle
|ExceptionGroup: Error while handling events (1 sub-exception)
└─┬──────────────────────────────╌┄┈
|Traceback (most recent call last):
| File "/Applications/Gaphor.app/Contents/Frameworks/generic/event.pyc", line 57, in handle
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/application.pyc", line 119, in on_session_shutdown
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/application.pyc", line 147, in shutdown_session
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/application.pyc", line 231, in shutdown
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/application.pyc", line 238, in shutdown_service
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/core/modeling/elementfactory.pyc", line 76, in shutdown
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/core/modeling/elementfactory.pyc", line 197, in flush
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/core/modeling/diagram.pyc", line 362, in unlink
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphas/connections.pyc", line 165, in remove_connections_to_item
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphas/connections.pyc", line 148, in _disconnect_item
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/diagram/_connector.pyc", line 108, in call
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/UML/classes/containmentconnect.pyc", line 68, in disconnect
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/core/modeling/element.pyc", line 213, in setattr
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/core/modeling/properties.pyc", line 149, in set
| File "/Applications/Gaphor.app/Contents/Frameworks/gaphor/core/modeling/properties.pyc", line 381, in set
|TypeError: Can not set <gaphor.UML.uml.Package element b0d8bd42-2066-11ee-b860-ba28606445aa>.package to itself
└─────────────────────────────╌┄┈
Expected behavior
The model to open. Or to identify the issue, so it can be corrected.
OS
Version
Version of Gaphor:2.23
Additional information
The model opens in 2.22, is there a way to identify the problematic elements?
The text was updated successfully, but these errors were encountered: