Inconsistencies between python/cython groupby.agg behavior
This is pretty ugly, but tentatively is sufficient to make #34997 pass.

The upshot is that we have two problems:

1) in libreduction setting `setattr(cached_ityp, '_index_data',  islider.buf)` silently does the wrong thing for EA-backed indexes
2) when we go through the non-libreduction path, we do things slightly differently, which requires more patches to get tests passing.

cc @WillAyd

> you are right, this is not pretty.

it started off even worse.

> does this have a test that is added that doesn't work now?

No.  The motivation is to get #34997 working (which is needed in order to upgrade to cython3 when its eventually released) This is also prerequisite to killing off the _index_data kludge if u can rebase will have a look rebased per request > do we have tests that show the inconsistency now? and how does this fix it?

This does not fix anything that is broken _in master_.  But under #34997 (which is needed for cy3 compat), some paths that currently go through cython will instead go through python, and would _then_ fail.
 > > do we have tests that show the inconsistency now? and how does this fix it?
> 
> This does not fix anything that is broken _in master_. But under #34997 (which is needed for cy3 compat), some paths that currently go through cython will instead go through python, and would _then_ fail.

maybe i am not following everything, but do we *need* to use cy3 in 3.9? > maybe i am not following everything, but do we need to use cy3 in 3.9?

i hope not; cy3 isnt even out yet > > maybe i am not following everything, but do we need to use cy3 in 3.9?
> 
> i hope not; cy3 isnt even out yet

so we *don't* need this rn then? > so we don't need this rn then?

correct AFAIK closing in favor of #34997