mathjazz / pontoon

In-place localization tool
https://pontoon.mozilla.org/
BSD 3-Clause "New" or "Revised" License
3 stars 1 forks source link

Pontoon database includes about 300k rejected translations with no rejected_date #1317

Open mathjazz opened 3 years ago

mathjazz commented 3 years ago

This issue was created automatically by a script.

Bug 1727322

Bug Reporter: @eemeli CC: @mathjazz

Discovered while building historical data for Project Insights, these almost certainly have no effect on normal operations, but make it a bit difficult to generate some of the statistics correctly. Visible with e.g. this query:

SELECT pro.id, pro.name, count(*)
FROM
  base_translation AS tra,
  base_entity AS ent,
  base_resource AS res,
  base_project AS pro
WHERE
  tra.rejected AND tra.rejected_date IS NULL AND
  tra.entity_id = ent.id AND
  ent.resource_id = res.id AND
  res.project_id = pro.id
GROUP BY pro.id
ORDER BY pro.name;

As the creation dates of these translations are rather spread out, it looks like there's some process that updates the rejected field without a corresponding rejected_date change.

mathjazz commented 3 years ago

Comment Author: @eemeli

Dropping the block of 1725648, as the scope of the parent issue was clarified not to include the affected data.