Skip to content
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

Handle empty dataframe in OrgaosMappingCleaner #124

Closed
augusto-herrmann opened this issue Jan 26, 2023 · 0 comments · Fixed by #125
Closed

Handle empty dataframe in OrgaosMappingCleaner #124

augusto-herrmann opened this issue Jan 26, 2023 · 0 comments · Fixed by #125
Labels
bug Something isn't working

Comments

@augusto-herrmann
Copy link
Member

If OrgaosMappingCleaner receives an empty dataframe (e.g. when doing an incremental database load and there is no change in data), it fails with the error

KeyError: "None of [Index(['nan'], dtype='object', name='key_name')] are in the [index]"

It should instead handle gracefully, log the occurrence of an empty dataframe and return without error so that the Airflow task can succeed.

@augusto-herrmann augusto-herrmann added the bug Something isn't working label Jan 26, 2023
augusto-herrmann added a commit that referenced this issue Jan 26, 2023
fixes #124
Co-authored-by: gutaors <gutaors@gmail.com>
augusto-herrmann added a commit that referenced this issue Jan 26, 2023
fixes #124
Co-authored-by: gutaors <gutaors@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant