devstats icon indicating copy to clipboard operation
devstats copied to clipboard

Fix company contribution calculation discrepancies in governance data

Open Arunodoy18 opened this issue 1 month ago • 2 comments

  • Add company-level aggregation queries using count(distinct e.id) to both kubernetes and shared project_developer_stats.sql
  • Prevents double-counting when multiple developers from same company work on same GitHub events
  • Ensures consistency between companies table and developer activity dashboards for governance decisions
  • Addresses Istio governance data discrepancy where Google showed 12738 vs 12615 contributions in different views
  • Fixes potential ranking issues for top 5 company contributions across all CNCF projects

Please make sure that you follow instructions from CONTRIBUTING

Specially:

  • Check if all tests pass, see TESTING for deatils.
  • Make sure you've added test coverage for new features/metrics.
  • Make sure you have updated documentation.
  • If you added a new metric, please make sure you have been following instructions about adding new metric.

Arunodoy18 avatar Nov 25 '25 21:11 Arunodoy18

I have done the following changes. If anything is needed please do Tell. Thank you.

Arunodoy18 avatar Nov 25 '25 21:11 Arunodoy18

Looking good at the 1st glance, but I would have to pull that branch and execute on the test database to confirm and only then I can merge and make it default (not speaking about regenerating all projects already existing data) - I can't do this ATM, will do on my next CNCF working. day after the more urgent migration task, so this is added to my backlog.

lukaszgryglicki avatar Nov 26 '25 09:11 lukaszgryglicki

Thanks for the update! Sounds good — go ahead with your migration task first. Whenever you get a chance to review it on the test database, I’m here if you need anything from my side.

Arunodoy18 avatar Nov 26 '25 09:11 Arunodoy18

Any updates on merging? ThankYou.

Arunodoy18 avatar Dec 02 '25 06:12 Arunodoy18

As I said, I can do this after migration. This is not done yet.

lukaszgryglicki avatar Dec 02 '25 06:12 lukaszgryglicki