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

[Core] The schemas context variable has its own page but invocation_args_dict does not #5118

Open
dbeatty10 opened this issue Mar 19, 2024 · 0 comments
Labels
content Improvements or additions to content dbt Core The changes proposed in this issue relate to dbt Core size: medium This change will take up to a week to address

Comments

@dbeatty10
Copy link
Contributor

Link to the page(s) on docs.getdbt.com requiring updates

This page for schemas also exists:
https://docs.getdbt.com/reference/dbt-jinja-functions/schemas

But this page does not exist for invocation_args_dict:
https://docs.getdbt.com/reference/dbt-jinja-functions/invocation_args_dict

Rather, it is within this page instead:
https://docs.getdbt.com/reference/dbt-jinja-functions/flags#invocation_args_dict

Tell us more about this update

So to resolve this discrepancy, it seems like either both should have their own page or neither should have their own page.

Having its own page seems more useful, because then it would be available in the side menu also. It would also show up as the page title when searching through Google search results or Algolia search results.

Example

It would also be useful to have an example that shows how to get the value of one of the CLI args. Here's a couple potential examples for getting the value of the --limit flag and use a default of 999 if it is not found (I'm not sure which works or not):

invocation_args_dict.get("limit", 999)
invocation_args_dict.get("limit") or 999

Important

I'm not sure if either or both of these examples work or not. At least for config.get, I think it needs to be the latter (see #3969), but I'm not sure if that also applies to invocation_args_dict or not.

Reviewers/Stakeholders/SMEs

I can be the stakeholder on this one 😎

Related GitHub issues

I noticed this discrepancy when looking at dbt-labs/dbt-core#9600 (comment) and was researching a context variable that contains the command-line args (which ended up being invocation_args_dict).

This is also related to #5117

Additional information

No response

@dbeatty10 dbeatty10 added content Improvements or additions to content dbt Core The changes proposed in this issue relate to dbt Core labels Mar 19, 2024
@nataliefiann nataliefiann added the size: medium This change will take up to a week to address label Sep 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content Improvements or additions to content dbt Core The changes proposed in this issue relate to dbt Core size: medium This change will take up to a week to address
Projects
None yet
Development

No branches or pull requests

2 participants