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
Prevent accepted resubmit #187434120 #4504
base: main
Are you sure you want to change the base?
Conversation
tofarr
commented
Apr 17, 2024
- Do not resubmit if there is already an accepted return with the same SSN.
- Added a feature flag so we can turn this off if it is interfering with testing
Heroku app: https://gyr-review-app-4504-b29341d4c2fa.herokuapp.com/ |
end | ||
|
||
context "when there is already a non-accepted submission in a different account with the same SSN" do | ||
#let!(:efile_submission) { create :efile_submission, :accepted, :for_state, data_source: intake } |
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.
Can we nuke this comment?
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.
LGTM, I think the comment just needs to be removed.
@@ -17,6 +17,13 @@ def save | |||
efile_info = StateFileEfileDeviceInfo.find_by(event_type: "submission", intake: @intake) | |||
efile_info&.update!(attributes_for(:state_file_efile_device_info)) | |||
|
|||
unless Flipper.enabled?(:allow_duplicate_submissions) | |||
if accepted_submissions_with_same_ssn(@intake).any? | |||
Rails.logger.warn "#{@intake.state_code}#{@intake.id} was not submitted because there is already an accepted submission for that ssn" |
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.
is this sufficient notification? would it be worth elevating this to a slack message or sentry warning or similar?