-
Notifications
You must be signed in to change notification settings - Fork 35
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
How to adjust models? #43
Comments
Hi @nbenezri would you be able to share a snippet of your variables in your root dbt_project. Defining the variables the way you have shown above should work. I would be curious if maybe there is an error with how the variables are defined within your project. |
In
|
Thanks so much for sharing these details @nbenezri. The declaration of these variables seems accurate 🤔 I am especially curious since you mentioned the |
They are. and they are appearing in the staging schema.
|
Hi @nbenezri my apologies as I misread your initial question. I was under the assumption you were unable to replicate the metadata fields in the staging models. Currently the package only brings the customer metadata fields through to the final model. The other metadata fields are restricted to the staging models. If you are looking to bring other metadata fields through to the final models we can use this issue as a feature and plan to incorporate them in a future release. For the time being, if you wanted to bring in the metadata fields prior to our feature update I would recommend either one of the following options:
models:
stripe:
stripe__invoice_line_items:
+enabled: false You are correct that since the package contents are stored in the |
Is there a more detailed walkthrough on how to recreate/fork a model to the side? EDIT I will be more specific, working on the customers model:
I now get
A few questions:
copying the dbt_project from dbt_packages doesn't work...
|
Hi @nbenezri if you wanted to fork the repo and make your changes directly in your own fork that may be easiest. You can then install your fork (with your custom changes) instead of our package. You would use the following syntax in your packages:
- git: https://github.com/nbenezri/dbt_stripe.git
revision: custom-branch
warn-unpinned: false This way you can make whatever changes you want directly in your own codebase and it will still be installed as a package. This will allow you to circumvent the need for disabling and copy/pasting which can result in a bunch of headache and compilation errors as dbt has a bunch of rules with disabling and having models with the same name. You make a great point though that it would be helpful for us to possibly put together a guide for customers on how to fork or edit package code if needed. |
Work like a charm! thanks! |
Brilliant! Yeah if you wanted to share your fork I would be happy to take a look. We have also had a few individuals in the past open PRs from their forks to contribute the code back into the package. I can look through your updates and if they make sense for the larger user base, we can work to incorporate it! |
Repo is private - can't share it. But here are the files. |
BTW I know this is not your field anymore, but I push this change into master and the schedule in fivetran transformation is acting up.
If you have any idea why it unable to fork it... |
Hey @nbenezri no worries at all. Hopefully I can help. What are the contents of your |
It should work as both repo's ( |
Would love some help @fivetran-joemarkiewicz |
@nbenezri do the package installs on |
Locally it works. Actually, until the issue is solved, I use crontab from my server instead of Fivetran's transformation schedule. |
Since it works locally, I imagine this is something that needs to be addressed at the Fivetran Transformations layer. Unfortunately, I am not part of this team but I would recommend opening a Support Ticket (if you have not already) to help resolve this issue. I apologize I am unable to help address this, but I do believe it has something to do with how Fivetran Transformations talks to other repos. |
Closing this issue out as we have now introduced the ability to bring metadata fields into select staging models! |
After changing the metadata variables I saw not all columns are showing in the destination transformation schema. So I went and edit them myself in dbt_packages/stripe/models. however it did not do anything, not even with
--full-refresh
. I guess this is somewhat related todbt_packages
being in.gitignore
.Am I allowed to change it? if I change it - will it work?
I don't want to break stuff.
The changes I've done to the dbt_project.yml are:
The text was updated successfully, but these errors were encountered: