apache / apache/beam

Python BigQuery source fails for timestamps < year 1900

Open
#18,829 0 comments 0 reactions 0 assignees View on GitHub
bug core P3 python
Dominant language
Java
Stars
8.7k
Forks
4.7k
Avg merge
1d 20h
Merged PRs (30d)
196

Description

This seems to be due to Python SDK using 'date.strftime' which has a known limitation.

[https://bugs.python.org/issue1777412](https://bugs.python.org/issue1777412)

This has been fixed for Python 3.3**** 

 

We might want to consider one of the workaround mentioned in the below post to fix BQ for Python 2.7.

[https://stackoverflow.com/questions/10263956/use-datetime-strftime-on-years-before-1900-require-year-1900](https://stackoverflow.com/questions/10263956/use-datetime-strftime-on-years-before-1900-require-year-1900)

 

This affects both Direct and Dataflow runners.

 

 

Imported from Jira [BEAM-4171](https://issues.apache.org/jira/browse/BEAM-4171). Original Jira may contain additional context.
Reported by: chamikara.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.