Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If the case of a dist name changes, PAUSE should use the most recent version #428

Open
neilb opened this issue May 11, 2023 · 1 comment
Labels
indexer How we index uploads

Comments

@neilb
Copy link
Collaborator

neilb commented May 11, 2023

Let's say you have a CPAN distribution with a single module, so the dist name is based on the module's name. If you do one or more releases, and then change the case of the module name, you may (hopefully will) change the name of the distribution as well. When this happens, PAUSE realises that the two different names are the same distribution (good), but in various places it will give the original dist name, rather than the current one. I think it should show the current name.

Example: I released N/NE/NEILB/Acme-NameChangeTest-0.003.tar.gz and then changed the "Test" to "TEST", so now if you look in 02packages you'll see:

Acme::NameChangeTEST              undef  N/NE/NEILB/Acme-NameChangeTEST-0.004.tar.gz

And 06perms is showing:

  Acme::NameChangeTEST,NEILB,f

I look at "View Permissions", "Add Comaintainers", and other places, then the good news is that only one version of this distribution appears (unlike MetaCPAN, for example), but the distname is given as Acme-NameChangeTest, rather than Acme-NameChangeTEST.

@charsbar
Copy link
Collaborator

This is because the packages table has a row like the following

   package: Acme::NameChangeTEST
   version: undef
      dist: N/NE/NEILB/Acme-NameChangeTEST-0.004.tar.gz
  distname: Acme-NameChangeTest                                       (<- This is shown in those pages)

My first guess was this was caused by a bug in one-off-utils/fill_distname.pl, but the script was added to one-off-utils in 2019, so that should not be the reason of this mismatch. Unfortunately, I found much more rows that do not match dist and distname. I don't have a clue why this happened yet.

The distname column is only used in those perms-per-distribution pages. It should be safe if we update the column with the correct dist by another one-off-utils script. But, how should we proceed?

@rjbs rjbs added the indexer How we index uploads label Apr 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
indexer How we index uploads
Projects
None yet
Development

No branches or pull requests

3 participants