Unclear error is printed when wrong event_timestamp column type is used
See original GitHub issueWhen running feast materialize-incremental 2022-01-01T00:00:00
on a parquet source that contains to a string based event_timestamp
column, the following exception is printed.
Materializing 1 feature views to 2022-01-01 00:00:00-08:00 into the sqlite online store.
fake_data_fv from 2021-05-21 02:11:51-07:00 to 2022-01-01 00:00:00-08:00:
Traceback (most recent call last):
File "/home/willem/.pyenv/versions/3.7.7/bin/feast", line 8, in <module>
sys.exit(cli())
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/click/core.py", line 829, in __call__
return self.main(*args, **kwargs)
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/click/core.py", line 782, in main
rv = self.invoke(ctx)
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/click/core.py", line 1259, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/click/core.py", line 1066, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/click/core.py", line 610, in invoke
return callback(*args, **kwargs)
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/click/decorators.py", line 21, in new_func
return f(get_current_context(), *args, **kwargs)
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/feast/cli.py", line 270, in materialize_incremental_command
end_date=datetime.fromisoformat(end_ts),
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/feast/telemetry.py", line 151, in exception_logging_wrapper
result = func(*args, **kwargs)
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/feast/feature_store.py", line 379, in materialize_incremental
tqdm_builder,
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/feast/infra/local.py", line 193, in materialize_single_feature_view
end_date=end_date,
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/feast/infra/offline_stores/file.py", line 208, in pull_latest_from_table_or_query
lambda x: x if x.tzinfo is not None else x.replace(tzinfo=pytz.utc)
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/pandas/core/series.py", line 3848, in apply
mapped = lib.map_infer(values, f, convert=convert_dtype)
File "pandas/_libs/lib.pyx", line 2329, in pandas._libs.lib.map_infer
File "/home/willem/.pyenv/versions/3.7.7/lib/python3.7/site-packages/feast/infra/offline_stores/file.py", line 208, in <lambda>
lambda x: x if x.tzinfo is not None else x.replace(tzinfo=pytz.utc)
AttributeError: 'str' object has no attribute 'tzinfo'
Instead, we should validate types during materialize and print a clearer error message.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:8
- Comments:6
Top Results From Across the Web
insert datetime from csv to postgres error - Stack Overflow
It includes a date, time, and a timezone offset. Apparently, your table's event_time column is timestamp format with date and time only. You ......
Read more >Detect and Fix Data Quality Problems - Fluxicon
The very first check is to make sure that there are no error messages when you import your data set. Error messages can...
Read more >Database Engine events and errors - SQL Server
Consult this MSSQL error code list to find explanations for error messages for SQL Server database engine events.
Read more >How to Get SQL Server Dates and Times Horribly Wrong
One of the problems is that most SQL Server date/time data types are fairly ambiguous. For example, suppose we have a table in...
Read more >How to Effectively Use Dates and Timestamps in Spark 3.0
Spark SQL defines the timestamp type as TIMESTAMP WITH SESSION TIME ZONE , which is a combination of the fields ( YEAR ,...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@sgvarsh the workaround that I found:
Inspecting the file
output.parquet
:Reading the feature view:
@woop do you know some workaround for this issue? It’s a stale issue, but the same problem existis even in the version 0.19.4 =/