warren830 opened a new pull request, #8737: URL: https://github.com/apache/incubator-devlake/pull/8737
## Summary - Replace auto-increment ID (`common.Model`) with composite primary keys (`common.NoPKModel`) on `_tool_q_dev_user_report` and `_tool_q_dev_user_data` tables to enable proper deduplication - Switch `db.Create()` to `db.CreateOrUpdate()` in s3_data_extractor so re-extracted data updates existing rows instead of inserting duplicates - Add migration to drop/rebuild tables with new PKs and reset `s3_file_meta.processed` flag to trigger clean re-extraction ## Test plan - [x] `go build ./plugins/q_dev/...` passes - [x] `go test ./plugins/q_dev/...` passes - [ ] Verify migration runs cleanly on dev environment - [ ] Verify `SELECT ... GROUP BY ... HAVING COUNT(*) > 1` returns no duplicates after re-extraction - [ ] Verify Grafana dashboard "Total Credits Used" shows correct value -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
