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

remove run_error from tracking code #817

Merged
merged 5 commits into from
Jul 6, 2018
Merged

Conversation

cmcarthur
Copy link
Member

This branch removes the run_error field from dbt's tracking code.

It uses the new 2-0-0 version of the run_model schema.

Closes #805

Copy link
Contributor

@drewbanin drewbanin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One comment, but looking good to me

dbt/tracking.py Outdated
project,
args,
result_type,
result
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we probably also want to nix result here too, right? This would contain the exception that dbt throws if the project is misconfigured. There are a couple of instances where we pass exceptions in around here

@cmcarthur
Copy link
Member Author

@drewbanin i nixed result as well. can you take a look?

Copy link
Contributor

@drewbanin drewbanin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM if you gave this a spin and confirmed that the events were recorded

@cmcarthur
Copy link
Member Author

test:

select event_id, run_error from fishtown_snowplow.run_model 
where invocation_id in ('5eb37985-587c-4004-9137-a33cbc7ff061', 'bd6142dd-5fac-4c8f-ba55-45140e166011')
limit 10;

returns:

event_id                             | run_error                                                                                                
-------------------------------------+----------------------------------------------------------------------------------------------------------
1cae9a84-181d-4d1c-8e5d-7d24672cbce7 | Database Error in model moby_dick_base (models/moby_dick_base.sql)                                       
                                     :   000904 (42000): 923491e6-b118-44c5-9ab7-7f230349f3cf: SQL compilation error: error line 5 at position 2
                                     :   invalid identifier 'ANOTHER_FIELD_THAT_DOES_NOT_EXIST'
                                     :   compiled SQL at target/run/talk/moby_dick_base.sql
9e906ecb-1daf-45d0-ba3d-8e92347dc50e |                                                                                                          

the first event is on development, second is on this branch. the invocations both have null results

@drewbanin
Copy link
Contributor

@cmcarthur nice! :shipit:

@cmcarthur cmcarthur merged commit 3aab1a5 into development Jul 6, 2018
@cmcarthur cmcarthur deleted the remove-error-tracking branch July 6, 2018 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants