Skip to content

Fix to skipping artificial normalization #499

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

Merged
merged 1 commit into from
Nov 14, 2024
Merged

Conversation

rboston628
Copy link
Contributor

@rboston628 rboston628 commented Nov 14, 2024

Description of work

An error is generated if reduction is performed on the same run twice in a row.

This was due to all fields on the ArtificialNormalizationView being deleted as a way of hiding them if artificial normalization was not needed.

Explanation of work

Instead of deleting the widgets, they are added to a different layout, and that layout added inside a frame which can be hidden.

This has the same effect, but the widgets still exist and can be updated or shown as needed.

It was determined in slack comments that a plain view underneath the popup should be shown if artificial normalization is skipped.

To test

Dev testing

Make sure on your local you have a normalization for run 46680.

From next, reproduce the error. Run reduction on 46680. Click okay on the Workflow Complete dialog box. Now run reduction on 46680 again. An error will be generated, saying that a widget has been deleted.

Still onnext, hide this normalization file (rename its folder), run reduction with 46680, take screen shot of the artificial normalization screen.

Switch to this branch. Keep the normalization file hidden, and run reduction with 46680, compare artificial normalization screen to your screen shot. It should be identical.

Unhide the normalization file or make a new one. Run reduction with 46680. It should go directly to a workflow complete popup on a blank view. Run reduction again with 46680. The same workflow complete popup again, up with no errors.

CIS testing

Hide the normalization file (rename its folder).

Open the SNAPRed reduction panel. Enter 61991 as the run number, continue to the artificial normalization screen. Run reduction twice in a row for this run.
(It is faster to use 46680, if you prefer)

Restore the normalization file.

Open the SNAPRed reduction panel. Enter 61991 as the rune number, continue. There should be no artificial normalization taking place. The workflow will finish successfully, with popup over stylish blank view. Run reduction again. There should be no issues.

Link to EWM item

EWM#8230

Verification

  • the author has read the EWM story and acceptance critera
  • the reviewer has read the EWM story and acceptance criteria
  • the reviewer certifies the acceptance criteria below reflect the criteria in EWM

Acceptance Criteria

This list is for ease of reference, and does not replace reading the EWM story as part of the review. Verify this list matches the EWM story before reviewing.

NOTE This only handles the first defect. The second defect will be handled in a separate PR

  • running reduction on the same run twice in a row should not cause errors (see test instructions)

Copy link

codecov bot commented Nov 14, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 96.54%. Comparing base (bb8cf23) to head (a1f4d80).
Report is 42 commits behind head on next.

Additional details and impacted files
@@             Coverage Diff             @@
##             next     #499       +/-   ##
===========================================
+ Coverage   59.51%   96.54%   +37.03%     
===========================================
  Files          64       64               
  Lines        4836     4836               
===========================================
+ Hits         2878     4669     +1791     
+ Misses       1958      167     -1791     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@rboston628 rboston628 marked this pull request as ready for review November 14, 2024 19:22
@darshdinger
Copy link
Contributor

Testing


  1. First on next run Reduction with run number 46680 and insure I have a normalization locally:
    image

  2. Reproduce error by running Reduction once and then again:
    1st time:
    image

2nd time (got error):
image

  1. Still on next rename normalization folder:
    image

  2. Artificial Normalization screen:
    image

  3. Switch to this branch and reRun Reduction:
    image

  4. Rename normalization folder:
    image

  5. Rerun Reduction:
    image

  6. And then Rerun to see if the same error occurs:
    image

Copy link
Contributor

@darshdinger darshdinger 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 man!

@rboston628 rboston628 merged commit c92d475 into next Nov 14, 2024
8 checks passed
@rboston628 rboston628 deleted the ewm8230-skipview branch November 14, 2024 20:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants