metacpan-api icon indicating copy to clipboard operation
metacpan-api copied to clipboard

main_module is bad for perl releases

Open haarg opened this issue 10 months ago • 5 comments

Releases of the perl dist have an assortment of modules set as their main_module, such as less or utf8. These values are inconsistent, not useful, and misleading.

The most natural value for the field is probably perl, but that is not actually a module so it could be problematic.

Another option is leaving the field empty.

Whatever value is best, we'll probably need to have a special case for the perl dist. This seems fine to me.

haarg avatar Feb 04 '25 13:02 haarg

Maybe somebody could pop a package perl; at the top of perl.pod (as seen on metacpan)?

guest20 avatar Jun 05 '25 11:06 guest20

Some suggestions (mainly because they're central modules that will never go away): strict, feature, version 😃

Grinnz avatar Jul 05 '25 05:07 Grinnz

maybe selecting the matching perldelta might be better main_module for perl?

What does metacpan use main_module for? Is it just the Release Info link?

guest20 avatar Jul 05 '25 07:07 guest20

perldeltas, like 'perl', are documentation and not modules and thus are not indexed for installation or dependency, and can't be the main module. I'm not sure what specifically it's used for.

Grinnz avatar Jul 05 '25 08:07 Grinnz

It seems to only be in the "how to install the dist" instructions?

https://github.com/metacpan/metacpan-web/blob/aa9554a8202bceca4577834fe8159bdf7ded87ab/root/inc/module_install.tx#L9

I guess it's up to users of the API how they decide to interpret the thing

guest20 avatar Jul 05 '25 08:07 guest20