-
-
Notifications
You must be signed in to change notification settings - Fork 187
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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prevent removing relationships with Remove Unused Elements disabled #3173
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
So we do no longer explicitly have to unlink.
amolenaar
force-pushed
the
fix-retain-relations
branch
6 times, most recently
from
March 10, 2024 16:24
319fefb
to
9d52cc5
Compare
Closed
3 tasks
amolenaar
force-pushed
the
fix-retain-relations
branch
from
March 10, 2024 20:31
9d52cc5
to
5a6ecb1
Compare
So test data is not interfering with real user settings
They are taken care of by the sanitizer service. That way we can avoid deletion if the option _Remove Unused Elements_ is disabled.
Leave it to the Sanitizer service.
Let Sanitizer service take care of this. On disconnected unused MessageEnds are still removed, though.
Instead the Sanitizer service has to take care of this.
This should avoid errors like: ==> Pouring python@3.12--3.12.2_1.monterey.bottle.tar.gz Error: The `brew link` step did not complete successfully The formula built, but is not symlinked into /usr/local Could not symlink bin/2to3
We want the homebrew version!
amolenaar
force-pushed
the
fix-retain-relations
branch
from
March 10, 2024 20:41
5a6ecb1
to
7d10e69
Compare
danyeaw
added
fix
A fix for a bug
and removed
python
Pull requests that update Python code
labels
Mar 11, 2024
danyeaw
approved these changes
Mar 11, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @amolenaar, this is a really great way to handle this!
danyeaw
changed the title
Fix retain relations
Prevent removing relationships with Remove Unused Elements disabled
Apr 15, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR Type
What kind of change does this PR introduce?
What is the current behavior?
If you disable the "Remove Unused Elements" option, and remove a diagram, the relations in that diagram are removed anyway.
Issue Number: Fixes #2616 and #3047.
What is the new behavior?
All unlinking is left to the SanitizerService. This service knows if the "Remove Unused Elements" option has been disabled and acts accordingly.
Does this PR introduce a breaking change?
Without a configured Sanitizer Service, relationships are no longer removed on model level when a relation is broken in a diagram.
Other information
The change itself is quite simple: remove the unlink call from the connector. Fixing the tests took most of the time 馃槃 .