Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions sdk/python/feast/repo_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,9 @@ class RepoConfig(FeastBaseModel):
"""Repo config. Typically loaded from `feature_store.yaml`"""

project: StrictStr
""" str: Feast project id. This can be any alphanumeric string up to 16 characters.
""" str: This acts as a Feast unique project identifier. This can be any alphanumeric string and can have '_' but can not start with '_'.
You can have multiple independent feature repositories deployed to the same cloud
provider account, as long as they have different project ids.
provider account, as long as they have different project identifier.
"""

provider: StrictStr = "local"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
from sdk.python.feast.repo_operations import is_valid_name


def test_is_valid_name():
test_cases = [
# Valid project name cases
("valid_name1", True),
("username_1234", True),
("valid123", True),
("1234567890123456", True),
("invalid_name_", True),
("12345678901234567", True),
("too_long_name_123", True),
# Invalid project name cases
("_invalidName", False),
("invalid-Name", False),
("invalid name", False),
("invalid@name", False),
("invalid$name", False),
("__", False),
]

for name, expected in test_cases:
assert (
is_valid_name(name) == expected
), f"Failed for project invalid name: {name}"