Skip to content

Conversation

SilkeSchomann
Copy link
Collaborator

@SilkeSchomann SilkeSchomann commented May 9, 2025

Description of work:
Due to rounding errors MSlice sometimes assumed a set width for producing more than one cut when only one cut was intended. This has been fixed by setting the width to None if no value was provided.

To test:

Please replace MSlice in an installed Mantid with the version from this branch and follow steps in the original issue.

Fixes #39285 - Might need to get closed manually as it is a Mantid issue.

Copy link
Member

@mducle mducle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good and I confirm it fixes the issue.

I think that with this, the code where the original rounding error occurs (lines 145-146 of models/cut.py) is now unreachable and should probably be removed...

@github-project-automation github-project-automation bot moved this from Unassigned to Approved in DEVS May 9, 2025
@SilkeSchomann
Copy link
Collaborator Author

Looks good and I confirm it fixes the issue.

I think that with this, the code where the original rounding error occurs (lines 145-146 of models/cut.py) is now unreachable and should probably be removed...

I agree, I will open a separate issue for it.

@SilkeSchomann SilkeSchomann merged commit 920627b into main May 9, 2025
2 checks passed
@github-project-automation github-project-automation bot moved this from Approved to Merged in DEVS May 9, 2025
@SilkeSchomann SilkeSchomann deleted the 39285_fix_width_problem branch May 9, 2025 10:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Merged
Development

Successfully merging this pull request may close these issues.

2 participants