MCPcopy Create free account
hub / github.com/feast-dev/feast / Project

Class Project

sdk/python/feast/project.py:27–175  ·  view source on GitHub ↗

Project is a collection of Feast Objects. Projects provide complete isolation of feature stores at the infrastructure level. Attributes: name: The unique name of the project. description: A human-readable description. tags: A dictionary of key-value pairs to sto

Source from the content-addressed store, hash-verified

25
26@typechecked
27class Project:
28 """
29 Project is a collection of Feast Objects. Projects provide complete isolation of
30 feature stores at the infrastructure level.
31
32 Attributes:
33 name: The unique name of the project.
34 description: A human-readable description.
35 tags: A dictionary of key-value pairs to store arbitrary metadata.
36 owner: The owner of the project, typically the email of the primary maintainer.
37 created_timestamp: The time when the entity was created.
38 last_updated_timestamp: The time when the entity was last updated.
39 """
40
41 name: str
42 description: str
43 tags: Dict[str, str]
44 owner: str
45 created_timestamp: datetime
46 last_updated_timestamp: datetime
47
48 def __init__(
49 self,
50 *,
51 name: str,
52 description: str = "",
53 tags: Optional[Dict[str, str]] = None,
54 owner: str = "",
55 created_timestamp: Optional[datetime] = None,
56 last_updated_timestamp: Optional[datetime] = None,
57 ):
58 """
59 Creates Project object.
60
61 Args:
62 name: The unique name of the project.
63 description (optional): A human-readable description.
64 tags (optional): A dictionary of key-value pairs to store arbitrary metadata.
65 owner (optional): The owner of the project, typically the email of the primary maintainer.
66 created_timestamp (optional): The time when the project was created. Defaults to
67 last_updated_timestamp (optional): The time when the project was last updated.
68
69 Raises:
70 ValueError: Parameters are specified incorrectly.
71 """
72 self.name = name
73 self.description = description
74 self.tags = tags if tags is not None else {}
75 self.owner = owner
76 updated_time = _utc_now()
77 self.created_timestamp = created_timestamp or updated_time
78 self.last_updated_timestamp = last_updated_timestamp or updated_time
79
80 def __hash__(self) -> int:
81 return hash((self.name))
82
83 def __eq__(self, other):
84 if not isinstance(other, Project):

Calls

no outgoing calls

Tested by 7

test_initializationMethod · 0.72
test_equalityMethod · 0.72
test_is_validMethod · 0.72
test_to_protoMethod · 0.72