Skip to content

chore: env management overhaul#9408

Draft
AdityaHegde wants to merge 8 commits into
mainfrom
feat/env-edit-session
Draft

chore: env management overhaul#9408
AdityaHegde wants to merge 8 commits into
mainfrom
feat/env-edit-session

Conversation

@AdityaHegde
Copy link
Copy Markdown
Collaborator

@AdityaHegde AdityaHegde commented May 7, 2026

We have multiple places where we read .env and assign variables for secrets. This leads to fragmented code especially with the new ducklake form changes.

Adding a service to manage env variables.

  1. EnvStore manages the full list of variables. Has hooks for getter and setter so that in future we can separate the file write and admin API calls.
  2. EnvEditSession manages the variables in flight during an edit. Managed which variables are assigned so that new env vars that come during the add data process is not overwritten.
  3. This also allows for yaml construction and env assignment to happen in a single method, compileConnectorYAML. This makes things like ducklake utils to not worry about env, just focus on attach.

Checklist:

  • Covered by tests
  • Ran it and it works as intended
  • Reviewed the diff before requesting a review
  • Checked for unhandled edge cases
  • Linked the issues it closes
  • Checked if the docs need to be updated. If so, create a separate Linear DOCS issue
  • Intend to cherry-pick into the release branch
  • I'm proud of this work!

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.

1 participant