DISTINCT was removed as it significantly hurt the SQL performance. The duplicates are showing because a user has more than 1 usergroup. Have added a bug ticket to explore other options as adding DISTINCT back isn't an viable option. Sites with 100,000 or more users see 600x performance loss (not an exaggeration; going from 10-20ms to seconds).
forge.joomlapolis.com/issues/7531
Below is a current example if 1 million users.
Current: 0.0311 seconds
GROUP BY: 20.4404 seconds
DISTINCT: 154.7703 seconds
More than likely GROUP BY will be our only solution besides maybe changing to a subquery usage.