(#11803) Add modules_by_path method to environments
There's already a modules method on environments that returns your
modules, but only the first one in the module path. For example, if you
have a modulepath with multiple directories, and a module is in both
directories, you only ever info back about the module in the first
directory in the modulepath. For the module list command we need to
show details about all the modules split up by path.