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
Renaming a workspace in a group can cause a name clash #8652
Comments
Samuel Jackson (2013-09-04T14:34:58): Refs http://trac.mantidproject.org/mantid/ticket/7807 Samuel Jackson (2013-09-04T14:34:58): Refs http://trac.mantidproject.org/mantid/ticket/7807 Samuel Jackson (2013-09-04T14:34:58): Refs http://trac.mantidproject.org/mantid/ticket/7807 Samuel Jackson (2013-09-04T14:34:59): Also added rename notifications to data service. Refs http://trac.mantidproject.org/mantid/ticket/7807 Samuel Jackson (2013-09-05T14:50:05): I would start by checking you can reproduce the problem. Load a few nexus files and group them. Then rename a child workspace to use the same name as another child workspace and verify that you get two pointers to the same workspace. Then check that this has been fixed in this branch. I would also suggest checking the behaviour of the following cases:
And any other edge cases you may think of. @PeterParker (2013-09-06T15:21:16):
The culprit is at line 301 of DataService.h:
When Also, now that the ticket has been reopened, has the expected functionality of the edge cases listed in comment 5 been decided to the extent where it can be "written in stone"? If so, unit tests to cover those cases would be particularly worthwhile in my opinion (given how much rests on GroupWorkspaces, and how often the surrounding code gets modified). Samuel Jackson (2013-09-09T10:13:37): Samuel Jackson (2013-09-10T09:53:08): Refs http://trac.mantidproject.org/mantid/ticket/7807 Samuel Jackson (2013-09-10T09:53:08): Also updated RenameWorkspace documentation with know issue. Refs http://trac.mantidproject.org/mantid/ticket/7807 @PeterParker (2013-09-13T15:13:52):
Samuel Jackson (2013-09-17T08:27:40): @KarlPalmen (2013-09-20T14:00:02): @martyngigg (2013-09-21T10:48:21): Can you hold off doing anything to this until we can talk about it more. I want to get Roman's thoughts on this too as he put the rename in in the first place. Samuel Jackson (2014-08-11T07:29:21): |
This does still happen in the world of GroupWorkspaces holding pointers. Perhaps Rename should refuse if a workspace of that name is in the ADS (or in a Group in the ADS). |
Rewritten into #16263 Therefore this is a duplicate |
This issue was originally TRAC 7807
Original Reporter: Samuel Jackson
If you rename two workspaces inside a workspace group to be the same thing you end up with two references to the same workspace. Also, deleting one does not remove the other reference.
The text was updated successfully, but these errors were encountered: