Skip to content
This repository has been archived by the owner on Nov 4, 2021. It is now read-only.

Make timeout errors more understandable inside workers #465

Merged
merged 7 commits into from
Jun 9, 2021

Conversation

neilkakkar
Copy link
Contributor

@neilkakkar neilkakkar commented Jun 7, 2021

Changes

Add a caller parameter to async guard

This will soon help make it easier to understand what's going on with errors like these: https://sentry.io/organizations/posthog/issues/2358370433/?project=5592816

... and what went wrong with Bigquery in PostHog/bigquery-plugin#9

Checklist

  • Updated Settings section in README.md, if settings are affected
  • Jest tests

Comment on lines 40 to 45
status.info(
'🍿',
wasCachedAlready
? `Refetched action ID ${actionId} (team ID ${teamId}) from DB`
: `Fetched new action ID ${actionId} (team ID ${teamId}) from DB`
)
Copy link
Collaborator

Choose a reason for hiding this comment

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

💯

Copy link
Collaborator

Choose a reason for hiding this comment

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

I think we should leave this in, but at a reduced debug level, which would only be shown with LogLevel.Debug so that normally there's no spam

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sounds good to me

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Actually, involves adding debug to status, so I'll pull it out into a separate PR instead.

@neilkakkar neilkakkar marked this pull request as ready for review June 8, 2021 10:37
@Twixes Twixes added the bump patch Bump patch version when this PR gets merged label Jun 8, 2021
@neilkakkar neilkakkar merged commit 096e988 into master Jun 9, 2021
@neilkakkar neilkakkar deleted the timeoutcaller branch June 9, 2021 09:29
fuziontech pushed a commit to PostHog/posthog that referenced this pull request Oct 12, 2021
PostHog/plugin-server#465)

* add caller to async function guard

* add simple test

* add transforms test
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bump patch Bump patch version when this PR gets merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants