You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After cloning a workspace I've discovered that the logs are shared between the original and the clone, so altering the original also affects the clone.
I was running this script when I discovered this.
def correct_logs(ws):
ws_log_names = mtd[ws].getRun().keys()
if 'stheta' in ws_log_names and not 'theta' in ws_log_names:
#create a copy of the original
CloneWorkspace(InputWorkspace=ws,OutputWorkspace=ws+"_clone")
RenameLog(Workspace=ws,OriginalLogName='stheta',NewLogName='theta')
else:
print "Nothing to correct."
correct_logs('POLREF00008481')
To reproduce
Load POLREF00008481.nxs and check the sample logs for "stheta" and note that 'theta' doesn't exist, then run the script. Check the sample logs again on both POLREF00008481 and POLREF00008481_clone for stheta. It won't be present on either and theta will be present instead.
The way it should work is that the original should have been altered and have theta rather than 'stheta', while the clone should remain untouched and contain 'stheta' but not 'theta'
The text was updated successfully, but these errors were encountered:
Original Reporter: Keith Brown
After cloning a workspace I've discovered that the logs are shared between the original and the clone, so altering the original also affects the clone.
I was running this script when I discovered this.
To reproduce
Load POLREF00008481.nxs and check the sample logs for "stheta" and note that 'theta' doesn't exist, then run the script. Check the sample logs again on both POLREF00008481 and POLREF00008481_clone for stheta. It won't be present on either and theta will be present instead.
The way it should work is that the original should have been altered and have theta rather than 'stheta', while the clone should remain untouched and contain 'stheta' but not 'theta'
The text was updated successfully, but these errors were encountered: