REF/API: dont alter Grouper in _get_grouper
This doesn't break any tests and I haven't concocted any new cases in which it would matter, but the logic is hard enough to disentangle (xref #51134) that I can't promise it won't
Thanks @jbrockmendel 