Cherry picks from current/for_cpan_index (flux due to not-yet-clear-policy)

This is an amalgamation of:
- f6fff270
- 293dccfc (corrected version of b63585bd)
- 77cc50d1