Extensions: clarify the identifiers must "Python" id's in the error

Without this, it's not clear what a "valid identifier" means,
ref: #136517.
This commit is contained in:
Campbell Barton
2025-07-24 18:19:13 +10:00
parent 6f2988f0af
commit 0442a9fe0a

View File

@@ -1531,7 +1531,7 @@ def url_retrieve_exception_as_message(
def pkg_idname_is_valid_or_error(pkg_idname: str) -> str | None:
if not pkg_idname.isidentifier():
return "Not a valid identifier"
return "Not a valid Python identifier"
if "__" in pkg_idname:
return "Only single separators are supported"
if pkg_idname.startswith("_"):