From 32e6aa1e7c752551d455c5efd0974a938d756210 Mon Sep 17 00:00:00 2001 From: Daniel Dowler <12484302+dandawg@users.noreply.github.com> Date: Mon, 4 Nov 2024 20:39:28 -0700 Subject: [PATCH] fix: Fixed SparkSource docstrings so it wouldn't used inhereted class docstrings (#4722) Fixed docstrings so it wouldn't used inhereted class docstrings Signed-off-by: dandawg <12484302+dandawg@users.noreply.github.com> --- .../spark_offline_store/spark_source.py | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/sdk/python/feast/infra/offline_stores/contrib/spark_offline_store/spark_source.py b/sdk/python/feast/infra/offline_stores/contrib/spark_offline_store/spark_source.py index 4eb020ebd3..209e3b87e8 100644 --- a/sdk/python/feast/infra/offline_stores/contrib/spark_offline_store/spark_source.py +++ b/sdk/python/feast/infra/offline_stores/contrib/spark_offline_store/spark_source.py @@ -29,6 +29,8 @@ class SparkSourceFormat(Enum): class SparkSource(DataSource): + """A SparkSource object defines a data source that a Spark offline store can use""" + def __init__( self, *, @@ -44,6 +46,25 @@ def __init__( owner: Optional[str] = "", timestamp_field: Optional[str] = None, ): + """Creates a SparkSource object. + + Args: + name: The name of the data source, which should be unique within a project. + table: The name of a Spark table. + query: The query to be executed in Spark. + path: The path to file data. + file_format: The format of the file data. + created_timestamp_column: Timestamp column indicating when the row + was created, used for deduplicating rows. + field_mapping: A dictionary mapping of column names in this data + source to feature names in a feature table or view. + description: A human-readable description. + tags: A dictionary of key-value pairs to store arbitrary metadata. + owner: The owner of the DataSource, typically the email of the primary + maintainer. + timestamp_field: Event timestamp field used for point-in-time joins of + feature values. + """ # If no name, use the table as the default name. if name is None and table is None: raise DataSourceNoNameException()