diff --git a/test/test_api_usage.py b/test/test_api_usage.py index b1f8b7476..e01dd0ce7 100644 --- a/test/test_api_usage.py +++ b/test/test_api_usage.py @@ -2241,7 +2241,7 @@ class TestGetRepository(ApiTestCase): def test_getrepo_badnames(self): self.login(ADMIN_ACCESS_USER) - bad_names = ['logs', 'build', 'tokens', 'foo.bar', 'foo-bar', 'foo_bar'] + bad_names = ['logs', 'build', 'tokens', 'foo-bar', 'foo_bar'] # For each bad name, create the repo. for bad_name in bad_names: diff --git a/util/names.py b/util/names.py index 9fb6f3064..d6b4c1886 100644 --- a/util/names.py +++ b/util/names.py @@ -5,7 +5,7 @@ import anunidecode # Don't listen to pylint's lies. This import is required for from uuid import uuid4 -REPOSITORY_NAME_REGEX = re.compile(r'^[\.a-zA-Z0-9_-]+$') +REPOSITORY_NAME_REGEX = re.compile(r'^[a-zA-Z0-9_-]+$') VALID_TAG_PATTERN = r'[\w][\w.-]{0,127}' FULL_TAG_PATTERN = r'^[\w][\w.-]{0,127}$'