-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
fix catalog generation #808
Conversation
dbt/context/common.py
Outdated
"model": node, | ||
"sql": node.get('injected_sql'), | ||
"this": get_this_relation(db_wrapper, project_cfg, profile, node), | ||
"ref": provider.ref(db_wrapper, node, project_cfg, profile, flat_graph) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ref
, sql
should be in the global context
@@ -17,7 +17,9 @@ def load_all(cls, root_project, all_projects): | |||
for loader in cls._LOADERS: | |||
nodes.update(loader.load_all(root_project, all_projects, macros)) | |||
|
|||
return ParsedManifest(nodes=nodes, macros=macros) | |||
manifest = ParsedManifest(nodes=nodes, macros=macros) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tell the ParsedManifest to process itself:
- process refs
- incorporate Schema Spec info
UnparsedManifest.parse() ---> ParsedManifest
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i've started an issue for this here: #821
given the changes on this plus what i sent you about parsing, maybe we should hold off on this. it's not actually causing problems rn, right? |
@cmcarthur yeah, I had to do this because of operations for catalog generation. Specifically, the code that gets |
@drewbanin ok, yeah that sounds fine |
@cmcarthur I made some other changes around operations in this PR. Going to rip them out and revise this PRs description |
Fixes some issues around catalog generation/operations
Changes:
this
to the context for Operations{% macro %}
blocks.dbt docs generate
. This simplifies the code a whole lot