Composer 2.8.4/2.8.5 made some changes to InstalledVersions.php https://github.com/composer/composer/pull/12233/files composer/composer@ee6dc33
which result in InstalledVersions.php now returning the wrong version (= whatever version was loaded first) for packages
Afaik the only fix is to also scope the ClassLoader.php and use a post-dump script to restore the scoped one (since dumping will discard it) and modify autoload_real.php to also load the scoped one (essentially a very similar fix as what is needed for #1036)
However, I remembered you told me there's a test for it: #1043 (comment) e2e 035
Am I doing something wrong or how is that test able to pass? Or did it not run with those composer versions yet at all?
I guess a PR with no changes just to trigger the CI on every new composer release would be helpful to identify any breaking changes?