Skip to content
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

Mark message send to avoid duplicate send on final status update #795

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

norkans7
Copy link
Contributor

@norkans7 norkans7 commented Nov 1, 2024

No description provided.

Copy link

codecov bot commented Nov 1, 2024

Codecov Report

Attention: Patch coverage is 64.28571% with 5 lines in your changes missing coverage. Please review.

Project coverage is 74.52%. Comparing base (d67f20c) to head (2f06a78).

Files with missing lines Patch % Lines
backends/rapidpro/status.go 69.23% 2 Missing and 2 partials ⚠️
backends/rapidpro/backend.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #795   +/-   ##
=======================================
  Coverage   74.52%   74.52%           
=======================================
  Files         111      111           
  Lines       13450    13462   +12     
=======================================
+ Hits        10023    10032    +9     
- Misses       2697     2698    +1     
- Partials      730      732    +2     

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

ts.True(sent)

m = readMsgFromDB(ts.b, msg.ID())
ts.Equal(m.Status_, courier.MsgStatusWired)
Copy link
Member

Choose a reason for hiding this comment

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

this seems wrong but I'm still not getting how a message in this state could be picked up 5 minutes later for retrying

Copy link
Contributor Author

Choose a reason for hiding this comment

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

you mean Failed should not be changed back to Wired?

ts.NoError(err)

m := readMsgFromDB(ts.b, msg.ID())
ts.Equal(m.Status_, courier.MsgStatusFailed)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@rowanseymour any idea why this line fails for package tests but pass for the individual test?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@norkans7 norkans7 marked this pull request as ready for review November 1, 2024 18:33
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