lincc-frameworks / python-project-template

Python project best practices for scientific software
https://lincc-ppt.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
61 stars 15 forks source link

Support upper-case letters in project name #487

Open hombit opened 1 month ago

hombit commented 1 month ago

CC @delucchi-cmu

drewoldag commented 3 weeks ago

I took a quick look at this - to make the change to accept uppercase letters is very straightforward. But I have become somewhat confused about how and where we use project and package name since these are both using almost the same regex. (I also recognize that I did this to myself)

Within the context of the output from copier, "project" and "package" names are pretty clear. However, I do have trouble keeping up with the various different ways that PyPI, ReadTheDocs, and CodeCov will manipulate the project name to fit within their standards.

For instance, I believe that PyPI will take the project.name from pyproject.toml and convert to lowercase. And possibly also converts underscores to dashes. Similarly readthedocs will change the project name underscores to dashes.

Maybe these different standards are worth worrying about, and we should just let the user name the package as they like, and allow PyPI, RTD or CodeCov to do what it does??? Doing so would likely break a bunch of the README badges that we've created though...

hombit commented 3 weeks ago

Thank you, @drewoldag, for the investigation. I could be wrong, but I think @delucchi-cmu wanted to create a GitHub repo name with uppercase letters.

For Python-related names, modules, projects, and packages should all be lowercase, I believe.