incorrect user_id is written to event logs table on sign in
Created by: coury-clark
I noticed while investigating a problem with signouts on s2 that the user_id associated with sign in events doesn't seem to make sense.
SignInAttempted
always writes user_id
0 (this makes sense since we don't have a user context yet)
SignInSucceeded
has the following breakdown on s2:
user_id | count |
---|---|
1 | 46 |
61 | 2 |
131 | 6 |
136 | 2 |
Certainly none of my events (user 23) are in this list, and in general the magnitude doesn't seem to make sense.
Notes: unable to reproduce locally on main by creating a new user and logging in
Here is where the event is triggered https://sourcegraph.sourcegraph.com/github.com/sourcegraph/sourcegraph@dd0ad55a184c686c300ad3c7d4fc6c705e43bd73/-/blob/cmd/frontend/internal/auth/userpasswd/handlers.go?L267:4-267:18