-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vertica timestamp(0) causes an unable to get column information error in DataHub CLI #5295
Comments
Hi, is there a possibility of receiving an ETA on when this might be resolved? |
Some additional information regarding this issue. In case of timestamp(x) or timestamptz(x) as mentioned, the following warning is raised: The precision argument is initiated in \Lib\site-packages\datahub\ingestion\source\sql\vertica.py:
This calls for the TIMESTAMP class in \Lib\site-packages\sqlalchemy\sql\sqltypes.py:
Which returns the precision error as there's no precision argument defined. |
So an easy fix would be to add the following argument and code line into the class:
Which results in the following schema output:
|
Hi martinontcode! Would you mind opening a PR with the fix so we can move it through review? |
This issue is stale because it has been open for 15 days with no activity. If you believe this is still an issue on the latest DataHub release please leave a comment with the version that you tested it with. If this is a question/discussion please head to https://slack.datahubproject.io. For feature requests please use https://feature-requests.datahubproject.io |
Hi, the issue is still present. Is there a way to fix this from Datahub perspective? |
This issue is stale because it has been open for 30 days with no activity. If you believe this is still an issue on the latest DataHub release please leave a comment with the version that you tested it with. If this is a question/discussion please head to https://slack.datahubproject.io. For feature requests please use https://feature-requests.datahubproject.io |
I submitted a PR attempting to fix this problem. It basically is a hacky implementation of the suggestion @martinontcode made. |
This issue is stale because it has been open for 30 days with no activity. If you believe this is still an issue on the latest DataHub release please leave a comment with the version that you tested it with. If this is a question/discussion please head to https://slack.datahubproject.io. For feature requests please use https://feature-requests.datahubproject.io |
This still is a problem in the current version. Could anybody review and comment on the opened PR? |
Co-authored-by: İnanç Dokurel <[email protected]> Fixes #5295
…ahub-project#6295) Co-authored-by: İnanç Dokurel <[email protected]> Fixes datahub-project#5295
Describe the bug
A warning is received in Datahub CLI while executing ingestion from Vertica DB via Vertica plugin.
Warning output: 'warnings': {'XXX_TABLE': ['unable to get column information due to an error -> __init__() got an unexpected keyword ' "argument 'precision'"]}
It seems that the error is caused when an attribute data type is set to timestamp(0). The error can be bypassed when commenting out the following lines in venv\Lib\site-packages\datahub\ingestion\source\sql\vertica.py,
_get_column_info
function.The created kwargs object precision attribute isn't compatible with the timestamp parameters:
{'timezone': False, 'precision': 0}
, it's possible that the same error would appear when working with timestampz data type.Commenting most likely works as timestamp precision is optional - TIMESTAMP/TIMESTAMPTZ
To Reproduce
Create a table in Vertica including an attribute with timestamp(0):
Execute the pipeline using datahub CLI.
Expected behavior
Load meta from Vertica to file using datahub CLI w/o warnings.
Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: