Skip to content

Commit

Permalink
fix: Raise error when not able read of file source spark source (#4005)
Browse files Browse the repository at this point in the history
fix: raise error when not able to read path sparksource

Signed-off-by: tanlocnguyen <tanlocnguyen296@gmail.com>
Co-authored-by: tanlocnguyen <tanlocnguyen296@gmail.com>
  • Loading branch information
ElliotNguyen68 and tanlocnguyen committed Mar 12, 2024
1 parent 5561b30 commit 34cabfb
Showing 1 changed file with 2 additions and 1 deletion.
Expand Up @@ -8,7 +8,7 @@

from feast import flags_helper
from feast.data_source import DataSource
from feast.errors import DataSourceNoNameException
from feast.errors import DataSourceNoNameException, DataSourceNotFoundException
from feast.infra.offline_stores.offline_utils import get_temp_entity_table_name
from feast.protos.feast.core.DataSource_pb2 import DataSource as DataSourceProto
from feast.protos.feast.core.SavedDataset_pb2 import (
Expand Down Expand Up @@ -179,6 +179,7 @@ def get_table_query_string(self) -> str:
logger.exception(
"Spark read of file source failed.\n" + traceback.format_exc()
)
raise DataSourceNotFoundException(self.path)
tmp_table_name = get_temp_entity_table_name()
df.createOrReplaceTempView(tmp_table_name)

Expand Down

0 comments on commit 34cabfb

Please sign in to comment.