Skip to content

Commit a906018

Browse files
authored
fix: Remove opening file object when validating S3 parquet source (#3217)
* Remove opening the file object Let pyarrow handle opening the path using the filesystem. Signed-off-by: Max Z <[email protected]> * fix: linting error Signed-off-by: Max Z <[email protected]> Signed-off-by: Max Z <[email protected]>
1 parent ae37b20 commit a906018

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

sdk/python/feast/infra/offline_stores/file_source.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -160,9 +160,7 @@ def get_table_column_names_and_types(
160160
if filesystem is None:
161161
schema = ParquetDataset(path).schema.to_arrow_schema()
162162
else:
163-
schema = ParquetDataset(
164-
filesystem.open_input_file(path), filesystem=filesystem
165-
).schema
163+
schema = ParquetDataset(path, filesystem=filesystem).schema
166164

167165
return zip(schema.names, map(str, schema.types))
168166

0 commit comments

Comments
 (0)