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

serialize inferred primary key in manifest.json #9824

Closed
1 task done
dave-connors-3 opened this issue Mar 26, 2024 · 1 comment · Fixed by #10096
Closed
1 task done

serialize inferred primary key in manifest.json #9824

dave-connors-3 opened this issue Mar 26, 2024 · 1 comment · Fixed by #10096
Assignees
Labels
Impact: CA user docs [docs.getdbt.com] Needs better documentation
Milestone

Comments

@dave-connors-3
Copy link
Contributor

dave-connors-3 commented Mar 26, 2024

Housekeeping

  • I am a maintainer of dbt-core

Short description

In #9650, we added a method for models to infer the primary key based on configured tests and/or constraints. We should serialize this as additional metadata in the manifest.json artifact

Acceptance criteria

output of model.infer_unique_key() is written to the manifest.json artifact for each relevant node

Suggested Tests

We already have unit testing on this method! Additional testing will be required for the artifact itself.

Impact to Other Teams

None

Will backports be required?

I don't think so

Context / Additional details

The primary key inference method on ModelNode requires a list of data_tests that apply to the model, which means data_tests must also be parsed by the point that we are able to populate this field on the ModelNode for serialization.

@dave-connors-3 dave-connors-3 added the user docs [docs.getdbt.com] Needs better documentation label Mar 26, 2024
@MichelleArk MichelleArk changed the title [<project>] serialize inferred primary key serialize inferred primary key in manifest.json Mar 26, 2024
@graciegoheen graciegoheen added this to the v1.9 milestone Apr 11, 2024
@FishtownBuildBot
Copy link
Collaborator

Opened a new issue in dbt-labs/docs.getdbt.com: dbt-labs/docs.getdbt.com#5497

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Impact: CA user docs [docs.getdbt.com] Needs better documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants