-
Notifications
You must be signed in to change notification settings - Fork 726
feat: optimize geolocation and timezone pipes #3816
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
Conversation
Signed-off-by: Gašper Grom <gasper.grom@gmail.com>
|
Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability. Example:
Projects:
Please add a Jira issue key to your PR title. |
2 similar comments
|
Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability. Example:
Projects:
Please add a Jira issue key to your PR title. |
|
Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability. Example:
Projects:
Please add a Jira issue key to your PR title. |
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.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
| FROM activityRelations_deduplicated_cleaned_bucket_union | ||
| WHERE | ||
| platform IN ('git', 'github', 'gitlab', 'gerrit') | ||
| AND memberTimezoneOffset != 0 |
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.
UTC timezone contributors incorrectly filtered out
High Severity
The filter memberTimezoneOffset != 0 incorrectly excludes contributions from members in UTC timezone countries (e.g., Iceland, Ghana, Liberia, Burkina Faso, Mali, Senegal, and 9+ more). The old code used WHERE idx != 0 to check if a country match was found (index > 0 means a match), while the new code filters on the actual timezone value. Since the default for unknown locations is offset 0, and valid UTC countries also have offset 0, legitimate contributions from ~15 countries are now silently dropped.
Signed-off-by: Gašper Grom <gasper.grom@gmail.com>
|
Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability. Example:
Projects:
Please add a Jira issue key to your PR title. |
1 similar comment
|
Your PR title doesn't contain a Jira issue key. Consider adding it for better traceability. Example:
Projects:
Please add a Jira issue key to your PR title. |


Note
Medium Risk
Touches core Tinybird ETL/pipeline SQL and adds new stored columns, so mistakes could skew analytics outputs across buckets and dashboards even though the change is conceptually straightforward.
Overview
Precomputes and persists member geolocation + timezone on all
activityRelations_deduplicated_cleaned_bucket_*datasources by addingmemberCountryCodeandmemberTimezoneOffsetand populating them during theactivityRelations_bucket_clean_enrich_copy_pipe_*copy/enrich step.Refactors enrichment pipes to join
members_sortedand compute org vs member country separately, and updates downstream analytics:contributions_with_local_time.pipenow readsmemberTimezoneOffsetdirectly, whilecontributors_geo_distribution.pipeswitches from fuzzy location parsing to grouping bymemberCountryCodeand mapping viacountry_mapping.Written by Cursor Bugbot for commit f86427c. This will update automatically on new commits. Configure here.