Sandbox configuration¶
Developer sandbox mode scopes lhp generate / lhp validate to the
pipelines a developer declares in a personal profile and renames the tables
those pipelines produce. It draws on three surfaces: the --sandbox flag,
an optional sandbox: block in lhp.yaml (team policy), and a gitignored
.lhp/profile.yaml (personal scope).
See also
How-to guide: Develop in a sandbox.
Activation flag¶
--sandbox is a boolean flag on lhp generate and lhp validate only.
Invocation |
Behavior |
|---|---|
|
Generates only the in-scope pipelines, with renames applied. |
|
Validates only the in-scope pipelines, with the structured renames applied. |
|
Rejected with a Click usage error (exit code 2): sandbox scope comes from |
Team policy — sandbox: block in lhp.yaml¶
Optional top-level block. When absent, all defaults below apply. A block that
is not a mapping fails with LHP-CFG-062.
Field |
Type |
Default |
Description |
|---|---|---|---|
|
string |
|
Rename strategy. Only |
|
string |
|
Python |
|
list[string] |
— (unrestricted) |
Environments where |
# lhp.yaml
sandbox:
strategy: table
table_pattern: "{namespace}_{table}"
allowed_envs: [dev, tst]
Personal profile — .lhp/profile.yaml¶
Per-developer namespace and pipeline scope, nested under a top-level
sandbox: key in <project-root>/.lhp/profile.yaml. The .lhp/
directory is gitignored. A missing file fails with LHP-IO-025; a malformed
profile (bad YAML, non-mapping root, missing sandbox: key, namespace
regex failure, or empty pipelines list) fails with LHP-CFG-064.
Field |
Type |
Required |
Description |
|---|---|---|---|
|
string |
Yes |
Personal identifier prepended to renamed tables. Must match |
|
list[string] |
Yes |
Non-empty. Exact pipeline names or case-sensitive |
# .lhp/profile.yaml
sandbox:
namespace: alice
pipelines:
- raw_ingestions
- silver_*
Scope resolution¶
Each pipelines entry is expanded against the project’s discovered
pipelines.
Rule |
Behavior |
|---|---|
Glob expansion |
Globs expand with |
Zero-match entries |
Every entry matching zero pipelines is collected; all offenders fold into one |
Monitoring pipeline |
Excluded from glob expansion. An exact entry naming the monitoring pipeline fails with |
Rename semantics¶
table_pattern formats the table leaf only; catalog and schema pass through
unchanged. With namespace alice and the default pattern,
catalog.schema.table becomes catalog.schema.alice_table. The rename set
is exactly the tables the in-scope pipelines produce; matching is
case-insensitive and backtick-aware.
Element |
Rename behavior |
|---|---|
Streaming-table / materialized-view write target |
Leaf renamed. |
Delta-sink |
Leaf renamed. |
Catalog and schema of a renamed table |
Pass through unchanged. |
In-scope reads of a produced (in-scope) table |
Leaf renamed to match the producer. |
Reads of tables produced outside the scope |
Unchanged (read-shared). |
Non-delta sinks and non-delta loads |
Unchanged (no table identity). |
|
Unchanged (dependency ordering only; never emitted in code). |