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

Copying macro code copies the full contents of the sql file, including other macros #142

Closed
5 tasks
dave-connors-3 opened this issue Aug 21, 2023 · 0 comments · Fixed by #192
Closed
5 tasks
Assignees
Labels
bug Something isn't working
Milestone

Comments

@dave-connors-3
Copy link
Collaborator

Describe the bug

in macros/foo_and_bar.sql

{% macro foo() %}
{% endmacro %}

{% macro bar() %}
{% endmacro %}

if you select a model that uses bar, both macros are copied over since we don't parse the SQL

Steps to reproduce

Expected results

Actual results

Screenshots and log output

System information

Which database are you using dbt with?

  • postgres
  • redshift
  • bigquery
  • snowflake
  • other (specify: ____________)

The output of dbt debug:

<output goes here>

The output of dbt --version:

<output goes here>

Additional context

Are you interested in contributing the fix?

@dave-connors-3 dave-connors-3 added bug Something isn't working triage Tis issue or pull request must be triaged by a project maintainer labels Aug 21, 2023
@nicholasyager nicholasyager self-assigned this Nov 21, 2023
@nicholasyager nicholasyager removed the triage Tis issue or pull request must be triaged by a project maintainer label Nov 21, 2023
@graciegoheen graciegoheen added this to the 0.5.3 milestone Dec 18, 2023
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.

3 participants