## Problem In **Add pipeline**, the managed DuckLake configuration method (**Select Supabase projects**) lets users pick any project in their organization for the catalog and for storage. For now, managed DuckLake should only use the current project. ## Solution - Rename the option to **Use this Supabase project** and remove the **Catalog project** and **Storage project** selectors. Users still set **Metadata schema** and **Bucket**. - Remove `ducklakeCatalogProjectRef` and `ducklakeStorageProjectRef` from the form schema, default values, and validation rather than hiding them, so the form can't carry another project's ref. `buildDucklakeConfig` sets both `catalogProjectRef` and `storageProjectRef` to the current project ref, which the config builders already receive from the URL. - The bucket list and the **New bucket** dialog always target the current project. The cross-region warning is removed because it can no longer trigger. - `data/replication` (types and API payload mapping) is unchanged. It still sends `project_ref` for the catalog and storage, now always the current project. - Fix in passing: creating a bucket from the dialog now sets the field with `shouldDirty` and `shouldValidate`, so a stale "Bucket is required." error clears. - Edit mode and **Enter connection details** are unchanged. The DuckLake docs page (`apps/docs/content/guides/database/replication/pipelines/ducklake.mdx`) still describes choosing separate projects. It'll be updated in a follow-up PR that should merge after this one ships. ## Review instructions 1. Open a project, go to **Database** > **Pipelines**, select **Add pipeline**, and choose **DuckLake**. 2. Under **Configuration method**, check that the first option is **Use current Supabase project** and that there's no **Catalog project** or **Storage project** selector. 3. Open the **Bucket** list and check that it shows the current project's buckets. **New bucket** creates a private bucket in the current project. 4. Create the pipeline and check that the request sends the current project ref as both `catalog.project_ref` and `storage.project_ref`. 5. Run the unit tests: `cd apps/studio && pnpm vitest run components/interfaces/Database/Replication/DestinationPanel/DestinationForm data/replication` ## Checklist Check all before review: - [ ] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: Danny White <3104761+dnywh@users.noreply.github.com>
Reference Docs
Supabase Reference Docs
Maintainers
If you are a maintainer of any tools in the Supabase ecosystem, you can use this site to provide documentation for the tools & libraries that you maintain.
DocSpec
We use documentation specifications which can be used to generate human-readable docs.
- OpenAPI: for documenting API endpoints.
- SDKSpec (custom to Supabase): for SDKs and client libraries.
- ConfigSpec (custom to Supabase): for configuration options.
- CLISpec (custom to Supabase): for CLI commands and usage.
The benefit of using custom specifications is that we can generate many other types from a strict schema (eg, HTML and manpages). It also means that we can switch to any documentation system we want. On this site we use Next.js, but on Supabase's official website, we use a custom React site and expose only a subset of the available API for each tool.
Contributing
To contribute to docs, see the style guide for how to write a page, and the developers' guide and contributing guide for repo mechanics. If you write with an AI coding agent, use the /write-the-docs skill to draft and /edit-the-docs to revise an existing page.