Skip to content

add table visibility control via dune_public config#57

Merged
a-monteiro merged 7 commits intomainfrom
03-17-add-table-visibility-control-via-dune_public-config
Mar 18, 2026
Merged

add table visibility control via dune_public config#57
a-monteiro merged 7 commits intomainfrom
03-17-add-table-visibility-control-via-dune_public-config

Conversation

@a-monteiro
Copy link
Copy Markdown
Member

@a-monteiro a-monteiro commented Mar 17, 2026

Adds meta.dune.public to control table accessibility — same ergonomics as datashare config so all Dune-specific settings live in one place under meta.dune.

Set it in the model config block:

{{ config(
    materialized = 'table'
    , meta = {"dune": {"public": true}}
) }}

Tables default to private. On prod, visibility is applied two ways: for full builds (table materialization or --full-refresh), extra_properties is injected into CREATE TABLE ... WITH (...) via a properties() macro override; for incremental runs, an ALTER TABLE SET PROPERTIES post-hook keeps it in sync. Both are no-ops outside the prod target.

Fixes DWH-280

Copy link
Copy Markdown
Member Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

@a-monteiro a-monteiro marked this pull request as ready for review March 17, 2026 19:58
@cursor

This comment was marked as off-topic.

@a-monteiro a-monteiro requested review from 0xRobin and jeff-dude March 18, 2026 00:56
@a-monteiro a-monteiro requested a review from 0xRobin March 18, 2026 12:48
@a-monteiro a-monteiro dismissed 0xRobin’s stale review March 18, 2026 15:56

already addressed

@a-monteiro a-monteiro merged commit d5eddfe into main Mar 18, 2026
@a-monteiro a-monteiro deleted the 03-17-add-table-visibility-control-via-dune_public-config branch March 18, 2026 15:57
msf added a commit that referenced this pull request Apr 2, 2026
Companion doc for set_table_visibility macro (#57). Covers meta.dune.public
config, folder-level config, combining with datashare, and raw SQL fallback.
jeff-dude added a commit that referenced this pull request Apr 2, 2026
## Summary

Companion documentation for the `set_table_visibility` macro added in
#57. Adds `docs/dune-table-visibility.md` and links it from the README
docs index.

Covers:
- `meta.dune.public` config (the sugar over `extra_properties`)
- Folder-level config via `dbt_project.yml`
- Prod-only behavior
- Combining with datashare
- Raw SQL fallback for existing tables

---------

Co-authored-by: jeff-dude <102681548+jeff-dude@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants