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

🔬 Add contact/resolve endpoint to assist with channel events still handled in RP #364

Merged
merged 2 commits into from
Oct 2, 2020

Conversation

rowanseymour
Copy link
Contributor

No description provided.

shouldErr func(funcName string, call int) error
real *sqlx.DB
callCounts map[string]int
callCountsMutex *sync.Mutex
Copy link
Contributor Author

Choose a reason for hiding this comment

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

unrelated - just noticed this class can panic if we end up with two threads writing to callCounts at exactly the same time

@@ -128,12 +130,6 @@ func handleModify(ctx context.Context, s *web.Server, r *http.Request) (interfac
return nil, http.StatusInternalServerError, errors.Wrapf(err, "unable to load org assets")
}

// clone it as we will modify flows
Copy link
Contributor Author

Choose a reason for hiding this comment

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

unrelated - this appears to be a turd from copy and pasting from the simulator endpoint

@codecov
Copy link

codecov bot commented Oct 1, 2020

Codecov Report

Merging #364 into master will increase coverage by 0.07%.
The diff coverage is 86.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #364      +/-   ##
==========================================
+ Coverage   54.13%   54.20%   +0.07%     
==========================================
  Files         112      112              
  Lines        8025     8042      +17     
==========================================
+ Hits         4344     4359      +15     
- Misses       2955     2956       +1     
- Partials      726      727       +1     
Impacted Files Coverage Δ
models/events.go 48.35% <ø> (ø)
web/contact/contact.go 69.23% <80.95%> (+7.52%) ⬆️
models/contacts.go 58.42% <100.00%> (-0.08%) ⬇️
models/imports.go 67.44% <100.00%> (ø)
web/ivr/ivr.go 43.71% <100.00%> (ø)
web/surveyor/surveyor.go 53.73% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0fa60d4...653d8f2. Read the comment docs.

Copy link
Member

@nicpottier nicpottier left a comment

Choose a reason for hiding this comment

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

Why is channel required?

@rowanseymour
Copy link
Contributor Author

@nicpottier to set affinity on the URN

@nicpottier
Copy link
Member

But is that always required? Say adding a RapidPro contact manually before a channel exists. Take it that's a different api path?

@rowanseymour
Copy link
Contributor Author

Yeah this endpoint is specifically for a channel interaction - and to be clear it's only for the relayer code in RP that will move to mailroom

@rowanseymour rowanseymour merged commit cbccc73 into master Oct 2, 2020
@rowanseymour rowanseymour deleted the resolve_endpoint branch October 2, 2020 19:53
rasoro pushed a commit to Ilhasoft/mailroom that referenced this pull request Mar 10, 2023
✈️ Always set `sent_on` for W/S/D statuses if not already set
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