Compare commits

...

555 Commits

Author SHA1 Message Date
Romeo Van Snick
fd50ffa7dd Parametrise PythonLibraryEditor 2025-09-12 16:04:06 +10:00
Romeo Van Snick
2880033f06 Update python lib terminology and parametrise API 2025-09-12 15:54:41 +10:00
Romeo Van Snick
87161c6d71 Add shared lib toggle 2025-09-12 12:42:19 +10:00
Romeo Van Snick
89117dbfb0 Remove trailing whitespace 2025-09-12 11:27:36 +10:00
Romeo Van Snick
3a1b93b79d Add python library editor 2025-09-11 20:29:59 +10:00
Romeo Van Snick
2f651e074d Allow passing className to python editor 2025-09-11 20:28:01 +10:00
Romeo Van Snick
54a2642138 Add api endpoints for python library 2025-09-11 20:28:01 +10:00
Romeo Van Snick
d3a74d538d Add fullWidth prop to admin layout 2025-09-11 20:28:01 +10:00
Romeo Van Snick
82b097feb8 Move PythonCodeEditor to separate component 2025-09-11 20:28:01 +10:00
Nicola Mometto
a8f5ff5193 sqlserver rename-table 2025-09-11 11:22:48 +01:00
Nicola Mometto
b8fef1a67f chore 2025-09-11 11:11:17 +01:00
Nicola Mometto
ce6420ebc7 missing require 2025-09-11 11:10:00 +01:00
Nicola Mometto
6f74fd4593 type conversion for mongo 2025-09-11 11:09:47 +01:00
Nicola Mometto
33593abd60 format datetimes for bigq 2025-09-11 10:52:48 +01:00
Nicola Mometto
702bd9a3f2 typo 2025-09-11 10:40:34 +01:00
Nicola Mometto
8284646d15 more parsing for bigq 2025-09-11 10:35:58 +01:00
Romeo Van Snick
1e0246d2f1 Use DataGrid for displaying results 2025-09-11 19:33:17 +10:00
Romeo Van Snick
d82c40a1db Swap buttons 2025-09-11 19:33:16 +10:00
Romeo Van Snick
e39983b3db Add pandas completions 2025-09-11 19:33:16 +10:00
Romeo Van Snick
01f4bcfb43 Allow extension to be passed to CodeEditor 2025-09-11 19:33:16 +10:00
Romeo Van Snick
cae08116f0 Increase indentUnit for python 2025-09-11 19:33:16 +10:00
Romeo Van Snick
a314bb587c Remove color in editor gutter 2025-09-11 19:33:16 +10:00
Romeo Van Snick
09731e48fa Move python execution to separate hook 2025-09-11 19:33:15 +10:00
Romeo Van Snick
cdba119297 Split up ExecutionResult component 2025-09-11 19:32:37 +10:00
Romeo Van Snick
5957b1f5df Add empty and loading state components 2025-09-11 19:32:37 +10:00
Romeo Van Snick
2357bea601 Split off results into separate component 2025-09-11 19:32:37 +10:00
Romeo Van Snick
32281e2096 Move parseCSV to utils 2025-09-11 19:32:36 +10:00
Romeo Van Snick
f17e329af5 Make python editor resizable 2025-09-11 19:32:36 +10:00
Romeo Van Snick
c481f1ceb6 Lay python editor out in two columns 2025-09-11 19:32:36 +10:00
Romeo Van Snick
f63e05fda1 Add first-class PythonTransformSource type 2025-09-11 19:32:36 +10:00
Nicola Mometto
928f6f830b bump 2025-09-11 10:15:33 +01:00
Nicola Mometto
29e936e2f8 chore: Dictionary as root type 2025-09-11 10:15:21 +01:00
Nicola Mometto
802fe0fcfe fix: schema-exists? check 2025-09-11 10:15:21 +01:00
Nicola Mometto
0ae5027542 feat: decode json strings 2025-09-11 10:15:21 +01:00
Nicola Mometto
e64e7ec93b assoc table-schema to data-source 2025-09-11 10:15:21 +01:00
Chris Truter
fcb4ca1f80 Bump to latest submodule 2025-09-11 10:58:11 +02:00
Dan Stone
54695561ad Add a few comments regarding optimistic nature of s3 deletes 2025-09-11 09:41:07 +01:00
Nicola Mometto
e965057f1b fix for clickhouse driver 2025-09-11 08:53:07 +01:00
Nicola Mometto
7ed61da2df feat: json 2025-09-10 17:47:32 +01:00
Nicola Mometto
0fba1b34a9 fix support for clickhouse 2025-09-10 16:37:44 +01:00
Chris Truter
6ca68fc067 Pin to a fixed python-runner, with slightly changed logs 2025-09-10 17:36:27 +02:00
Dan Stone
93bcf2f1b8 Remove some commented out / dead code 2025-09-10 15:39:17 +01:00
Ngoc Khuat
c830ff5164 Start python runner with driver tests (#63335) 2025-09-10 20:51:56 +07:00
Nicola Mometto
97296942ab fixes for bigq rename-table 2025-09-10 12:35:18 +01:00
Nicola Mometto
a9b58f9dd7 fixes for bigq insertion 2025-09-10 12:26:20 +01:00
Nicola Mometto
54d2a79a1a eh, array/dictionary for bigq 2025-09-10 11:43:37 +01:00
Nicola Mometto
4147277e28 kondo 2025-09-10 10:51:33 +01:00
Nicola Mometto
1815fb8afa feat: allow overriding base_type/db_type 2025-09-10 10:51:02 +01:00
Nicola Mometto
058e4b3bc5 wip: filter out nested fields 2025-09-10 10:51:02 +01:00
Dan Stone
8c5cd34ec9 Separate file / s3 lifetimes / writes / reads from http calls (#63294)
- python-runner no longer simulates a single http api that does
everything (incl s3 interaction)
- Separates file lifetimes (shared storage) from execution
- Easier to see how to avoid reading into strings (e.g. for piping into
tmp files, follow up)

Earlier on we had a service that managed much of the I/O, metabase now
coordinates it so it makes little sense pretending there is still
an overall http api.
2025-09-10 10:35:50 +01:00
Nicola Mometto
eea9b658da fix: retrieve meta from appdb 2025-09-09 15:27:51 +01:00
Nicola Mometto
17fb99163f chore: bind cancel-chan 2025-09-09 14:58:37 +01:00
Nicola Mometto
7257a4d1d2 only deal with schemas if schema exist 2025-09-09 11:59:23 +01:00
Nicola Mometto
0287e639b1 fix(mongo): guard against lack of cancel-chan 2025-09-09 11:59:23 +01:00
Nicola Mometto
0999cfab54 wip: DDL/DML for mongo 2025-09-09 11:59:23 +01:00
Nicola Mometto
9e18d5b9f7 stub rename-table for bigquery 2025-09-09 10:49:01 +01:00
Nicola Mometto
9910f6d0ca kondo 2025-09-09 10:45:25 +01:00
Chris Truter
6939615ce2 Merge branch 'master' into proj-python/s01e03 2025-09-08 20:24:26 +02:00
Chris Truter
b7bb799e14 Test for ordering across databasees, if we enable python support 2025-09-08 20:23:57 +02:00
github-automation-metabase
3eb696e22b Update generated docs (master) (#63229)
Co-authored-by: github-actions <github-actions@github.com>
2025-09-08 13:35:50 -04:00
Alexander Polyankin
60da15bf27 Transform list cleanup (#63208) 2025-09-08 13:32:48 -04:00
Noah Moss
3b3e5f91d6 Fix semantic search repair test flake (#63195)
* Use unique doc IDs across semantic search repair tests to fix flakes

* clear gate table before test

* try switching out table name generation
2025-09-08 12:33:29 -04:00
Jeff Bruemmer
0fcff349d1 note on custom expressions (#63249) 2025-09-08 12:08:55 -04:00
Riley Thompson
f8a66a7470 remove use database from snowflake transforms (#63199) 2025-09-08 16:05:57 +00:00
Riley Thompson
4672ea6c34 handle dbrefs properly (#63244) 2025-09-08 10:05:18 -06:00
Konstantin Darutkin
73e4ba5bd8 test: refactor datetime table editing tests (#63239) 2025-09-08 18:47:54 +03:00
Ngoc Khuat
20d91af3a5 proper transform ordering 2025-09-08 22:16:23 +07:00
Ngoc Khuat
2d43e09f84 add tests and polishing 2025-09-08 21:40:26 +07:00
Ngoc Khuat
8cb6965fa7 Table swapping instead of delete then create 2025-09-08 21:40:26 +07:00
Nicola Mometto
1279c1f226 chore: kondo 2025-09-08 12:29:52 +01:00
Nicola Mometto
9efe8835fa typo 2025-09-08 12:22:53 +01:00
Nicola Mometto
23b4d7ece0 types for clickhouse 2025-09-08 12:18:43 +01:00
Nicola Mometto
40e71f4baa fix for redshift 2025-09-08 12:11:36 +01:00
Nicola Mometto
2dd76b303e add session-schema for snowflake 2025-09-08 11:45:37 +01:00
Nicola Mometto
f7eb4ca800 fix ddl for bigquery 2025-09-08 11:34:37 +01:00
Nicola Mometto
f3860aee72 fix bigquery types 2025-09-08 11:34:05 +01:00
Nicola Mometto
5d93b6fe71 fix roundtrip 2025-09-08 11:00:07 +01:00
Chris Truter
f09dbce65d Protect against nil search_vector (#63172)
Co-authored-by: Nathan Voxland <nathan@metabase.com>
2025-09-08 11:51:38 +02:00
Nicola Mometto
0783824721 Merge remote-tracking branch 'origin/master' into proj-python/s01e03 2025-09-08 10:46:17 +01:00
Chris Truter
e6d90444c2 delete old test file 2025-09-08 10:30:48 +02:00
Stas Gavrylov
dabaa3007e WRK-874: List view preview improvements (#63159)
* WRK-874: Populate preview for List View customization with sample values

* WRK-874: Set default and min size for list view on dashboard

* WRK-874: Fix List view card size on the dashboard

* WRK-874: Add e2e test for empty column placeholder

* Fix lint errors

* Add horizontal padding for List view

* Refactor generatePreviewSample
2025-09-08 07:58:43 +00:00
Fraser
00fb1c3841 Dev 780 Provide issue comments by employees to Claude Code (#62476) 2025-09-08 11:30:13 +12:00
Fraser
e7fd61a386 Ensure flaky tests are tagged as flaky (#63157) 2025-09-08 11:02:02 +12:00
github-automation-metabase
a17971e449 chore(sdk): Update published npm version to 0.57.0-alpha.2 (#63210) 2025-09-06 12:28:31 +00:00
Romeo Van Snick
02390555ba Fix join step alignment (#63120)
* Stretch join data sections when needed

* Tweak padding to avoid jump

* Center 'on' in join condition

* Make gap consistent

* Tighten margins to avoid jump

* Tweak padding to make all wells the same height
2025-09-06 15:17:36 +10:00
Riley Thompson
20577becba Include transform dependencies that have not been run yet (#62884) 2025-09-06 04:21:10 +00:00
Nicolò Pretto
4c3656a57b fix(embed-js): bar charts no longer change scale when props change (#63182)
* fix(embed-js): bar charts no longer change scale when props change

* spec

---------

Co-authored-by: Aleksandr Lesnenko <alxnddr@gmail.com>
2025-09-05 23:23:40 +00:00
appleby
cca17f5f4d BOT-310 lower the weight on the :rrf score for semantic search results (#63102)
* BOT-310 lower the weight on the :rrf score for semantic search results

This seems to give a better blend between the :rrf score coming from the semantic search hybrid query and the other
post-search metadata scorers.

* Add with-weights and with-only-semantic-weights test util macros

* Use semantic.tu/with-weights in scoring tests

* Update query tests to use semantic.tu/with-only-semantic-weights

This prevents other metadata scorers from overriding the expected rankings for these tests. The query tests are
largely focused on making sure the basic machinery of semantic queries are working. Tests exercising individual
scorers are in scoring_test.clj

* Add tests for :official_collection and :verified "premium" scorers
2025-09-05 15:49:18 -07:00
github-automation-metabase
f74de7e31e Bump com.google.cloud/google-cloud-bigquery from 2.54.1 to 2.54.2 (#62974)
Inspect dependency changes here: https://github.com/googleapis/java-bigquery/blob/v2.54.2/CHANGELOG.md
2025-09-05 15:17:21 -06:00
Jeff Bruemmer
cb946d095d Update development instance documentation for clarity (#63201) 2025-09-05 21:08:14 +00:00
github-automation-metabase
c4ed3cac1d Bump net.snowflake/snowflake-jdbc-thin from 3.26.0 to 3.26.1 (#62976)
Inspect dependency changes here:
2025-09-05 21:02:29 +00:00
github-automation-metabase
2e184e6c48 Bump org.clojure/clojure from 1.12.1 to 1.12.2 (#62973)
Inspect dependency changes here: https://github.com/clojure/clojure/blob/clojure-1.12.2/changes.md
2025-09-05 14:47:03 -06:00
github-actions[bot]
71f7fe60f1 Fix: No drill-thru to filter a table by clicking a NULL FK value (#62569)
Fixes #35561

We currently don't allow filtering on null foreign key values, but that is a reasonable thing to want to do.  This extends the foreign key drill to support null values.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-authored-by: Claude Code[bot] <noreply@anthropic.com>
Co-authored-by: William Zimrin <william@metabase.com>
2025-09-05 20:31:44 +00:00
William
c80fea1587 Native Query Snippet Params (#62283)
Native query snippets get parameterization, using familiar `{{...}}` syntax. Snippets can use other snippets.
2025-09-05 20:05:57 +00:00
github-automation-metabase
50cb92e548 Bump org.apache.arrow/arrow-memory-core from 17.0.0 to 18.3.0 (#62654)
Inspect dependency changes here:

Co-authored-by: bryan <bryan.maass@gmail.com>
2025-09-05 19:50:54 +00:00
github-automation-metabase
b5f5624007 Bump io.netty/netty-common+buffer from 4.2.3.Final to 4.2.4.Final (#62262)
* Bump io.netty/netty-common from 4.2.3.Final to 4.2.4.Final

Inspect dependency changes here:

* typo

---------

Co-authored-by: bryan <bryan.maass@gmail.com>
2025-09-05 19:11:25 +00:00
github-automation-metabase
b514c93c50 Update generated docs (master) (#63153)
Co-authored-by: github-actions <github-actions@github.com>
2025-09-05 15:05:21 -04:00
github-automation-metabase
f9614edfdf Bump djblue/portal from 0.60.2 to 0.61.0 (#62643)
Inspect dependency changes here: https://github.com/djblue/portal/blob/0.61.0/CHANGELOG.md
2025-09-05 18:52:29 +00:00
github-automation-metabase
21325c4366 Bump com.facebook.presto/presto-jdbc from 0.293 to 0.294 (#62975)
Inspect dependency changes here:
2025-09-05 12:28:17 -06:00
github-automation-metabase
b37c60a342 Bump org.apache.sshd/sshd-core from 2.15.0 to 2.16.0 (#62647)
Inspect dependency changes here:
2025-09-05 12:11:21 -06:00
lbrdnk
4a01316597 Ensure thread performing migration finishes first (#63184) 2025-09-05 16:55:55 +00:00
Sébastien
eb474fbf52 Closes EMB-779 content translation is now case insensitive (#63171) 2025-09-05 17:49:05 +02:00
Sébastien
d90fcce25b Closes EMB-780 selected cell color in embedding dark mode (#63163) 2025-09-05 17:48:41 +02:00
github-automation-metabase
9733cd683a Bump net.thisptr/jackson-jq from 1.4.0 to 1.5.0 (#62646)
Inspect dependency changes here:

Co-authored-by: bryan <bryan.maass@gmail.com>
2025-09-05 15:27:35 +00:00
github-automation-metabase
8462072dfd Bump io.github.metabase/hawk from 1.0.7 to 1.0.11 (#62644)
Inspect dependency changes here:

Co-authored-by: bryan <bryan.maass@gmail.com>
2025-09-05 15:27:18 +00:00
Riley Thompson
c482aa6f03 Create schemas if needed for transforms (#62786)
* Unpolished WIP hackathon code for additional driver support

* fix kondo

* add transforms/table featuer for supported drivers

* fix transforms for dbs with no schema

* rename transform datasets to prevent foreign key overlap

* Add clickhouse support

* fix clickhouse tests

* fix redshift tests

* fix bigquery failures

* kondo and filter tests by feature

* fix transform dataset for bigquery

* fix sqlserver transforms with joins

* fix clickhouse order by when no non nullable field is available

* add more complex test with join, filter, aggregation and ordering

* use different metadata provider

* filter for left join feature in test

* improve sqlserver compile-transform

* done use legacy mbql in test, refactor normalize-name

* clean up

* add sqlserver error test

* Squashed commit of the following:

commit a11b602e19
Author: Romeo Van Snick <romeo@romeovansnick.be>
Date:   Thu Aug 21 17:44:13 2025 +1000

    Add message when a new transform will be created

commit 2cfdbfaba3
Author: Romeo Van Snick <romeo@romeovansnick.be>
Date:   Thu Aug 21 17:37:36 2025 +1000

    Allow creating values in schema form select

commit 17ff4dcb3f
Author: Romeo Van Snick <romeo@romeovansnick.be>
Date:   Thu Aug 21 16:51:13 2025 +1000

    Allow selecting schemas always, not only when there are schemas

* create schemas

* fix redshift

* add snowflake

* add sqlserver

* add clickhouse

* add bigquery

* Add test

* add default impl

* fix redshift tests

* Move SchemaFormSelect to components folder

* Allow creating schemas in the target update modal

* Allow initial value in SchemaFormSelect

* Only render schema field when the database supports :schemas

* Do not render new schema item if value is empty

* Add unit tests for SchemaFormSelect

* Add e2e tests for schema creation

* check schema exists first

* fix sql jdbc schema exists and add create schema permissions test

* update changelog

* parse query and add into for sqlserver

* add type hints for linter

* Address comments

* realize bigquery execute-raw-queries

* Disable target schema link if it does not exists (yet)

* Add tooltip when schema is new

* Use hydrated table from transform

* Add e2e tests

* Allow existing schema link to render as enabled even when table does not exist yet

* Do not add default to databaseId

* Add tests for existing schema with new table

* Fix e2e test

* address comments

* rename connection-details to conn-spec

* Compare against null not empty string

* use find first

* Await request to avoid flakiness in hover

---------

Co-authored-by: Timothy Dean <timothy@timothydean.dev>
Co-authored-by: Romeo Van Snick <romeo@romeovansnick.be>
2025-09-05 11:17:51 -04:00
metamben
c621b64c2f Add last_run, next_run and tag id filters (#62993)
* Add last_run, next_run and tag id filters

Closes QUE-2156

* Placate kondo

* Test with scheduled jobs and filtering by tags

* Fix next_run_start_time test

* Return run timestamps as timezone localized strings

* Handle Zulu

* Prepare job list table for next_run and transforms

* Add JobListParams type and use it in getJobListUrl

* Add new parameters to listTransformJobs handler

* Parse params and pass them down on job list page

* Add filters to job list page

* Add tooltipPosition prop to Icon

* Add TimezoneIndicator component

* Allow rendering React nodes in table headers

* Add timezone indicators to job list and transform list

* Add timezoneToUTCOffset helper

* Add timezone to cron explanation

* Format timestamps as ISO-8601 strings with timezone

* Add next run timestamp

* Hide transform count in list for now

* Add next_run to TransformJob

* Add timezone indicators to run list

* Avoid wrapping timestamps in run list

* Move shared widgets to transforms/components

* Allow passing available shortcuts to filter picker

* Disable shortcuts that are in the past for Next run, which is always in the future

* Add e2e test for filters

* Add UTC offset in tests

* Report run timestamps in UTC and expose system timezone

The system timezone is exposed in /api/session/properties as "system-timezone".

* Expose system-timezone to admins only

* Fix setting docstring

* Fix serdes baseline-comparison-test

* Make transform_job API return run timestamps in UTC

* Placate kondo

* Timezone

* Use system-timezone instead of report-timezone

* Add tests

* Fix test string

---------

Co-authored-by: Romeo Van Snick <romeo@romeovansnick.be>
Co-authored-by: Alexander Polyankin <alexander.polyankin@metabase.com>
2025-09-05 15:11:26 +00:00
github-automation-metabase
9275b7fb84 Bump net.thisptr/jackson-jq from 1.4.0 to 1.6.0 (#62972)
Inspect dependency changes here:
2025-09-05 09:11:02 -06:00
Chris Truter
bda65e63db bump python-runner 2025-09-05 16:19:23 +02:00
Nicola Mometto
74d6c3f356 more fixes 2025-09-05 15:03:36 +01:00
Nicola Mometto
815d7a3186 fixes 2025-09-05 14:41:40 +01:00
Dennis Schridde
7e0f54bb73 Cache Store OpenAPI description only for 5min (#63168)
The Store API's OpenAPI description (OAD) can change over time, but
Metabase's Store client would not notice.  For example, the client
would fail a HTTP request, not because the server rejected it, but
because the client "believes" it needs to send a field that the server
no longer requires.

Instead of caching the client, and thus OAD, for the whole lifetime of
the Metabase instance, cache it only for 5min.

Fixes: 1dd56e5f14
References: https://metaboat.slack.com/archives/C010ZSXQY87/p1757002462314229
2025-09-05 15:37:19 +02:00
Nicola Mometto
92171ab506 fix: cleanup 2025-09-05 14:33:05 +01:00
Nicola Mometto
4fc51375be add test 2025-09-05 14:32:48 +01:00
Nicola Mometto
de8a48277f more generic types 2025-09-05 14:28:48 +01:00
Nicola Mometto
dad98c137d fix test 2025-09-05 14:08:43 +01:00
Nicola Mometto
68d9786697 Merge remote-tracking branch 'origin/master' into proj-python/s01e02 2025-09-05 13:59:54 +01:00
Nicola Mometto
db02774c9c for snoflake and sqlserver too 2025-09-05 13:52:17 +01:00
Phoomparin Mano
ef5e78f979 feat(embed-js): append entity-types=model to embed flow code snippet if the instance has over 2 models (#63068) 2025-09-05 19:49:50 +07:00
Nicola Mometto
3b955d9067 feat: per driver impl 2025-09-05 13:40:03 +01:00
Riley Thompson
f4d3359e33 Remove driver/set-use-database in favour of setting the DB in the jdbc spec (#63047) 2025-09-05 08:38:17 -04:00
Nicola Mometto
6b190fdcb1 unused 2025-09-05 11:43:31 +01:00
Nicola Mometto
d3d865dda9 fix tests 2025-09-05 11:42:58 +01:00
Nicola Mometto
558c69ee84 simpler 2025-09-05 11:41:31 +01:00
Nicola Mometto
86bc79d826 typo 2025-09-05 11:41:31 +01:00
Nicola Mometto
6739de6bfc bump 2025-09-05 11:41:31 +01:00
Nicola Mometto
f21fda68f1 feat: use new methods 2025-09-05 11:41:31 +01:00
Nicola Mometto
350561daf9 add new type->database-type 2025-09-05 11:41:31 +01:00
Nicola Mometto
cc99a79835 root-type instead of upload-type 2025-09-05 11:41:31 +01:00
Alexander Polyankin
9be149e22f Fix flaky e2e test (#63128)
* attempt to fix

* Try to fix a flaky test

* Try to fix a flaky test
2025-09-05 06:36:11 -04:00
Alexander Polyankin
a283c947aa Fix filtering on questions after dashboard drills when there are no perms to create queries (#63074)
* Pass cardId and dashboardId

* Pass cardId and dashboardId

* Pass cardId and dashboardId

* Fix flaky test

* E2E test

* E2E test
2025-09-05 06:35:47 -04:00
Timofey Kachalov
ab4e737c31 feat(sdk): Add disc/memory caching for hosted bundle on top of etag caching (#63014) 2025-09-05 14:32:34 +04:00
Phoomparin Mano
4a1ce5d04f Send CORS headers for localhost regardless of whether SDK is enabled or not (#61747) 2025-09-05 17:17:52 +07:00
Timofey Kachalov
34f1e6811f Add dev.md placeholder for embedding-sdk-bundle folder (#63160) 2025-09-05 14:05:25 +04:00
Ngoc Khuat
8a5c220e5c add scheduled job e2e tests 2025-09-05 16:59:07 +07:00
Nicola Mometto
daeb777e4d fix: sort data-rows 2025-09-05 10:57:16 +01:00
Nicola Mometto
708f4696ca move utils into transforms.util 2025-09-05 10:50:03 +01:00
Nicola Mometto
fc453f6bbc chore: move insert-from-source into! driver 2025-09-05 10:31:02 +01:00
Dan Stone
f50d99d709 Pass run-id to /logs endpoint 2025-09-05 09:29:03 +01:00
Chris Truter
c19e0fa75f Date times can roundtrip losslessly and custom metadata is supported 2025-09-05 09:53:44 +02:00
Ryan Laurie
805e5beb8b Add base color prohibition to stylelint (#63091)
* add base color rule to stylelint

* allow in colors file

* lint in CI

* better highlighting

* css fixes

* fix all improper color use

* Update frontend/lint/stylelint-rules/no-base-colors.js

Co-authored-by: Phoomparin Mano <poom@metabase.com>

* Update Loki Snapshots

* fix color name

* Update Loki Snapshots

---------

Co-authored-by: Phoomparin Mano <poom@metabase.com>
Co-authored-by: Metabase Automation <github-automation@metabase.com>
2025-09-04 16:45:59 -06:00
Fraser
246b6534a1 Run type check with increased space to avoid OOM (#63115) 2025-09-05 09:42:13 +12:00
bryan
a532fe0e28 put back the try to catch missing reload mw (#63142) 2025-09-04 21:23:59 +00:00
Robert Kosara
83dc4947f4 Add section about new connection string at top of db settings (#63143)
* Add section about new connection string at top of db settings

* Missed MariaDB…
2025-09-04 14:05:23 -07:00
Aleksandr Lesnenko
8d77a4f153 inline dashcard parameter can only be mapped to the card (#63051)
* inline dashcard parameter can only be mapped to the card, fix mapping mode hides other inline parameters

* update spec

* review
2025-09-04 15:36:46 -04:00
Jeff Bruemmer
92febb9f2b docs - clarify data collection for Metabase editions (#63138)
* Clarify data collection for Metabase editions

* Update docs/usage-and-performance-tools/usage-analytics.md
2025-09-04 15:03:55 -04:00
Phoomparin Mano
92267df836 fix(embed-js): copywriting improvements for embed flow (#63126) 2025-09-05 01:52:55 +07:00
eliotmetabase
7b4ed715ae Fix math to calculate scatter bubble diameter (#63104)
* Fix math and update comment

* Update Loki Snapshots

---------

Co-authored-by: Metabase Automation <github-automation@metabase.com>
2025-09-04 09:39:10 -07:00
Dan Stone
fe9b74f261 Remove stdout/err from clj side (single :events output is used now) 2025-09-04 17:38:30 +01:00
Dan Stone
3f720c9624 Read new events jsonl file and use that for the message 2025-09-04 17:34:57 +01:00
Jeff Bruemmer
207cbffc05 notes (#63097) 2025-09-04 12:06:25 -04:00
Ngoc Khuat
0f2d049daf CI for Python Runner (#63113) 2025-09-04 21:54:04 +07:00
github-automation-metabase
cd962a792e Update generated docs (master) (#63106)
Co-authored-by: github-actions <github-actions@github.com>
2025-09-04 10:52:23 -04:00
metamben
55ab852f4b Add transform dependencies and job transforms endpoints (#62776)
* Add transform dependencies and job transforms endpoints

* Add API handler for /api/ee/transform/:id/dependencies

* Add API handler for /api/ee/transform-job/:id/transforms

* Add description to TitleSection

* Add Dependencies section to transform page

* Add transform order to job page

* Invalidate transform jobs when adding tags to transforms

* Add empty state for job transforms

* Add e2e test for transform and job dependencies

* Fix type for job dependencies component

* transform ordering is well defined

* don't sort whole list when we just need the first element

* make new function private

* Use neg?

* Remove unused require

* use a sorted map instead of scanning for the earliest transform each time

* extend docstring

* use ->

* update docstring again

Co-authored-by: metamben <103100869+metamben@users.noreply.github.com>

---------

Co-authored-by: Romeo Van Snick <romeo@romeovansnick.be>
Co-authored-by: William Zimrin <william@metabase.com>
2025-09-04 14:11:57 +00:00
Phoomparin Mano
1280bb454d feat(sdk): native questions should hide filter and summarize from toolbar (#63082) 2025-09-04 20:56:05 +07:00
Nicola Mometto
3d295d8025 unused 2025-09-04 14:40:34 +01:00
Nicola Mometto
456dc422fc don't go through qp for create-table/drop-table 2025-09-04 14:34:21 +01:00
Alexander Polyankin
500e039023 When navigating with browser back/forward buttons, re-run the query only when the existing query results are dirty (#63092) 2025-09-04 09:22:45 -04:00
Alexander Polyankin
3075c57bf4 Add CurrencyPicker to places where you can change the semantic type (#63032)
* Add CurrencyPicker

* Add currency picker

* Add currency picker

* Fix flaky test

* Fix flaky test

* E2E test

* E2E test

* E2E test
2025-09-04 08:56:14 -04:00
Alexander Polyankin
cd290b0daa Fix buttons focus state (#63089) 2025-09-04 08:55:32 -04:00
Abed Habli
7dceeb13b8 docs: Typo in Embedded JS (#63119)
* Typo

* quick fix
2025-09-04 14:53:10 +02:00
Abed Habli
686a52c702 docs: add browser embedding in JS and background-light theme token (#63012)
* Update embedded analytics JS docs to include browser

* small update

* new appearance setting

* Update docs/embedding/embedded-analytics-js.md

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>

* Apply suggestion from @jeff-bruemmer

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>

* Apply suggestion from @jeff-bruemmer

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>

* update on the browser

---------

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>
2025-09-04 14:11:46 +02:00
Phoomparin Mano
788ef138b0 Add the "Enable to Continue" button to explicitly enable embedded analytics JS (#63054) 2025-09-04 18:45:12 +07:00
Filipe Silva
c5fbd85f0b fix: match filter names in metabase.driver.sync (#63114) 2025-09-04 12:34:58 +01:00
Nicola Mometto
008c87b572 automatically parse datetime fields 2025-09-04 12:18:02 +01:00
Nicola Mometto
b21d3365b7 wip: pass upload_type to manifest 2025-09-04 12:07:55 +01:00
Dan Stone
a639f6bbec Metrics for semantic search indexer/DLQ (#62915)
* WIP

* Use ee-search-gate-max-batch-size

* Gate metrics test

* Fix handling of pg 57014 error state

* Remove redundant require

* Unrelated cleanup

* dlq metrics test

* Indexer loop metric test

* Indexer metric tests

* Fix poll time

* Metric collector and test

* test name

* whitespace

* Fixture

* Suggestions

---------

Co-authored-by: lbrdnk <lbrdnk@users.noreply.github.com>
2025-09-04 13:05:26 +02:00
Nicola Mometto
42b06a759f fix: timezone aware datetime 2025-09-04 12:00:14 +01:00
Nicola Mometto
b3088ecfe4 note 2025-09-04 11:38:13 +01:00
Nicola Mometto
a1d8b0650a an in/out type test 2025-09-04 11:37:26 +01:00
Chris Truter
9740c5fe74 Replace python-runner folder with git submodule 2025-09-04 12:12:32 +02:00
Chris Truter
bfdd0754ed Critical fix: docstring indentation 2025-09-04 12:02:50 +02:00
Nicola Mometto
df6404e2f5 hack 2025-09-04 10:46:17 +01:00
Nicola Mometto
22224b8304 simpler api 2025-09-04 10:26:32 +01:00
Nicola Mometto
11c83cab30 switch to delete-target-table 2025-09-04 10:04:15 +01:00
Timofey Kachalov
32f47019f0 Update SDK docs for Hosted Bundle (#63069) 2025-09-04 12:43:36 +04:00
Nicola Mometto
ee3c3ff237 fix hints 2025-09-04 09:22:13 +01:00
Nicola Mometto
467734b04e type hints 2025-09-04 09:12:31 +01:00
appleby
2c02a11a51 Update pgvector to pg17 in semantic search docker-compose.yml and CI workflow (#62967)
* Update pgvector to pg17 in semantic search docker-compose.yml

This matches the version that will be used in prod and staging deployments.

* Update to pg17 in semantic-search.yml CI workflow

* Remove enable-ssl-tests env var from semantic-search.yml workflow
2025-09-04 01:17:54 +00:00
Romeo Van Snick
28125c53b5 Type parameter value (#62804)
* Move validate.js to ts and remove unused validators

* Remove any and unknown for typing parameter values

* Use ParameterValuesMap where possible

* Fix parameter-parsing

* Fix tests

* Fix cast to empty string
2025-09-04 08:57:28 +10:00
dpsutton
bd01f49307 Ignore some test vars (#63078)
metabase.session.models.session-test/send-email-on-first-login-from-new-device-test
test is failing because sometimes there's an extra email in there.

metabase-enterprise.impersonation.driver-test/nested-do-with-connection-with-options-test
is failing because it deadlocks all the app-db connections
2025-09-03 17:44:05 -05:00
bryan
c77f693f51 :dev-start --hot can watch enterprise paths (#62961) 2025-09-03 22:40:48 +00:00
Fraser
6915d54e9f Mark tests as flaky (#63055) 2025-09-04 09:31:28 +12:00
appleby
4b99970499 Fix semantic search tests when running on mysql and enable all appdbs in CI (#62966)
* Also skip the :bookmarked scorer on mysql

MySQL does not like the CASTs in the search-index-query

* Fix appdb-available-with-semantic test for mysql appdb

When the appdb is :mysql, we should fallback to the in-place engine rather than appdb

* Move body of search.engine/results :search.engine/in-place into a func for easy mocking

* Fix api-engine-switching-test for mysql appdb

* Fix test-semantic-search-fallback-supplementation and test-semantic-search-max-combined-results-limit for mysql appdb

* Update semantic-search CI job to run against all supported appdbs
2025-09-03 14:21:37 -07:00
metamben
f13e579c26 Add transform run start/end time and run method filters to the list endpoint (#62835)
* Implement last_run_... filters for transform runs

* Change filters to start_time, end_time, run_method

* Use timestamp literals instead of strings in test

* Add start_time, end_time and run_method to transform run query params in api

* Parse start_time, end_time and run_method params on run list page

* Allow custom react elements in displayValue prop

* Add filters for start_time and end_time to run list page

* Allow filtering on multiple run methods

* Add run method filter widget

* Close time filter when changing value

* Add e2e test for start at, end at and run method filters

* Allow multiple values for run_method filter

* Add test with start_time=2025-08-22~2025-08-23

* Fix e2e test

* Rename the run_method parameter to run_methods

* Remove "local" timestamps

* Return transform run timestamps in the system timezone

* Stop expecting a last_run with a nil value

* Rename run_method to run_methods to match api

---------

Co-authored-by: Romeo Van Snick <romeo@romeovansnick.be>
Co-authored-by: Alexander Polyankin <alexander.polyankin@metabase.com>
2025-09-03 20:44:09 +00:00
Uladzimir Havenchyk
6b8e95a34f fix(qb): do not show view detail button in step preview (#63071) 2025-09-03 23:00:34 +03:00
Jakub Chodorowicz
94875789ca Create standalone add DB page (#62927)
* Create standalone add DB page

* Use full page view for editing db connection

* Fix title on edit database page

* fix dataspec  cypress test

* fix missing formLocation prop

* fix add initial data cypress test

* Fix add db test not waiting for db connected

* Fix default schedule cypress test

* Remove unnecessary nullish coalescing and route

* Extract common logic to use-database-connection hook

* Adjust Add DB page width

* Adjust padding for smaller devices

* Use FormLocation type in prop
2025-09-03 19:24:03 +00:00
Noah Moss
c5a14f7ec4 Add repair-index! API with temp table mechanism for detecting lost deletes (#62960)
* Add repair-index! API with temp table mechanism for detecting deletions

* Fix up tests, bug fixes

* Explicitly disable reindex! and reset-tracking

* Add repair index task, and cleanup job in case there are orphans

* fix tests

* Test - comment out new tests to see if it fixes CI failures

* switch with-index! macro to use init! instead of reindex

* try again to fix with-index

* fix kondo

* ensure drop table table names get quoted

* switch to using gate table for the anti-join

* add missing assertion in test

* add more error handling in find-lost-deletes, reorganize a function

* make sure index cleanup task is initialized

* make sure index repair task is initialized
2025-09-03 15:19:26 -04:00
Alex Yarosh
ec14b08b13 docs: new VPAT (#63087)
* docs: new VPAT

* Update docs/installation-and-operation/accessibility.md

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>

---------

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>
2025-09-03 19:08:15 +00:00
bryan
8d6e60df0f stabilize composed regex schemas (#61805) 2025-09-03 19:02:40 +00:00
Ryan Laurie
fd168103b8 set default time in create event modal (#63046) 2025-09-03 18:58:54 +00:00
bryan
f2ddc223b6 block prs coming from master (#61681) 2025-09-03 14:57:53 -04:00
Dan Stone
e1df9b5c14 Use timestamps to interleave python stdin/err output in msg 2025-09-03 17:54:28 +01:00
Dan Stone
e1083a25f7 Wrap stdin/stderr with timestamp prefixes for each line 2025-09-03 17:54:28 +01:00
Dan Stone
fe3ea7401d Increase max processes
For me 50 was exceeded today and I could not start transforms. I am
guessing these are starter numbers and we'll need to figure out values
anyway
2025-09-03 17:54:28 +01:00
Alex Yarosh
f0de6a74b6 docs links (#63084) 2025-09-03 16:34:21 +00:00
Nicola Mometto
1815a69384 chore: add error 2025-09-03 17:34:02 +01:00
Phoomparin Mano
cefa86ccea Apply the new upsell flow to interactive and embed js upsells (#63062) 2025-09-03 23:32:21 +07:00
Rodrigo López Dato
4d6426249a Suggest to upgrade drivers only for self-hosting (#63079) 2025-09-03 12:28:08 -04:00
Nicola Mometto
af7a73b5f7 chore: allow empty schemas 2025-09-03 17:26:05 +01:00
Nicola Mometto
9035fda953 fix: don't remove indentation before """ 2025-09-03 17:07:59 +01:00
Phoomparin Mano
2f34d06d53 feat(embed-js): throws when setting invalid metabaseConfig keys (#63064) 2025-09-03 23:01:01 +07:00
Nicola Mometto
b4df47d8c8 drop table instead of truncating 2025-09-03 17:00:35 +01:00
Ngoc Khuat
4d270c04d1 remove hashp 2025-09-03 22:30:35 +07:00
github-automation-metabase
245f9e5090 Update generated docs (master) (#63056)
Co-authored-by: github-actions <github-actions@github.com>
2025-09-03 11:08:39 -04:00
Chris Truter
ea56586c04 Add default creds provider to pick up STS 2025-09-03 17:07:09 +02:00
Ryan Laurie
2b28d4e60f Stop pushing useless version info highlights (#62950)
* stop pushing useless version info

* fix dash
2025-09-03 09:06:43 -06:00
Arkadi Yaroslavtsev
ee1aa7620c adding sts dependency 2025-09-03 18:03:02 +03:00
dpsutton
128759d892 Fix time-interval filters (#62892)
* Fix time-interval filters

Reported on stats that the examples dashboard was breaking when you used
some relative timestamps. There it was a bit cryptic with

```
class java.lang.Integer cannot be cast to class
clojure.lang.IPersistentMap (java.lang.Integer is in module java.base of
loader 'bootstrap'; clojure.lang.IPersistentMap is in unnamed module of
loader 'app')
```

Locally in dev, we get:

```
 Error processing query: Invalid output: ["invalid tuple size 4, expected 5, got: [:time-interval [:field {:base-type :type/DateTime, :lib/uuid \"69655229-95a0-4bfb-9d3a-7675b1111ec4\"} 13] :current :day]"]
```

And it's a failure to have the time-interval options

before:
`[:time-interval field-clause :last (keyword unit)]`
after:
`[:time-interval interval-options field-clause :last (keyword unit)]`

spec:

```
(mbql-clause/define-mbql-clause :time-interval :- :type/Boolean
  ;; TODO -- we should probably further constrain this so you can't do weird stuff like
  ;;
  ;;    [:time-interval {} <time> :current :year]
  ;;
  ;; using units that don't agree with the expr type
  [:tuple
   [:= {:decode/normalize common/normalize-keyword} :time-interval]
   [:merge ::common/options ::time-interval-options]  ;; <---- missing bits
   #_expr [:ref ::expression/temporal]
   #_n    [:multi
           {:dispatch (some-fn keyword? string?)}
           [true  [:enum {:decode/normalize common/normalize-keyword} :current :last :next]]
           ;; I guess there's no reason you shouldn't be able to do something like 1 + 2 in here
           [false [:ref ::expression/integer]]]
   #_unit [:ref ::temporal-bucketing/unit.date-time.interval]])
```

Switching them to lib calls and then i noticed there were no tests.

With fix:

```clojure
dates=> (date-string->filter
          "lastmonth"
          [:field {:lib/uuid "00000000-0000-0000-0000-000000000000", :base-type :type/DateTime} "field"])
[:time-interval
 {:lib/uuid "bbca7a83-feb9-4259-a4db-bbb79687eb4e"}
 [:field
  {:lib/uuid "00000000-0000-0000-0000-000000000000",
   :base-type :type/DateTime}
  "field"]
 :last
 :month]
```

In a 56.3.4 repl:
```
user=> (metabase.driver.common.parameters.dates/date-string->filter "lastmonth" [:field {:lib/uuid "00000000-0000-0000-0000-000000000000", :base-type :type/DateTime} "field"])
[:time-interval [:field {:lib/uuid "00000000-0000-0000-0000-000000000000", :base-type :type/DateTime} "field"] :last :month]
user=> (pp)
[:time-interval
 [:field {:lib/uuid "00000000-0000-0000-0000-000000000000", :base-type :type/DateTime} "field"]
 :last
 :month]
nil
```

Note the missing options in the second position

* test e2e dashboard filters

takes a sampling of a few different parameter types and different
parsers. At one point i was doing something like:

```clojure
(concat (for [unit [:day :week :month :quarter :year]
              relative [:this :last]]
          (str (name relative) (name unit)))
        (for [unit '[days weeks months quarters years]
              include? [true false]
              relative '[past next]]
          (str relative "3" (name unit) (when include? "~"))))
```

But that seems overkill. This test is kinda seeing if the query
processor throws an error (or at least that's where most errors
happen). So those checks can be more exhaustive and against some
in-memory metadata providers
2025-09-03 09:43:33 -05:00
dpsutton
9f6acff3f5 two fixes, compaction and when to run (#63042)
* two fixes, compaction and when to run

Test logs are super, duper awesome. We upload them on failure since we
don't presumably need to see healthy logs.

There are two issues:
1. We upload them on `failure()`, but timeouts don't seem to trigger
this condition. So now upload on `always() && !success()` Why not just
`!success()`? An LLM suggests that timeouts are a bit special and go
into another mode. The always() will run and then we qualify it. Let's
see.

2. The logs are all on a single line.

We have a few axes here: compact and eventEol.
I have three files with these. If you want to grep for logs during a
particular test, here's what you get:

Compact: (current behavior)
```
❯ ag "metabase.util.queue-test/result-listener-test" logs/test-log.json.compact
<not reproducing here, because it's the whole file>
```

compact false
```
❯ ag "metabase.util.queue-test/result-listener-test" logs/test-log.json.not-compact
251:    "mb-test" : "metabase.util.queue-test/result-listener-test"
268:    "mb-test" : "metabase.util.queue-test/result-listener-test"
414:    "mb-test" : "metabase.util.queue-test/result-listener-test"
```

It's _too_ expanded.

```
{
  "instant" : {
    "epochSecond" : 1756844736,
    "nanoOfSecond" : 357005000
  },
  "thread" : "main",
  "level" : "INFO",
  "loggerName" : "metabase.util",
  "message" : "Maximum memory available to JVM: 8.0 GB",
  "contextMap" : { },
  "endOfBatch" : false,
  "loggerFqcn" : "org.apache.logging.log4j.spi.AbstractLogger",
  "threadId" : 1,
  "threadPriority" : 5
}
{
  "instant" : {
    "epochSecond" : 1756844739,
    "nanoOfSecond" : 802772000
  },
```

Compact true, eventEol (this PR sets this)
```
❯ ag "metabase.util.queue-test/result-listener-test" logs/test-log.json
17:{"instant":{"epochSecond":1756844991,"nanoOfSecond":537601000},"thread":"main","level":"INFO","loggerName":"metabase.util.queue","message":"Starting listener \u001B[32mtest-result-listener\u001B[0m with 1 threads 🎧","contextMap":{"mb-test":"metabase.util.queue-test/result-listener-test"},"endOfBatch":false,"loggerFqcn":"org.apache.logging.log4j.spi.AbstractLogger","threadId":1,"threadPriority":5}
18:{"instant":{"epochSecond":1756844991,"nanoOfSecond":572361000},"thread":"main","level":"INFO","loggerName":"metabase.util.queue","message":"Stopping listener test-result-listener...","contextMap":{"mb-test":"metabase.util.queue-test/result-listener-test"},"endOfBatch":false,"loggerFqcn":"org.apache.logging.log4j.spi.AbstractLogger","threadId":1,"threadPriority":5}
20:{"instant":{"epochSecond":1756844991,"nanoOfSecond":585407000},"thread":"main","level":"INFO","loggerName":"metabase.util.queue","message":"Stopping listener test-result-listener...done","contextMap":{"mb-test":"metabase.util.queue-test/result-listener-test"},"endOfBatch":false,"loggerFqcn":"org.apache.logging.log4j.spi.AbstractLogger","threadId":1,"threadPriority":5}
```

You get the whole log lines. super helpful. pipe these through a
processing pipeline, use jq, etc.

Also, these files are ~817MB when running in a test suite. I'm doing these with a single namespace

```
❯ clj -X:dev:test :only metabase.util.queue-test

❯ ls -lh logs
13K Sep  2 15:29 test-log.json
13K Sep  2 15:24 test-log.json.compact
16K Sep  2 15:26 test-log.json.not-compact
```

* stacktraces when we don't get returned connections
2025-09-03 09:37:23 -05:00
dpsutton
9191713854 Quick ci test disabling (#63030)
* use new hawk version. waiting on release

* quick checkin on CI stuff

* load file to ignore vars

```clojure
;; json file with a list of vars
test-runner=> (println (slurp "/tmp/config.json"))
{
  "ignored": {
    "vars": [
      "metabase.util.queue-test/bounded-transfer-queue-test",
      "metabase.util.queue-test/take-batch-test"
    ]
  }
}

nil
test-runner=> (find-tests (build-final-options {:ci-config-file "/tmp/config.json"
                                                :only 'metabase.util.queue-test}))
Running tests with options {:namespace-pattern #"^(?:(?:metabase.*)|(?:hooks\..*))", :exclude-directories [".clj-kondo/src" "classes" "dev" "enterprise/backend/src" "local" "resources" "resources-ee" "src" "target" "test_config" "test_resources"], :test-warn-time 3000, :ignored {:vars #{"metabase.util.queue-test/bounded-transfer-queue-test" "metabase.util.queue-test/take-batch-test"}}, :ci-config-file "/tmp/config.json", :only metabase.util.queue-test}
Running tests in metabase.util.queue-test
Finding tests took 1000.0 µs.
Running 4 tests
(#'metabase.util.queue-test/non-delayed-take-batch-test
 #'metabase.util.queue-test/result-listener-test
 #'metabase.util.queue-test/listener-handler-test
 #'metabase.util.queue-test/multithreaded-listener-test)

;; only found 4 tests
;; no ignored vars

test-runner=> (println (slurp "/tmp/empty-config.json"))
{
  "ignored": {
    "vars": []
  }
}

nil

;; finds 6 tests
test-runner=> (find-tests (build-final-options {:ci-config-file "/tmp/empty-config.json"
                                                :only 'metabase.util.queue-test}))
Running tests with options {:namespace-pattern #"^(?:(?:metabase.*)|(?:hooks\..*))", :exclude-directories [".clj-kondo/src" "classes" "dev" "enterprise/backend/src" "local" "resources" "resources-ee" "src" "target" "test_config" "test_resources"], :test-warn-time 3000, :ignored {}, :ci-config-file "/tmp/empty-config.json", :only metabase.util.queue-test}
Running tests in metabase.util.queue-test
Finding tests took 0.0 ns.
Running 6 tests
(#'metabase.util.queue-test/non-delayed-take-batch-test
 #'metabase.util.queue-test/take-batch-test
 #'metabase.util.queue-test/result-listener-test
 #'metabase.util.queue-test/listener-handler-test
 #'metabase.util.queue-test/bounded-transfer-queue-test
 #'metabase.util.queue-test/multithreaded-listener-test)
```

* Fetch ci-test-config.json from master on each test run

This affects all BE tests, driver and app-db. Don't pass an explicit arg
and just let the default pick it up.

```bash
❯ clj -X:dev:test :only metabase.util.queue-test
Running tests with options {:mode :cli/local, :namespace-pattern #"^(?:(?:metabase.*)|(?:hooks\..*))", :exclude-directories [".clj-kondo/src" "classes" "dev" "enterprise/backend/src" "local" "resources" "resources-ee" "src" "target" "test_config" "test_resources"], :test-warn-time 3000, :ignored {}, :exclude-tags [:metabot-v3/e2e], :only metabase.util.queue-test}
Running tests in metabase.util.queue-test
Finding tests took 7.5 s.
Running 6 tests
Running before-run hooks...

LONG TEST in metabase.util.queue-test/take-batch-test
Test took 4.720 seconds seconds to run

LONG TEST in metabase.util.queue-test/bounded-transfer-queue-test
Test took 7.518 seconds seconds to run

6/6   100% [==================================================]  ETA: 00:00

Ran 6 tests in 12.421 seconds
53 assertions, 0 failures, 0 errors.
{:test 6, :pass 53, :fail 0, :error 0, :type :summary, :duration 12421.435583, :single-threaded 6}
Ran 0 tests in parallel, 6 single-threaded.
Finding and running tests took 20.0 s.
All tests passed.
Running after-run hooks...
Running QP tests against these drivers: #{:h2}

metabase on  quick-CI-test-disabling [$!?] via ☕ v21.0.2 on ☁️  metabase-query took 48s
❯ clj -X:dev:test :only metabase.util.queue-test :ci-config-file '"/tmp/config.json"'
Loading CI config file from /tmp/config.json    # <------ new output
Running tests with options {:mode :cli/local, :namespace-pattern #"^(?:(?:metabase.*)|(?:hooks\..*))", :exclude-directories [".clj-kondo/src" "classes" "dev" "enterprise/backend/src" "local" "resources" "resources-ee" "src" "target" "test_config" "test_resources"], :test-warn-time 3000, :ignored {:vars #{"metabase.util.queue-test/bounded-transfer-queue-test" "metabase.util.queue-test/take-batch-test"}}, :exclude-tags [:metabot-v3/e2e], :only metabase.util.queue-test, :ci-config-file "/tmp/config.json"}
Running tests in metabase.util.queue-test
Finding tests took 6.9 s.
Running 4 tests
Running before-run hooks...

4/4   100% [==================================================]  ETA: 00:00

Ran 4 tests in 0.133 seconds
42 assertions, 0 failures, 0 errors.
{:test 4, :pass 42, :fail 0, :error 0, :type :summary, :duration 133.16525, :single-threaded 4}
Ran 0 tests in parallel, 4 single-threaded.
Finding and running tests took 7.1 s.
All tests passed.
Running after-run hooks...
Running QP tests against these drivers: #{:h2}
```

Note that it runs 4 tests instead of 6. The config passed here was:

``javascript
{
  "version": "1.0.0",
  "ignored": {
    "vars": [
      "metabase.util.queue-test/bounded-transfer-queue-test",
      "metabase.util.queue-test/take-batch-test"
    ]
  },
  "metadata": {
    "last_updated": "2025-08-02",
    "updated_by": "engineering-team",
    "reason": "Testing CI config implementation"
  }
}
```

* empty ci-test-config

this will be the file when this merges

* print config when it has vars that we are ignoring

* PR review feedback

typo in example json

set continue-on-error: true. if network fails, let's not fail our
build. it's just a little file. carry on soldier. worst case scenario a
test known to flake might flake. might not.
2025-09-03 09:33:11 -05:00
Ngoc Khuat
0c871cbd68 fix delete transform + table 2025-09-03 20:58:08 +07:00
Nicolò Pretto
8a71067f33 add eslint rule to catch missing key prop inside components passed to jt (#63063)
* add eslint rule to catch missing key prop inside components passed to jt

* fix errors found
2025-09-03 15:36:27 +02:00
Nicola Mometto
8f038a2476 note 2025-09-03 13:11:58 +01:00
Nicola Mometto
52dad58417 move to common ns 2025-09-03 13:10:36 +01:00
Nicola Mometto
97bbf28724 todo 2025-09-03 13:09:08 +01:00
Nicola Mometto
b06558f7fc with double dispatch 2025-09-03 13:03:14 +01:00
Nicola Mometto
9e4bb24349 creation tests 2025-09-03 12:53:09 +01:00
Nicola Mometto
2c269334ab chore: fix tests 2025-09-03 12:53:09 +01:00
Nicola Mometto
b594e954d8 relax schema 2025-09-03 12:53:09 +01:00
Nicola Mometto
de545a639e wip: move away from csv upload 2025-09-03 12:53:08 +01:00
Ngoc Khuat
cc9f0cc6da fix build error s3 v2 2025-09-03 18:49:33 +07:00
Ngoc Khuat
35588c7f9e switch s3 sdk to v2 2025-09-03 17:22:21 +07:00
Nicola Mometto
c5920c39e8 remove whitespaces 2025-09-03 10:48:03 +01:00
Nicola Mometto
1ffcaee719 add logging 2025-09-03 10:45:44 +01:00
Nicola Mometto
9f619f71cc fix args 2025-09-03 10:42:17 +01:00
Nicola Mometto
1e63d81675 fix import typo 2025-09-03 10:37:19 +01:00
Nicola Mometto
a13415c31f cleanup, remove csv metrics (as it's going to change), generic with-timing 2025-09-03 10:36:41 +01:00
Chris Truter
22554bed89 rough metadata transfer (just return raw dtype for now) 2025-09-03 11:30:09 +02:00
Ngoc Khuat
db1155d958 fix scheduled python run 2025-09-03 15:31:23 +07:00
Chris Truter
e0b446f108 more type check fixes - including some smelly optional override stuff 2025-09-03 09:48:36 +02:00
Chris Truter
ba51fad9d2 fix type errors 2025-09-03 09:42:49 +02:00
Kamil Mielnik
bf19cc9606 Fix flaky test (#63009) 2025-09-03 14:07:42 +07:00
Chris Truter
d4b7faa3ff solve more fe lints 2025-09-03 07:43:42 +02:00
Chris Truter
8c8fba1874 trouble with kms - support only region without custom endpoint 2025-09-03 07:34:38 +02:00
Romeo Van Snick
b53b8411c4 Wrap long question or dashboard names (#62980)
* Add repro for metabase#52872

* Wrap long titles without spaces in saved questions

* Add repro for metabase#52872 for dashboards

* Fix width of dashboard with long name

* Use max-width instead of width
2025-09-03 13:10:11 +10:00
Phoomparin Mano
c380541d30 Show loading indicator overlay immediately on embed flow preview (#63001) 2025-09-03 07:17:01 +07:00
Romeo Van Snick
6ce3e4b250 Show non-aggregation functions in aggregations (#62989)
* Show non-aggregation functions in aggragations

* Fix unit test

* Add repro for metabase#62987

* Lower fuzzing iterations
2025-09-03 09:55:58 +10:00
Chris Truter
ca970b80e7 fix unit test 2025-09-03 00:43:13 +02:00
bryan
f80fee03bd Make Usage Analytics work on mysql (#62357)
Co-authored-by: dan sutton <dan@dpsutton.com>
2025-09-02 22:19:59 +00:00
Chris Truter
2b9ead20f9 fix kondo 2025-09-03 00:15:53 +02:00
Chris Truter
f0f9b98f0f Fix build - oops 2025-09-03 00:13:48 +02:00
Chris Truter
1cccfd3c66 Don't need this negative comment 2025-09-03 00:05:09 +02:00
Chris Truter
79f2bc3a06 Various fixes for staging and general life
- Measure time properly
- Make endpoint config optional, so it's skipped in staging
- Make auth key config option, so it's skipped in staging
- Skip dev-only settings defaults in staging
- Add prefix, so staging permissions work
- Use short names for Java classes (Cursive lint)
- Remove trivial comments, answer some others
- Fix test-id that broke malli
2025-09-03 00:00:16 +02:00
Jeff Bruemmer
2970fc027f check doc links on PRs (#63041) 2025-09-02 17:04:42 -04:00
Ryan Laurie
a8fe573099 Fix Select Visual Bugs (#62466)
* fix double scroll + padding on select dropdown

* remove overrides for root overflow

* override inline style

* I think this is good

* less bad
2025-09-02 21:00:44 +00:00
Chris Truter
6171621ea3 lock down script permissions a bit more 2025-09-02 22:28:48 +02:00
Chris Truter
f6d0e32a02 Remove sharp hidden failures edges around bucket creation 2025-09-02 22:10:24 +02:00
Chris Truter
1697548096 Use system credentials for s3 2025-09-02 22:10:24 +02:00
Denis Berezin
8bd9ea4b3f Fix multiple datasource viz settings in visualizer (#63004)
* Fix multiple datasource viz settings in visualizer

* Add e2e test
2025-09-02 22:51:09 +03:00
Jeff Bruemmer
c9baddf99f update docs link checker (#62687) 2025-09-02 15:39:46 -04:00
Nick Fitzpatrick
bba0093d38 use container padding to provide space between items in entity picker lists (#62883) 2025-09-02 15:50:29 -03:00
Filipe Silva
bfd69205ef feat: Pg Replication Preview modal (#61522)
* etc: kickoff comments

* get quotas statuses from token-check (#61560)

* get quotas statuses from token-check
* Check quota and estimated-row-count of dbs before replication
* Evict token-check cache to get updated quotas

* Turn the MB pg replication button into a modal (#61701)

Closes: https://linear.app/metabase/issue/CLO-4308/turn-the-mb-pg-replication-button-into-a-modal

* Fix schema-filters-patterns split

* split token-check row estimates counts (#61783)

* Split token-check row estimates counts
* add preview endpoint

* Align replication schema-filters with HM

Fixes: 805f4cafcf
Depends-on: https://github.com/metabase/harbormaster/pull/6445

* preview endpoint changed

* temp frontend modal

* After pairing with Raimon

* Fix lint and fmt errors

* pg replication modal  (#61913)

* Success modal on starting replication
* Visual improvement to DatabaseReplicationForm
* made non-pk-tables list prettier

---------

Co-authored-by: Dennis Schridde <dennis@metabase.com>

* Run prettier and linter on DatabaseReplicationForm

* Turn DatabaseReplicationModal into a multi step thing and add backend API to support this

* Workaround broken dirty bit

* Call setFieldValue("schemaFields", "") when schemaSelect=all

* fix enabling of the replication button

* UI updates

* UI updates

* removed package-lock file

* Don't wait for replication to become "active" in "setting up" modal

The progression from "initializing" to "active" can take arbitrary
amounts of time.  Instead we should show the "setting up" modal while
creating the replication, which is synchronous and has an upper bound
of 40s.

Fixes: 6f2ba1852e
References: https://metaboat.slack.com/archives/C079ZS06ERJ/p1754940482733049

* Loading for preview method

* Error handling

* Modal padding and title updates

* Remove info about future email from form

* Misc

* Misc

* DatabaseReplicationStatusInfoProps cleanup

* Misc

* Status modal content padding

* Modal properties

* fix: throw harbormaster call error body in ex-data

* Show which tables are excluded from replication because of owner mismatch

Closes: https://linear.app/metabase/issue/CLO-4346/preview-should-also-include-schemas-that-cant-be-synced-due-to-owner

* Align text of replication modal more with Figma

* UI updates 1

* Replication stats spacing updates

* Misc

* Tables listing icons

* Alignment updates

* Layout updates for tables listing

* Misc

* Colours updates

* List updates

* Misc

* Misc text alignment

* Misc

* Scrollable tables list

* Fix tables listing

* Comma separated DB WIP

* Misc

* Fix margins

* Ui updates

* More on setting up and success layout

* Test for spinner

* More on spinner

* Colour update

* Box shadow for spinner

* Spinner size updated

* Spinner padding updated

* Spinner added to setting up step

* Misc

* Sizes updated

* Fix for unit tests

* Debounce for schema filters

* Schema filters onChange

* Remove loading in button is no schema filters

* Loader for preview

* Misc

* feat: check replication table ownership

Same as how HM does it.

* Moved laoder next to the submit button

* Make DatabaseReplicationForm look more "loading..." during preview

* Remove setFieldValue hack

Was obsoleted by 9cdbeaec7a

* Also show skeletons when data is not fresh (i.e. when loading)

* Fix linter: Change set IDs are not in order

* Build uberjar container also when pushing a PR branch

Before it would only build when the `build-docker-uberjar` label was
added.  So to build the latest branch head you'd have to remove and
re-add the label.

Fixes: 22507a963a

* Link to postgres docs

* SUrface "incorrect" errors from HM response to connection creation

* Misc

* Modal layout

* Error modal UI updates

* Misc

* More on layout + alignment fixed

* More on error layout

* Fix for modal closing

* rfct: use pg conn preview

* revert owner sync

* rfct: use existing schema filter format

* lint: fix fe

* feat: also show tables that will be replicated

* test: update be tests

* rfct: minor renames for consistency

* fix: cannot replicate 0 tables

* style: fix

* fix: copy

* test: update body prop

* test: add form tests

* fix: progress indicator on bottom

* fix: card styles

* fix: error message when no tables to replicate

* fix: easy stuff from jakub's review

* fix: error state for preview too

* claude: fast FE unit tests

* rfct: use fetchMock in FE test

* fix: remove small error step text

* fix: mocal close should reset setup step

* fix: translate noSyncReason

* fix: catch invalid schema pattern as 400

* rfct: use plain fn for onSubmit

* rfct: raise inline fn

* rfct: use correct token-check alias

* rfct: remove unused preview fields

* rfct: raise free-quota fn

* fix: throw on tunnel or certs

* rfct: remove silly when

* rfct: testable preview-replication and errors map

* test: granular fe error tests

* test: fix BE tests

* test: preview-replication unit tests

* fix: test redef name

* rfct: style and db as dbname

---------

Co-authored-by: Raimon Grau <raimon@metabase.com>
Co-authored-by: Dennis Schridde <63082+devurandom@users.noreply.github.com>
Co-authored-by: Dennis Schridde <dennis@metabase.com>
Co-authored-by: Raimon Grau <raimonster@gmail.com>
Co-authored-by: Arkadi Yaroslavtsev <arkadi@metabase.com>
Co-authored-by: losrebellos <ben@benoitvinay.com>
2025-09-02 17:51:28 +01:00
Filipe Silva
d6c7c03ebe feat: audit for cloud add on purchase (#63021)
Fix https://linear.app/metabase/issue/CLO-4380/pass-metabase-user-information-to-store-api-using-a-http-header
2025-09-02 16:57:27 +01:00
Nicola Mometto
32b49c788c snuck back in 2025-09-02 16:38:55 +01:00
Nicola Mometto
f447bdaa8f just use run-id 2025-09-02 16:36:16 +01:00
Vamsi Peri
1b468c92f9 Fix question download filenames to use question name instead of generic 'query_result' (#61710)
* Fix question download filenames to use question name instead of generic 'query_result'

Resolves: https://github.com/metabase/metabase/issues/61708

Previously, when downloading questions from the SDK (and public links), files were
named with a generic "query_result_{timestamp}.{format}" pattern even when the
question had a meaningful name.

This fix ensures that:
- Questions with valid names use the slugified question name as filename
- Questions with nil/empty/blank names fall back to "question" instead of "query_result"
- Both regular card downloads (/api/card/:id/query/:format) and public link downloads are fixed

Changes:
- Modified process-query-for-card-default-run-fn in query_processor/card.clj
- Modified process-query-for-card-with-id-run-fn in public_sharing/api.clj
- Added proper fallback logic using str/blank? to handle edge cases

Expected behavior:
- "My Awesome Question" → my_awesome_question_{timestamp}.csv
- nil/empty name → question_{timestamp}.csv

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* Cleanup and added tests

* Make whitespace linter happy

* Fix silly oversight

* Set warn-on-reflection

* Fix issues

---------

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Timothy Dean <timothy@timothydean.dev>
2025-09-02 09:33:39 -06:00
Stas Gavrylov
264ab81bd9 List View – Fixes for missed cases (#63013)
* WRK-867: Fix list display changing when duplicating model/turning into question

* Update e2e test for List View
2025-09-02 18:23:07 +03:00
Nicola Mometto
fbb2824944 simplify 2025-09-02 16:12:24 +01:00
Nicola Mometto
34331c5a79 instrument python execution 2025-09-02 16:04:07 +01:00
Nicola Mometto
935e458161 instrument the job 2025-09-02 16:04:07 +01:00
Nicola Mometto
31f5c10ffe chore: allow analytics for transforms 2025-09-02 16:04:07 +01:00
Nicola Mometto
c77efb4ba1 feat: add instrumentation util namespace 2025-09-02 16:04:07 +01:00
Nicola Mometto
e7510b606e wip: add transform metrics 2025-09-02 16:04:07 +01:00
Chris Truter
ff2dc465f7 more debugging stuff 2025-09-02 16:58:01 +02:00
Chris Truter
43de9c4f6a Some minor fixes around docstring rewriting 2025-09-02 16:30:06 +02:00
Dan Stone
126098289b Logs are viewable inline during execution of python transforms 2025-09-02 15:23:09 +01:00
Phoomparin Mano
087a69eb78 fix(sdk): prevent double scrollbars in sdk dashboards (#62962) 2025-09-02 21:20:02 +07:00
Phoomparin Mano
ad621ed1f0 Embed JS should show "Try it out" before docs in admin panel (#62954) 2025-09-02 21:19:15 +07:00
Phoomparin Mano
f4821a0935 feat(sdk): use entity ids directly in collection picker and browser (#60562) 2025-09-02 21:18:18 +07:00
Konstantin Darutkin
54bee8a76b feat: render link to table metadata editing in the error message (#63018) 2025-09-02 14:05:51 +00:00
github-automation-metabase
49080efe82 Update generated docs (master) (#62978)
Co-authored-by: github-actions <github-actions@github.com>
2025-09-02 09:50:28 -04:00
dpsutton
5973b65a81 disable starburst (#62955) 2025-09-02 08:29:16 -05:00
Chris Truter
e0f8ed8415 Return explicit errors when trying to edit a table without a PK (#62893) 2025-09-02 15:51:31 +03:00
Dan Stone
fb808245e3 Logs endpoint vibes
Needs to be destroyed at some future point
2025-09-02 11:46:57 +01:00
Dan Stone
159462606f Tests include boto3 now, so add to venv 2025-09-02 11:46:57 +01:00
Nicola Mometto
7d1ba026db eh, rename to appease the munging 2025-09-02 11:21:06 +01:00
Nicola Mometto
18199cf553 remove placeholders 2025-09-02 11:21:05 +01:00
Nicola Mometto
1fd87edf97 use new settings 2025-09-02 11:21:05 +01:00
Nicola Mometto
76097a2c65 feat: split settings 2025-09-02 11:21:05 +01:00
Nicola Mometto
cc5eb4332c feat: settings page with s3 configs 2025-09-02 11:21:05 +01:00
Nicola Mometto
54ad1db5c8 remove old setting 2025-09-02 11:21:05 +01:00
Chris Truter
a3af25f5b0 Auto-update Python transform function signature when table aliases change
- Automatically updates def transform(...) signature when aliases are modified
- Updates docstring Args section with aligned descriptions and table names
- Adds reset button to restore default slugified aliases
- Validates alias input to only allow valid Python identifiers
- Handles multi-line signatures for many parameters (>80 chars)
- Shows visual distinction between custom and auto-generated aliases
- Fixes code editor layout to prevent overlap with Run button
2025-09-02 12:17:43 +02:00
Sébastien
ca9ebb9972 Closes EMB-716 publicly shared maps in dashboards (#62990)
* Closes EMB-716 publicly shared maps in dashboards

* string | number -> DashboardId
2025-09-02 11:23:21 +02:00
Chris Truter
6ec9182ad0 silly move, from demo #p 2025-09-02 11:22:49 +02:00
Phoomparin Mano
dbdf070383 fix(sdk): drills and go to dashcard does not work in dashboard with entity ids (#62953) 2025-09-02 16:21:54 +07:00
Nicola Mometto
efb033096e chore: docstrings in right position 2025-09-02 10:06:51 +01:00
Timofey Kachalov
85ab7c0184 refactor(sdk): Improve version-helpers and sdk bundle version injection (#63008) 2025-09-02 12:27:20 +04:00
Fraser
0c17daf51b Enable ts incremental builds (#62910) 2025-09-02 10:29:07 +12:00
Chris Truter
91bd482969 Fix for 404s 2025-09-01 18:48:40 +02:00
Chris Truter
010ab29959 Fix for find-replace breaking signed url 2025-09-01 18:48:40 +02:00
Chris Truter
3f897aa4f8 get rid of vestigial working_dir 2025-09-01 18:48:40 +02:00
Nicola Mometto
d17158db77 working button 2025-09-01 17:43:07 +01:00
Nicola Mometto
29c80be876 add cancel python test endpoing 2025-09-01 17:37:59 +01:00
Nicola Mometto
76dc608ed8 add cancel button to test python endpoint 2025-09-01 17:37:50 +01:00
Phoomparin Mano
88aaf24794 ci(sdk): version bump for Next.js for host apps e2e tests (#62994) 2025-09-01 22:46:57 +07:00
Nicola Mometto
ded4524241 better endpoint name 2025-09-01 16:31:02 +01:00
Nicola Mometto
65b3027992 fix /test error reporting 2025-09-01 16:14:47 +01:00
Nicolò Pretto
a99144ee23 fix: remove helpers from the types of cy (#62662) 2025-09-01 16:57:32 +02:00
Sébastien
022b84e40d Closes EMB-650 move download button to footer for title-less embed tables (#62917)
* Closes EMB-650 move download button to footer for title-less embed tables

* Also show download button in paginated tables

* screenshot

* Update frontend/src/metabase/public/containers/PublicOrEmbeddedQuestion/PublicOrEmbeddedQuestionView.tsx

Co-authored-by: Phoomparin Mano <poom@metabase.com>

* .

---------

Co-authored-by: Phoomparin Mano <poom@metabase.com>
2025-09-01 16:18:35 +02:00
Nicolò Maria Mezzopera
21125870c0 chore: removed not needed cy.wait (#61412) 2025-09-01 14:18:22 +00:00
Chris Truter
d72ca3c6cc Minor code and object cleanup 2025-09-01 15:13:39 +02:00
Chris Truter
0622b4004a writing to a tempfile first is a feature - we can close the dwh query faster 2025-09-01 15:12:08 +02:00
Nicola Mometto
8348a94edb Merge remote-tracking branch 'origin/proj-python/s01e02' into proj-python/s01e02 2025-09-01 13:59:30 +01:00
Nicola Mometto
c96bd66166 Merge remote-tracking branch 'origin/proj-python/s01e02' into proj-python/s01e02 2025-09-01 13:55:49 +01:00
Chris Truter
21a54d7591 s3 config setting 2025-09-01 14:48:51 +02:00
Chris Truter
b8fb092432 Linter stuff 2025-09-01 14:38:30 +02:00
Nicola Mometto
5f6d3ee14e leave async cancel for sql 2025-09-01 13:35:45 +01:00
Chris Truter
f6b143d489 Makefile creates bucket 2025-09-01 14:31:45 +02:00
Chris Truter
8e5d085924 Vile vibe verbiage - but it works (locally) 2025-09-01 14:30:29 +02:00
Nicola Mometto
e1b4627f33 cancel working e2e 2025-09-01 13:22:00 +01:00
Chris Truter
fd50372b5d Hacky as all hell - input files use s3 2025-09-01 14:14:23 +02:00
Nicola Mometto
322edf01ba immediately cancel run 2025-09-01 13:01:26 +01:00
Nicola Mometto
50059a9790 fix transform-run-cancelation 2025-09-01 12:57:19 +01:00
Dan Stone
1115e30d3b Add docker-compose.yml with localstack
Makefile/tests now uses docker-compose
2025-09-01 12:53:50 +01:00
Nicola Mometto
518877e2f6 fix running-run for transform-id 2025-09-01 12:52:34 +01:00
Jakub Chodorowicz
11f98faf74 Hide CSV panel with no meaningful uploadable dbs (#62854)
* Hide CSV panel with no meaningful uploadable dbs

* Hide add data when no meaningful actions can be performed

* Simplify conditional for shouldShowUploadPanel test

Co-authored-by: Anderson <ands.alves.nunes@gmail.com>

* Show CSV tab also when user can upload data

User with upload permissions, but without admin rights, cannot see uploadable dbs in the api response

* Add e2e test for hidden add data for regular users without upload permissions

---------

Co-authored-by: Anderson <ands.alves.nunes@gmail.com>
2025-09-01 13:50:52 +02:00
Nicola Mometto
b0749f1b2b add cancel button 2025-09-01 12:45:08 +01:00
Nicola Mometto
c7cba11e85 fix cancel endpoint 2025-09-01 12:45:02 +01:00
Nicola Mometto
a1bcd98682 pass run-id 2025-09-01 12:44:59 +01:00
Nicola Mometto
95b077f039 fix tests 2025-09-01 12:31:10 +01:00
Nicola Mometto
840a2b71e8 feat: cancel in python server 2025-09-01 12:30:23 +01:00
Nicola Mometto
8325bb3375 feat: interrupt request on cancel 2025-09-01 12:20:51 +01:00
Nicola Mometto
00e078cfa4 chore: pipe cancel-chan down to python-runner 2025-09-01 10:54:43 +01:00
Nicola Mometto
105039ee2f Merge remote-tracking branch 'origin/master' into proj-python/s01e02 2025-09-01 10:41:02 +01:00
Cam Saul
b3c3ce62ab Fix deselecting fields in joins with inactive implicitly joined remapped columns (#62846)
* Don't add inactive remaps

* Don't add inactive remaps

* cljfmt

* summer squash

* Fix equality

* Fix bug in field resolution with multiple remaps between Table A and Table B

# Conflicts:
#	test/metabase/lib/field/resolution_test.cljc

* Kondo

* Fix fix

* A very nice fix 🔧
2025-08-30 00:07:20 -07:00
Cam Saul
e0a501e35b Malli validator LRU cache (#62523)
* Malli validator LRU cache

* Remove comments

* Pull in the changes to legacy-MBQL schema to power changes to predicates
2025-08-29 19:56:02 -07:00
bryan
89403cd164 spit out the nrepl port (#62443) 2025-08-29 18:42:42 -07:00
Brad Anderson
6d1ad5ad65 Fix: Command palette layout shift on open (#62945)
* UXW-295 Fix command palette layout jump by moving `useCommandPalette` to the always-mounted Palette component

* UXW-295 Fix tests
2025-08-29 16:28:04 -06:00
appleby
41551f5654 semantic search: fallback to backup engine when search-string is nil (#62947)
* semantic search: fallback to backup engine when search-string is nil

* Add test-semantic-search-fallback-empty-or-nil-search-string
2025-08-29 21:17:28 +00:00
Cam Saul
3c6ae7d9c0 Don't add inactive remaps (#62949)
* Don't add inactive remaps

* Don't add inactive remaps

* cljfmt
2025-08-29 20:50:23 +00:00
Alexander Polyankin
46cf12e858 Show a special error screen when you don't have permissions to run the query (#62941)
* Show a special error screen when you don't have permissions to run the query

* Show a special error screen when you don't have permissions to run the query

* Fix tests
2025-08-29 20:48:05 +00:00
Riley Thompson
8bb7956042 Enable transforms support for more drivers (#62430)
* Unpolished WIP hackathon code for additional driver support

* fix kondo

* add transforms/table featuer for supported drivers

* fix transforms for dbs with no schema

* rename transform datasets to prevent foreign key overlap

* Add clickhouse support

* fix clickhouse tests

* fix redshift tests

* fix bigquery failures

* kondo and filter tests by feature

* fix transform dataset for bigquery

* fix sqlserver transforms with joins

* fix clickhouse order by when no non nullable field is available

* add more complex test with join, filter, aggregation and ordering

* use different metadata provider

* filter for left join feature in test

* improve sqlserver compile-transform

* done use legacy mbql in test, refactor normalize-name

* clean up

* add sqlserver error test

* parse query and add into for sqlserver

* add type hints for linter

* Address comments

---------

Co-authored-by: Timothy Dean <timothy@timothydean.dev>
2025-08-29 15:47:06 -04:00
Alexander Polyankin
d70f6dae3b E2E repro for "Error when using coalesce expression in question with joins" (#62923) 2025-08-29 15:31:11 -04:00
Alexander Polyankin
9b4da26149 Fix model sidebar for joined tables (#62936) 2025-08-29 15:31:05 -04:00
Aleksandr Lesnenko
c8fb2a8ff4 fix combining timeseries datasets (#62903)
* fix combining timeseries datasets

* review
2025-08-29 19:08:33 +00:00
William
a08cb0df7b Differentiate different geographic drills and don't show duplicates (#62778)
Previously, if you had city, state, latitude, and longitude breakouts, you'd get zoom in (city), zoom in (state), zoom in (lat/lon for lat), zoom in (default binning for lat), zoom in (lat/lon for lon), and zoom in (default binning for lon).  Those would all be called "zoom in", so you'd just see half a dozen drills with the same title.  This hides the default binning drills if we are showing lat/lon, and gives the assorted geographic zoom-ins different titles.
2025-08-29 17:28:06 +00:00
Nicolò Pretto
eeee70fd5f chore(sdk): limit what branch we can release when using the workflow (#62925)
from master
2025-08-29 17:11:44 +00:00
Jeff Bruemmer
e0615cb2b5 docs - metabot follow-ups (#62934)
* consolidate blockquotes

* edit
2025-08-29 13:08:11 -04:00
Oleksandr Yakushev
fe01932aad Fix conversion of grouped pivot values to consistent types (2nd attempt) (#62902) 2025-08-29 13:02:52 -04:00
Robert Kosara
90ef491973 Add Jeff's suggestions from #62929 (#62933)
Today's lesson: don't turn on auto-merge if you want to be able to respond to suggestions…
2025-08-29 16:30:20 +00:00
Cam Saul
eb8aad0e2c wrap-value-literals => Lib (#62619)
* `wrap-value-literals` => Lib

* Mostly working nicely

* Clean up other middleware + test fix

* Finish it up

* Code cleanup

* Kondo

* Fix test 🔧

* Work around https://github.com/clj-kondo/clj-kondo/issues/2610

* Test fixes; PR feedback

* Fix walk recursion into `:case` and `:if`

* code cleanup

* Oracle test fix 🔧

* Another test fix 🔧
2025-08-29 09:23:35 -07:00
Braden Shepherdson
e20f7e2382 [ClickHouse] Handle SSH tunneling when checking for :connection-impersonation support (#62743)
Fixes #62377.

Correctly get a connection to the database while checking the ClickHouse version
(used to check if it supports `:connection-impersonation`). The driver was using the
internal, raw form of getting a connection, which didn't apply the SSH tunnel properly.
2025-08-29 16:22:02 +00:00
Robert Kosara
925cfb5a64 Add Snowflake JDBC error troubleshooting section (#62929)
This addresses an issue people run into when running the JAR file and connecting to Snowflake
2025-08-29 16:20:24 +00:00
Eric Normand
d17734fd9b Reproduce error on duplicating blocked card (#61103) 2025-08-29 16:07:38 +00:00
Stas Gavrylov
0cf6547fed Models – List View (#62428)
* Boilerplate

* Add list view toggle control to ViewFooter

* Remove processRemappedColumns, add layout

* Navigation

* Back button,breadcrumbs

* TODO

* Layout

* Layout

* Refactor

* Column detection logic

* Inline

* Fix

* Extract Breadcrumb

* Fix

* Entity name in nav

* Condition

* Fix

* Header

* Style

* Remove

* Do not render header if no column can be used there

* Body

* Add empty list viz

* Update VizStyleToggle to use list display type

* Sidebar

* Style

* Add simple list view

* Add virtualization for ListViz view. Optimize rendering

* Copy

* Hover style

* Add object detail modal opening on list item click

* Remove back button

* Overflows

* a11y

* Redundant css

* Fix

* Fix rendering

* Style links

* Cleanup

* FK pill

* Render images

* Prevent showing old images while new are loading

* Take currency_in_header into account

* Extract `ColumnHeader`

* Cleanup

* Fix spacing, colors

* Refactor relationships

* Update PK drill

* PK drill

* Fix

* Fix

* Improve layout of list items

* Center cells content

* Add sorting

* Fix virtualized behavior

* Fix copy if row name is not available

* Max height for values

* Update ViewStyleToggle rendering rule to fix incorrect list view icon

* Styling fixes

* Make whole list view scrollable

* Hide truncated data warning for list view

* Fix PK drilll

* Don't memo formatted rows

* Fix virtualization

* Use drills for sorting

* Fix virtualization flickering

* Fix drills

* Disable viz settings for list view

* List view visual enhancements (#62124)

* spaecing and font styling

* add entity_type icons to listitems

* display 4 columns instead of 5

* change icon for transaction tables

* add circle for boolean fields

* add badge style to category columns

* add colors to badges, incl Score cols

* Save list questions as tables

* Footer

* Padding and scrolling

* Styling

* Styling

* Remove icon

* Fix useObjectDetail call for ListView

* Fix list view columns alignment

* Move detail view breadcrumbs to AppBar

* Style breadcrumbs

* Fix scrolling

* Show icon if avatar is missing

* Fix react key warning

* Align breadcrumbs with detail view page

* Remove arrow navigation and footer

* Styling

* Error handling

* Styling

* Make Detail View breadcrumbs preserve card settings

* Make DetailView breadcrumbs return to previous ListView state

* Add company, currency, and receipt icons (#62196)

* add company currency and receipt icons

* add new icons to IconName and Icons obj

* Remove duplicate 'currency' icon declaration

---------

Co-authored-by: Stas Gavrylov <stasgavrylov@gmail.com>

* Update icons for TransactionTable and CompanyTable

* Make titleColumn always present. Update categoryValue styling

* ListView: Extract rendering logic to ColumnValue component

* Add tooltips for large column values

* Make list item grid always have at list 1 column

* Refactor DatasetEditorInner to typescript

* Rename DatasetEditor 'metadata' mode to 'columns'. Add new 'Metadata' tab for list view

* List view customization styling fixes (#62546)

* fix font sizes and spacing

* styling on ReorderableTagsInput

* make the viewsidebar 400px

* Make ReorderableTagsInput dropdown behave like multi-select

* Fix saving. Remove ViewStyleToggle

* Refactor List view to proper viz settings. Fix bugs. Remove TabHint popup

* Remove TabHintToast completely

* Fix container highlight when dragging between inputs

* Fix column settings in ListViz. Fix eslint

* Remove legacy DetailView code

* PR Cleanup

* Fix settings in list item preview

* Fix sorting. Replace custom column items with ColumnItem

* Fix saving models with list display type

* Fix incorrect condition to save list view models as tables

* Fix incorrect columns param in ListViewColumnsSidebar

* Fix list entity icon hover

* Tests – Models List View (#62836)

* Add storybook for ReorderableTagsInput

* wip

* Unit tests for ReorderableTagsInput

* Fix models-metadata related e2e tests

* e2e tests for List View

* Fix eslint

* Unit tests fixes

---------

Co-authored-by: Kamil Mielnik <kamil@kamilmielnik.com>
Co-authored-by: Anton Kulyk <kuliks.anton@gmail.com>
Co-authored-by: Maz Ameli <maz@metabase.com>
2025-08-29 17:58:38 +03:00
Ngoc Khuat
35e712e21b fix permissions when running transform as background job 2025-08-29 21:58:22 +07:00
github-automation-metabase
4bfd392609 Update generated docs (master) (#62928)
Co-authored-by: github-actions <github-actions@github.com>
2025-08-29 14:52:11 +00:00
Alexander Polyankin
ed9ed5b85f Fix the UI for partial between parameter values (#62614) 2025-08-29 10:40:49 -04:00
Brad Anderson
53958ef6fb UXW-57 Updates SmartScalar comparison text so it reuses existing, localizable strings (#62890) 2025-08-29 10:40:08 -04:00
Jeff Bruemmer
e263d6b598 don't document metabot env vars (#62919)
* don't document metabot env vars

* more settings

* another setting

* more settings
2025-08-29 14:21:27 +00:00
github-automation-metabase
41b42da633 chore(sdk): Update published npm version to 0.57.0-alpha.1 (#62920) 2025-08-29 14:00:29 +00:00
Nicola Mometto
5003a1e5ca explicitely pass cancel-chan 2025-08-29 14:10:20 +01:00
Nicola Mometto
949096259a style 2025-08-29 14:00:02 +01:00
Nicola Mometto
4feb3d4230 refactor: use common function for running python-transform 2025-08-29 13:58:01 +01:00
Nicola Mometto
4be8421fae chore: lift utility function 2025-08-29 13:06:02 +01:00
Nicola Mometto
652c2a1799 fix 2025-08-29 12:13:06 +01:00
Nicola Mometto
668289e248 run python transform within virtual thread, conform to async api
Closes QUE-2302
2025-08-29 12:08:31 +01:00
Nicola Mometto
37417f1e1f chore: make sure permission issues don't impact file deletion 2025-08-29 10:53:56 +01:00
Nicola Mometto
6901a209e2 dead code 2025-08-29 10:26:28 +01:00
Chris Truter
67e37c58b4 Remove unused python client 2025-08-29 10:52:28 +02:00
Kamil Mielnik
9319fb8ca6 Do not lock scroll behind detail view sidesheet (#62857) 2025-08-29 07:47:48 +00:00
Jakub Chodorowicz
75e51b4368 Prg 118 backfill provider name field on be side (#62420)
* Populate provider_name field on startup health check

* Serve provider patterns from BE side

* cleanup tests and expand clojure host provider detection

* Fix provider detection test

* Fix regexes for supabase and timescale

* adjust module api exports to standards

* mark private function ins provider-detection namespace

* extend provider values to null and empty, skip backfilling on empty provider_name

* Don't hardcode postgres in health check provider detection

* Make providers api dynamic and ready to support more engines

* Sort lines providers and engines

* Move hostname field tests to a test folder

* memoize detected provider

* Fix for tests for private functions

* Fix import of DatabaseProviderName type

* Use update function for setting provider_name on health check

* Fix typo in test case

* Remove duplicate entry

* simplify detect-provider-from-database call

* Move postgres extra-info to postgres driver module

* Simplify provider update check on startup, use null value for unidentified

* match provider also using engine

* bit of cleanup

- just move the regexes into the postgres driver namespace
- remove regexes and turn them into strings since most databases will put
  them in yaml
- just test the public api
- simplify all the host and details checks. Database is a very standard
  shape on the backend

* allowing setting null to provider match is null, cleanup unused imports

* move postgres tests to postgres driver; add a few tests for yaml

# Conflicts:
#	test/metabase/driver/postgres_test.clj

---------

Co-authored-by: dan sutton <dan@dpsutton.com>
2025-08-29 09:38:27 +02:00
Ngoc Khuat
65e54c1d17 fixex test run 2025-08-29 12:34:29 +07:00
Alexander Polyankin
894290024a Skip loading field values when possible in Table metadata (#62699) 2025-08-28 20:55:13 -04:00
Romeo Van Snick
c47c99e3af Add repro for metabase#46541 (#62719) 2025-08-29 10:02:37 +10:00
Fraser
549b72685e Fix for code scanning alert no. 512: Insecure randomness (#62852)
* Potential fix for code scanning alert no. 512: Insecure randomness

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>

* Handle max = 1 case

---------

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
2025-08-29 11:40:38 +12:00
Tyler Plude
5c7bc9630e [METABOT] Do not apply update-keys to ai-service request state (#62137)
* Do not apply update-keys to state

* Add comment documenting the intentional order

* remove recursive snake case update

* apply fix to both streaming and non streaming

* adding kebab->snake helpers that ignore camelcase

* Fix kondo

---------

Co-authored-by: Thomas Schmidt <thomas@metabase.com>
2025-08-28 15:28:58 -07:00
Sloan Sparger
e591235f8a [Search] Fix schema version number for search snowplow event (#62897) 2025-08-28 22:27:27 +00:00
Robert Kosara
fde1fa7173 Update timezone troubleshooting guide (#62888)
This is based on this discussion with Marcos: https://metaboat.slack.com/archives/C01R1JY03J4/p1756173436062039

It appears that we do set a reporting time zone for SQL queries, but it did not have an effect in my own testing on my local MariaDB. However, it works just fine when running the "official" Docker version of MariaDB.
2025-08-28 20:33:47 +00:00
Tyler Plude
ebbe91df3c [BOT-316] Metabase BE support for dynamic agent profiles (#62544)
* dynamic profile support

* kondo fixes

* fixing tests by adding metabot premium feature flag

* profile-id-whitelist env var

* metabot-id-whitelist env var

* Revert "metabot-id-whitelist env var"

This reverts commit e46ef63242.

* Revert "profile-id-whitelist env var"

This reverts commit 4e579e96a3.
2025-08-28 13:30:17 -07:00
Anton Kulyk
69d55d3b84 Fix vertical legend position for cartesian charts (#62602) 2025-08-28 16:24:15 -04:00
Noah Moss
963bcc28fe Exclude other personal collections in search-app context (#62307)
* Exclude other personal collections in search-app context

* Fix up test assertions
2025-08-28 16:04:37 -04:00
ignacio
8e11381d68 typo in embedding js docs (#62878)
Mini typo
2025-08-28 15:47:21 -03:00
Alexander Polyankin
39107da5c3 Fix the default value for case-sensitive for string filter clauses (#62874) 2025-08-28 18:13:48 +00:00
Timofey Kachalov
101fb38bfc feat(sdk): Fix and improve Metabot for SDK (#62822) 2025-08-28 22:12:25 +04:00
Riley Thompson
65e2a389ca Allow specifying athena hostname (#62438)
* allow specifying athena hostname

* use hostname

* fix params

* add test and clarify hostname field

* update helper text

* Apply suggestion from @jeff-bruemmer

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>

* update hostname field

* apply suggestion

* improve test

---------

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>
2025-08-28 17:24:42 +00:00
Chris Truter
57ef35fd81 Better default schema, better docstring 2025-08-28 19:11:21 +02:00
Dan Stone
2c8296bf53 BOT-319 Sem search dead letter queue (DLQ) (#62070)
* Add dead letter queue for the semantic search indexer

The DLQ system handles failed semantic search indexing operations if they are causing the indexer to stall.

- Applies back-off policies for retries (hard coded for now).
- Prevents batch poisoning from blocking indexer progress.

* Add the jitter factor I mistakenly deleted

* Doc fixes

* Slightly better stall recovery log

* Kondo

* Index attempt_at on DLQ table

* Add some more logging

* Init includes DLQ creation

* Fix some rebase collisions

* Formatting

* Add some asserts to show dlq creation during init

* Name test fixed with hashing

* Inline table-name-prefix

* Bump index meta version

* Prefer hex to b64 for table/index names they remain usable unescaped.

* Fix next-dlq-run test in on-indexing-idle

The test was backwards, so the loop only idled when `next-dlq-run` was due, rather than avoiding idle in that case.

* Ensure exit-early-due-to-cold-data? even if we have no last-seen-change

Ensure we still yield back to quartz if more than exit-early-cold-duration seconds have elapsed since the loop start
and we have no last-seen-change. This can happen in cases where no docs were updated since the loop start if our
watermark is already at the end of the gate table.

* Reduce log level to :trace for "nothing to do" case in indexing-step

* Whitespace cleanup

* Reduce ee-search-indexer-exit-early-cold-duration from 30s to 5s

30s is longer than the quartz interval for the indexer job, so we'll just get rescheduled immediately after yielding
control.

* Increase the run-frequency for the SemanticSearchIndexer job from every 10s to every 20s

* Move table-exists? into shared util ns and reuse

* Simplify honeysql qualified col reference in add-entries!

* Fix comment typo: s/indexes/indexer/

* Add missing seq in try-batch!

* Change ee-search-indexer-exit-early-cold-duration back to 30s

This value needs to be higher than the dlq-frequency, otherwise the dlq never runs.

---------

Co-authored-by: Mike Appleby <86076+appleby@users.noreply.github.com>
2025-08-28 09:21:12 -07:00
Jeff Bruemmer
8413b6a841 docs - basic metabot docs (#62842) 2025-08-28 16:16:26 +00:00
dpsutton
1dff00b209 Fix store default value (#62873)
in dev, the default value was the staging store. When not in dev, the
default value of this url was "false"

```
❯ http get http://localhost:3056/api/session/properties Cookie:"metabase.SESSION=d10a4524-837e-4aaf-84a3-b2f99bc9ecb2" | jq '."store-url"'
"false"
```

In javascript, most of the store url stuff is through

```javascript
export function useStoreUrl(storePath: StorePaths = "") {
  return useSelector((state) => getStoreUrl(state, storePath));
}
```

which is based on `getStoreUrl` which is

```
const DEFAULT_STORE_URL = "https://store.metabase.com/";

...

export function getStoreUrl(state: State, path: StorePaths = "") {
  try {
    const storeUrl = getSetting(state, "store-url");
    const url = new URL(path, storeUrl);
    return url.toString();
  } catch {
    return DEFAULT_STORE_URL;
  }
}
```

So what happens normally is:
1. in dev, we usually have no setting set for this, so the `when-some`
hits nil. If you do have something there, it is honored.
2. In prod, we read false for the config/is-dev and we use that as the
setting value

```clojure
settings=> (with-redefs [config/is-dev? false]
             (store-url-default))
"false"
```

3. There are lots of usages of this on the frontend. But they are all
protected by the try/catch and returning the default store. This is LOAD
BEARING in production.

```javascript
new URL("false", null)
Uncaught TypeError: Failed to construct 'URL': Invalid base URL
```

4. Cloud migration does something slightly different and so fails to get
this load bearing try/catch. It takes a `checkoutUrl` in its props:

```javascript
export const MigrationSuccess = ({
  migration,
  restartMigration,
  isRestarting,
  checkoutUrl,
}: MigrationSuccessProps) => {
```

This manually constructs a url:

```javascript
  const checkoutUrl = useMemo(() => {
    return migration
      ? `${storeUrl}/checkout?migration-id=${migration.external_id}`
      : `${storeUrl}/checkout`;
  }, [migration, storeUrl]);
```

And now we don't have the benefit of the `URL(base, extension)` which
would have (dumbly) failed closed. So now we end up with
`false/checkout?...` and then get a "We're a bit lost" locally

So to recap:
we do the right thing in dev, and then production is broken. Most
pathways were just catching this error, one way constructed a url
fragment and therefore was susceptible.

```clojure
settings=> (with-redefs [config/is-dev? false]
             (store-url-default))
"false"
settings=> (store-url-default)
"https://store.staging.metabase.com"
```
2025-08-28 11:10:08 -05:00
Alexander Polyankin
b43945927a Do not allow mixed query and last used parameter values (#62672) 2025-08-28 11:44:14 -04:00
Sébastien
d2e66d0081 Closes GIT-7894 302 redirect should not affect /properties (#62664)
* Closes GIT-7894 302 redirect should not affect /properties

* .

* .
2025-08-28 17:27:23 +02:00
Chris Truter
576c774001 Demo guide for Nico 2025-08-28 17:21:48 +02:00
Chris Truter
07c8dfab7c Slightly less wonky readme 2025-08-28 17:15:15 +02:00
Nicola Mometto
fe26b3ba57 chore: simpler code 2025-08-28 16:12:05 +01:00
Ryan Laurie
a40beb072a Fix Admin Nested Navlink Behavior (#62771)
* fix navigating on folders

* fix types

* conditional path for whitelabeling
2025-08-28 14:21:51 +00:00
Jeff Bruemmer
720c8513c5 relative links (#62827) 2025-08-28 09:24:54 -04:00
Nicola Mometto
a7ab68a82a kondo 2025-08-28 14:21:26 +01:00
Nicola Mometto
8a5b76955d dead code 2025-08-28 14:18:03 +01:00
Ngoc Khuat
dd3e9ffb8d run test 2025-08-28 20:11:02 +07:00
Chris Truter
c1adff4357 Get rid of anemic proxy layer 2025-08-28 15:01:39 +02:00
Phoomparin Mano
8dc14759a1 Fix flaky test for metabase-browser custom element (#62633) 2025-08-28 19:58:17 +07:00
Nick Fitzpatrick
e6d4839ffc Only clear card defer if request was not already cancelled (#62833) 2025-08-28 09:33:28 -03:00
Nicola Mometto
b90e090fec wip: disable pyexec user for now 2025-08-28 13:08:34 +01:00
Uladzimir Havenchyk
33c3ef25dc ci: use openldap from legacy registry (#62859) 2025-08-28 11:23:51 +00:00
Sébastien
b7a16be235 Closes EMB-760 table columns translations (#62760)
* Closes EMB-760 table columns translations

* Update e2e/test/scenarios/admin/i18n/content-translation/dashboards.cy.spec.ts

Co-authored-by: Phoomparin Mano <poom@metabase.com>

---------

Co-authored-by: Phoomparin Mano <poom@metabase.com>
2025-08-28 13:05:07 +02:00
Nicola Mometto
b8d7c3fe1b re-enable auth 2025-08-28 11:40:29 +01:00
Nicola Mometto
74efddd5f4 feat: communicate via files in python runner/server 2025-08-28 11:39:40 +01:00
Nicola Mometto
945263e788 feat: use jsonl files as transport layer 2025-08-28 11:23:22 +01:00
Nicola Mometto
11cf0a20b7 fix: actually delete temp files 2025-08-28 11:11:30 +01:00
Ngoc Khuat
04027d1310 source alignments 2025-08-28 15:57:17 +07:00
Ngoc Khuat
fdc0cdeb8b ensure tables are unique in tables selector 2025-08-28 15:44:11 +07:00
Ngoc Khuat
10d46bb28e Ensure we have the right permission when execute python 2025-08-28 15:14:41 +07:00
Romeo Van Snick
da1637a882 Allow opening dashboard filters using keyboard (#62716)
* Do not pass Sortable attributes when element is not sortable

* Render parameter value trigger as button

* Add repro for metabase#52674

* Use UnstyledButton

* Do not render parameter widget as button when it does not have a popover

* Update Loki Snapshots

* Use UnstyledButton and Box

* Fix syntax error

---------

Co-authored-by: Metabase Automation <github-automation@metabase.com>
2025-08-28 16:06:24 +10:00
Chris Truter
02afe10001 Persistent container (#62839) 2025-08-27 23:22:05 +02:00
Brad Anderson
cbe38462e2 Fix: UXW-569 Add Error message for failed document saves (#62834)
* UXW-569 Displays error toast when saving or creating a document fails
2025-08-27 16:35:46 -04:00
Brad Anderson
66fff2949c Fix: UXW-204 don't show upsells to non-admins on paid plans (#62816)
* UXW-204 Prevents non-admins from seeing "Explore paid features" link

* UXW-204 Adds unit tests, removes unused prop
2025-08-27 16:35:14 -04:00
Brad Anderson
434a9bd053 Fix: #62732 Documents editor hijacks browser keyboard shortcuts (#62773)
* #62732 Prevent tiptap StarterKit from hijacking cmd/ctrl+shift+b
2025-08-27 16:34:19 -04:00
Brad Anderson
54e84ef141 Fix: UXW-564 CMD-Z on an existing Document removes all content (+ other edge case) (#62692)
* UXW-564 Resets document undo/redo history when a new one loads in

* UXW-564 Adds e2e test
2025-08-27 16:33:45 -04:00
Alexander Polyankin
79580a4fec Fix caret issue introduced by mantine 8.2.2 (#62751) 2025-08-27 19:56:34 +00:00
Noah Moss
680672d641 Add discouraged-namespace kondo rule for clj-time (#62764) 2025-08-27 14:48:53 -04:00
Oleksandr Solovyov
eb5c21f8b4 update jspdf to 3.0.2 (#62798) 2025-08-27 17:13:21 +00:00
Chris Truter
4d8a8e93fb Fix up last few multi-table things 2025-08-27 18:47:09 +02:00
Nick Fitzpatrick
a5e72d83c5 Use Flexbox container to avoid CLS when on Collection Items Page (#62813) 2025-08-27 13:40:41 -03:00
Chris Truter
7528f2f3b0 Makefile 2025-08-27 18:35:54 +02:00
Chris Truter
d1660dba51 Fix input type for PK on creation (#62794) 2025-08-27 16:33:53 +00:00
Ngoc Khuat
7755c56386 multiple tables 2025-08-27 23:33:09 +07:00
Konstantin Darutkin
ccd51b88fa feat(enterprise): table data editing plugin (#61908)
* Reapply "feature(enterprise): table editing frontend plugin (#61326)"

This reverts commit 6970110108.

* Reapply "feat: hide enable editing setting for unsupported database drivers (#61544)"

This reverts commit 30bb713240.

* Reapply "fix: admin check and more tests (#61594)"

This reverts commit 71df2022c1.

* Trigger Build

* fix: send correct data for type/Date columns (#62095)

* fix: show user-friendly error messages from server (#62096)

* fix: show user-friendly error messages from server

* fix: review fixes

* fix: update grid design #1 (#62153)

* fix: udpate bulk row deletion design (#62155)

* fix: update expand row icon (#62268)

* fix: update expand row icon

* fix: review fixes

* fix: update editing grid cell styles (#62274)

* fix: change editing modals to sidesheets (#62276)

* inform admin about insufficient user permissions (#62395)

* fix: tests

* feat: add boolean input type (#62333)

* fix: typecheck

* fix: error display

* fix: hide table editing admin setting in some cases (#62552)

* feat: add numeric input types to table editing (#62554)

* feat: show unsaved leave confirmation for table editing modals (#62555)

* feat: show unsaved leave confirmation for table editing modals

* fix: modal order

* fix: review issues

* feat: check if tables are is_writable (#62484)

* feat: snowplow events for table data editing (#61914)

* fix: date editing test

* fix: disable date test due to flakyness

* fix: visual blocker for table data editing (#62722)

* fix: visual blocker for table data editing

* fix: tests

* Refactor browse hover actions to use ActionIcon (#62769)

* refactor to use ActionIcon

* fix bolt test

* Fix input type for PK on creation (#62794)

* fix: table editing bugs (#62796)

* fix: table editing bugs

* fix: tests

---------

Co-authored-by: Chris Truter <chris@metabase.com>
Co-authored-by: Ngoc Khuat <qn.khuat@gmail.com>
Co-authored-by: Maz Ameli <maz@metabase.com>
2025-08-27 09:30:49 -07:00
Chris Truter
65978ae49a Better convention 2025-08-27 18:03:16 +02:00
Chris Truter
7875745bfe Fixups 2025-08-27 18:03:16 +02:00
Chris Truter
2f778b9dd9 Support multiple tables on the runner side 2025-08-27 18:03:15 +02:00
Jeff Bruemmer
b7ce1a1bd5 Fix markdown links in Debian installation guide (#62823) 2025-08-27 11:37:40 -04:00
Braden Shepherdson
d5a0face2b [Mongo] Fix type inference for columns returned by native queries (#62777)
This was working for `:base_type`s but not `:effective_type`s.
The `:result_metadata` for a native Mongo query always had
`:effective_type :type/*` even when we correctly inferred the
`:base_type`.

Fixes #62397.
2025-08-27 11:04:09 -04:00
Riley Thompson
0358ebe99d Enable DB routing for ClickHouse (#62090)
* initial commit

* enable multi db by default for tests

* multi db as default, set inclusion filters for tests

* update introspection tests

* enable routing

* set enable multi db true as default

* use redef for spec

* clean up

* add more generic test

* update tests

* remove unused code

* clean up

* handle encrypted migration

* fix test and migration id

* move created and updated at fields

* more tests

* mark tests parallel

* fix whitespace

* fix athena test
2025-08-27 14:59:40 +00:00
Nicola Mometto
3b3ec3e396 cleanup 2025-08-27 15:44:37 +01:00
Nicola Mometto
fa1946c7d9 wip: empty token rather than nil, else shell/sh args parsing gets confused 2025-08-27 15:37:54 +01:00
Nicola Mometto
decf483773 feat: don't go through QP, reducible-query 2025-08-27 15:37:54 +01:00
Filipe Silva
7866ca3e84 fix: ignore case when offering metabot purchase (#62808) 2025-08-27 15:22:43 +01:00
Ngoc Khuat
0a82070f27 FE select table when creating python transform 2025-08-27 20:43:14 +07:00
Nick Fitzpatrick
e77320ac9e Git 7934 legends are cut off on pie charts when in documents (#62772)
* render pie charts more like dashcards in documents

* updating ChoroplethMap for documents
2025-08-27 10:42:54 -03:00
Chris Truter
21486dd01b Assume exactly 1 source table, preselected 2025-08-27 15:41:18 +02:00
Chris Truter
4ce5db9db3 WIP get table passed in 2025-08-27 15:30:35 +02:00
Sloan Sparger
9ccb92ab46 [Metabot] Add capabilities to metabot context (#62464)
Expose Metabase instance capabilities in ai-service context for Metabot

---------

Co-authored-by: Thomas Schmidt <thomas.heinz.schmidt@gmail.com>
Co-authored-by: Thomas Schmidt <thomas@metabase.com>
Co-authored-by: Alexander Solovyov <alexander@solovyov.net>
2025-08-27 13:18:02 +00:00
Alexander Polyankin
15e73ac7cf Reset parameter values if all parameters are equal to new values, not per parameter (#62757) 2025-08-27 09:12:23 -04:00
Nicolò Pretto
e5e2ff55fa chore(sdk e2e): make the "Invalid Host/Origin header" errors go away (#62803) 2025-08-27 14:32:13 +02:00
Ngoc Khuat
781045b019 TODO for python transform dependencies 2025-08-27 18:41:05 +07:00
Ngoc Khuat
fa2cbffbd5 python transforms now properly being scheduled 2025-08-27 18:39:55 +07:00
Jeff Bruemmer
e4e3f15eff Clarify JWT Identity Provider URI instructions (#62765)
Updated the instructions for the JWT Identity Provider URI to clarify the use of localhost and Cloud URL.
2025-08-27 07:34:22 -04:00
github-automation-metabase
66dbc98ff7 Update generated docs (master) (#62787)
Co-authored-by: github-actions <github-actions@github.com>
2025-08-27 07:33:41 -04:00
Chris Truter
00a034905b Fix uploads not being immediately editable (#62795) 2025-08-27 08:37:01 +00:00
Sébastien
d8aa553a09 Closes EMB-650 statics embedded dashboard export icon overlapped with tab (#62685)
* Closes EMB-650 download button overlaps with tabs

* loki test

* addressed comments
2025-08-27 09:00:15 +02:00
Romeo Van Snick
1aad10c239 Avoid scrolling on autoconnected message (#62718)
* Avoid overflow when showing auto-connected label

* Add repro for metabase#46372
2025-08-27 05:26:23 +00:00
Nathan Voxland
1ae8ff82e5 Change driver/humanize-connection-error-message to be passed a list messages, not a single message (#62634) 2025-08-26 22:53:38 -05:00
Aleksandr Lesnenko
ecfa6ea920 add yarn storybook-pure command (#62768) 2025-08-27 02:18:07 +00:00
Noah Moss
de01ff004e Fix conversion of pivot value keys to consistent types (#62762) 2025-08-26 18:20:15 -04:00
Robert Kosara
a075a22dac Add documentation for password settings on Metabase Cloud (#62767)
* Update docs/people-and-groups/changing-password-complexity.md

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>
2025-08-26 21:09:50 +00:00
Uladzimir Havenchyk
7da39401a4 chore: upgrade vulnerable cipher-base package (#62559) 2025-08-26 20:33:10 +00:00
Jeff Bruemmer
b1a819ad57 note on pinning (#62774) 2025-08-26 16:28:14 -04:00
Nathan Voxland
6a0f4e8070 Improved SQL generation for document charts (#62548) 2025-08-26 15:23:29 -05:00
Cam Saul
a941f1d9c2 validate-temporal-bucketing middleware => Lib (#62632) 2025-08-26 16:03:16 -04:00
Timofey Kachalov
8717a4fc02 refactor(sdk): Move storybook SDK configs to the embedding-sdk-shared directory (#62675) 2025-08-26 23:57:51 +04:00
appleby
7227b7d97c Add bookmarked scorer to semantic search backend (#62709)
* Add bookmarked scorer to semantic search backend

* Update appdb backend to use shared bookmarked scorer in search.scoring

* Fix whitespace / alignment

* Review feedback: s/filtered-search-results/search-results-to-score/
2025-08-26 19:52:31 +00:00
Riley Thompson
ef1273e815 Handle nulls in arrays (#62756)
* handle nulls in arrays

* use suggestion
2025-08-26 19:27:08 +00:00
Rodrigo López Dato
76b863c7ea Update Debian/systemd docs (#62701)
* Update Debian/systemd docs

* Remove references to Debian

* Use H2 database in .env file by default

* Add journalctl command to follow logs

---------

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>
2025-08-26 19:04:12 +00:00
Nick Fitzpatrick
849be9e037 Add border to top of Document page when sidebar is open (#62577)
* add border to top of page when sidebar is open

* do what metabot do
2025-08-26 15:29:11 -03:00
Ngoc Khuat
0695681d7c remove the hack of using local files as well 2025-08-27 00:49:55 +07:00
Ngoc Khuat
b5a67bf540 call api proxy instead of internal call, also have settings page for transform 2025-08-27 00:29:55 +07:00
Ngoc Khuat
83744d69a7 Transform life cycle macro and fix unable to run failed transform
repeatedly
2025-08-27 00:29:19 +07:00
Aleksandr Lesnenko
e5e2c767a0 fix overflowing text in tables (#62708)
* fix overflowing text in tables

* thanks cubic
2025-08-26 17:28:27 +00:00
Dan Stone
31650d2f87 Save message including stdout/err to the database on failure
Resolves QUE-2296
2025-08-26 18:05:36 +01:00
Dan Stone
c19a5dab9e Fix edit button not doing anything for python scripts
Closes QUE-2300
2025-08-26 17:44:52 +01:00
appleby
84763ca40d Refactor appdb-based scorers in the semantic search backend (#62690)
* Refactor appdb-based scorers in the semantic search backend

Refactor the appdb-based scorers in the semantic search backend in preparation for adding the bookmarked scorer in
BOT-312. This refactor has several benefits: (1) makes the appdb-based scorers work more like the existing index-based
scorers; (2) allows sharing the exact same honeysql expressions for the user-recency-expr and model-rank-expr between
the appdb and semantic backends, reducing code dup; (3) makes it easier to add the bookmarked scorer since it will be
able to reuse the appdb backend's honeysql expr for bookmarked scores as well.

* Move user-recency-expr into search.scoring and use it in appdb and semantic backends

* Move model-rank-expr into search.scoring and use it in appdb and semantic backends

* Move mysql check from with-appdb-scores into appdb-scorers

Again in preprartion for adding the appdb-based bookmarked scorer later.

* Fix whitespace
2025-08-26 09:33:08 -07:00
Maz Ameli
ffd615080b clarify text in new-transform menu (#62679)
* clarify text in new-transform menu

* update tests
2025-08-26 09:16:21 -07:00
dpsutton
bfcdbd2cda Better branch detection if relevant files are changed for CI (#62705)
I noticed that
https://github.com/metabase/metabase/pull/62513/files?file-filters%5B%5D=.clj&show-viewed-files=true
that the third tier drivers were running. Checking the action output
https://github.com/metabase/metabase/actions/runs/17220604727/job/48854867380?pr=62513
i see :

```
Is master or release: false
Has '.Team/Drivers' or '.Team/Querying' or '.Team/SemanticLayer' label: false
Checking for changes in relevant folders...
Changes detected in the following folders: src/metabase/lib src/metabase/query_processor.
Tier 3 driver tests will run.
```

So it thinks that something changed in src/metabase/lib/* and
src/metabase/query_processor/*

This branch
ds/clo-4370-button-in-metabase-admin-section-to-purchase-metabot-ai-add
targets master. And the diff is checking the diff of files between the
state of master and the PR. Which means if any changes have landed in
master affecting those areas this diff will report positive.

At the time of this writing this is:
```
❯ git diff --name-only c6a9193bff 462d83c5c2 | wc -l
    1259
```

Where c6a9 is master and 462 is the branch.

A better option is to find where the branch and the merge target share a
common ancestor and then check for changes from there.

```
❯ git diff --name-only $(git merge-base c6a9193bff 462d83c5c2) 462d83c5c2 | wc -l
      32
```

So we use `git merge-base <master> <branch>` and then diff that sha
against the branch.

```
git diff --name-only (git merge-base <base> <pr-branch>) <pr-branch>
```

And we get:

```
❯ git merge-base c6a9193bff 462d83c5c2
37e6eee311

❯ git show 37e6eee311
commit 37e6eee311
Author: Phoomparin Mano <poom@metabase.com>
Date:   Wed Aug 20 01:40:19 2025 +0700

    Add the metabase-browser custom element to Embed JS (#60828)

    Co-authored-by: cubic-dev-ai[bot]
    <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
```

Which is the common root. Then the diff from there:

```
❯  git diff --name-only $(git merge-base c6a9193bff 462d83c5c2) 462d83c5c2
.clj-kondo/config/modules/config.edn
enterprise/backend/src/metabase_enterprise/api/routes.clj
enterprise/backend/src/metabase_enterprise/cloud_add_ons/api.clj
enterprise/backend/src/metabase_enterprise/harbormaster/client.clj
enterprise/backend/test/metabase_enterprise/api/session_test.clj
enterprise/backend/test/metabase_enterprise/cloud_add_ons/api_test.clj
enterprise/frontend/src/metabase-enterprise/metabot/components/MetabotAdmin/MetabotPurchasePage.tsx
enterprise/frontend/src/metabase-enterprise/metabot/components/MetabotAdmin/MetabotPurchasePage.unit.spec.tsx
enterprise/frontend/src/metabase-enterprise/metabot/components/MetabotAdmin/MetabotPurchaseSettingUpModal.tsx
enterprise/frontend/src/metabase-enterprise/metabot/index.tsx
frontend/src/metabase-types/api/metabot.ts
frontend/src/metabase-types/api/mocks/settings.ts
frontend/src/metabase-types/api/settings.ts
frontend/src/metabase/admin/app/reducers.ts
frontend/src/metabase/admin/routes.jsx
frontend/src/metabase/api/metabot.ts
frontend/src/metabase/api/utils/use-token-refresh.ts
frontend/src/metabase/common/components/AdminLayout/AdminSettingsLayout.tsx
frontend/src/metabase/plugins/index.ts
resources/frontend_client/app/assets/img/metabot-cloud-96x96.svg
src/metabase/cloud_migration/core.clj
src/metabase/cloud_migration/models/cloud_migration.clj
src/metabase/cloud_migration/settings.clj
src/metabase/core/init.clj
src/metabase/premium_features/core.clj
src/metabase/premium_features/settings.clj
src/metabase/premium_features/token_check.clj
src/metabase/server/middleware/security.clj
src/metabase/store_api/core.clj
src/metabase/store_api/init.clj
src/metabase/store_api/settings.clj
test/metabase/analytics/stats_test.clj
```

And now we have a correct list of files changed in that PR, not just
files different between current master and current PR.
2025-08-26 11:09:05 -05:00
Dan Stone
b32310dad9 Revert "Fix wrong source field name used for showing script in transform view"
This reverts commit c7dfb541f3.
2025-08-26 16:31:47 +01:00
github-automation-metabase
6f461a78b5 chore(sdk): Update published npm version to 0.57.0-alpha.0 (#62749) 2025-08-26 15:16:41 +00:00
Nicola Mometto
e1e553e39c fix tests 2025-08-26 15:56:56 +01:00
Noah Moss
873f5830d0 Migrate remaining clj-time usages to clojure.java-time (#62696)
* Convert revision usage

* convert pivot test + metabot usages

* convert more tests

* migrate final clj-time usage in logger.core

* switch quartzite to a git sha to get most recent commit w/o clj-time

* Revert "switch quartzite to a git sha to get most recent commit w/o clj-time"

This reverts commit 393bc56aad.
2025-08-26 10:49:09 -04:00
Nicola Mometto
b6c062b365 fix test 2025-08-26 15:47:44 +01:00
Nicola Mometto
22a294c135 Merge branch 'QUE-2298' into proj-python/s01e01 2025-08-26 15:38:33 +01:00
Timofey Kachalov
e141921ac8 Use jq for getting the SDK release tag (#62748) 2025-08-26 18:38:00 +04:00
Nicola Mometto
012c0e5661 disable auth for now.. 2025-08-26 15:33:17 +01:00
Dan Stone
c7dfb541f3 Fix wrong source field name used for showing script in transform view 2025-08-26 15:30:00 +01:00
Nicola Mometto
1ea8c670f7 fix for docker/win 2025-08-26 15:29:52 +01:00
Nicola Mometto
7ed9553ee3 fix 2025-08-26 15:12:46 +01:00
Nicola Mometto
ba67bef0d2 remove connection string, pass metabase-url instead 2025-08-26 14:59:33 +01:00
Dan Stone
6902bb5020 Use :dbname if :db is not present for conn
For me this was the case
2025-08-26 14:54:05 +01:00
Timofey Kachalov
8442c3a3fd Prepare build scripts for determine-sdk-version job (#62740) 2025-08-26 17:42:01 +04:00
Nicola Mometto
e6cf33c740 query tables via api 2025-08-26 14:23:54 +01:00
Nicola Mometto
39daa3258a fix: docker compose 2025-08-26 14:13:16 +01:00
Nicola Mometto
ef60fa5ee5 wip: table/:id/data endpoint 2025-08-26 14:04:28 +01:00
Alexander Polyankin
9ec5f14c6b Make linking top-level parameters with inline parameters in dashboard work (#62691) 2025-08-26 09:00:52 -04:00
Alexander Polyankin
affd550c24 Ignore unsaved parameters when executing dashboard card queries in edit mode (#62680) 2025-08-26 09:00:27 -04:00
Alexander Polyankin
454598b4c0 E2E repro for "Model is being expanded to data sources after edit/distribute" (#62671) 2025-08-26 09:00:16 -04:00
Timofey Kachalov
c2016c28c8 Fix sdk pre-release version calculation and test-unit glob (#62729) 2025-08-26 16:42:40 +04:00
Kamil Mielnik
7dd4936c57 Detail view (#62011)
* Boilerplate

* Remove processRemappedColumns, add layout

* Navigation

* Back button,breadcrumbs

* TODO

* Layout

* Layout

* Refactor

* Column detection logic

* Inline

* Fix

* Extract Breadcrumb

* Fix

* Entity name in nav

* Condition

* Fix

* Header

* Style

* Remove

* Do not render header if no column can be used there

* Body

* Sidebar

* Style

* Copy

* Hover style

* Remove back button

* Overflows

* a11y

* Redundant css

* Fix

* Fix rendering

* Style links

* Cleanup

* FK pill

* Render images

* Prevent showing old images while new are loading

* Take currency_in_header into account

* Cleanup

* Refactor relationships

* Update PK drill

* PK drill

* Fix

* Fix

* Fix copy if row name is not available

* Max height for values

* Fix PK drilll

* Fix drills

* Footer

* Padding and scrolling

* Styling

* Styling

* Remove icon

* Move detail view breadcrumbs to AppBar

* Style breadcrumbs

* Fix scrolling

* Show icon if avatar is missing

* Fix react key warning

* Align breadcrumbs with detail view page

* Remove arrow navigation and footer

* Styling

* Error handling

* Styling

* Support models

* ESLint

* Types

* Types

* Make FK drill take user to the new page

* Update model-indexes.cy.spec.js

* Only consider PKs from the raw underlying source table

* Fix URL

* Revert "Only consider PKs from the raw underlying source table"

This reverts commit c408188fce.

* Revert filtering by source table

* Rename DetailView to DetailViewPage

* Add DetailViewSidesheet boilerplate

* Revert e2e changes

* Lift state

* Rename

* Bring back old drills

* Format code

* Use sidesheet

* Custom stylesheet component

* Styling

* Fix FKs

* Paddings

* Shadow

* Spacing

* Cleanup

* Prev/next buttons

* Add url buttons

* Implement url generation + update model page url

* Fix

* Highlight zoomed row

* Fix

* Memo

* Fix interactivity when object detail is open

* Remove autofocus

* Fix tooltip

* Consistent close button

* Aria

* Pixel-perfect

* Fix types

* Fix FK pill rendering

* Fix types

* Fix

* Fix

* Fix remapping

* Fix types

* Move test id

* Use proper cols

* Remove dead code

* Add testid

* Fix unit test

* Update unit test

* Lift qb redux state usage from TableInteractive to DatasetEditorInner

* Add ... button and separators

* Add object actions menu

* Move getObjectQuery

* Fetch row if missing, update tests

* Update tests

* Update tests

* Update tests

* Hide nav when not useful

* Update tests

* Update tests

* Fix Esc handling

* Arrange separators

* Make sidesheet work without table prop, which is the case in native questions

* Fix viz settings not being applied

* Refactor

* Handle 404s, do not show rows that do not belong to a question

* Fix actions fetching

* Add test for Esc

* change view detials icon to sidebar_open (#62471)

* Use new icon everywhere

* Fix row highlighting in questions

* Toggleable object detail

* Remove todo

* Fix test

* Make table viz settings affect the detail view

* Fix types

* Move filterByPk

* Fix types

* Use MLv2 to generate query

* Refactor

* Refactor

* Add keyboard navigation

* Fix types

* Fix

* Fix

* Update copy

* Style links

* Make selectors safe

* Responsive detail page

* Re-use Urls.tableRowsQuery

* Use Divider

* Fix pills

* Use palette colors

* Detail view - Tests (#62576)

* Take sidebar presence into rwd calculations

* Add test

* Add a test for toggling

* Add assertions

* Add unit tests for Header

* Add comment

* Add test

* Add tests

* Add tests

* Remove comments

* Add tests

* Add tests and extract helpers

* Fix model breadcrumbs

* Clean up

* Rename tests

* Add 404 tests

* Sort

* Format code

* Add tests

* Add Relationship unit tests

* Clean up

* Handle errors

* Add tests

* Add tests

* Add tests for images

* Proper model breadcrumbs

* Fix ellipsis

* Add assertions

* Add assertions

---------

Co-authored-by: Maz Ameli <maz@metabase.com>
2025-08-26 18:30:09 +07:00
github-automation-metabase
21fefa6115 Update generated docs (master) (#62712)
Co-authored-by: github-actions <github-actions@github.com>
2025-08-26 07:09:47 -04:00
Nicola Mometto
386f8ce2ec fix: source-database-id for python transforms 2025-08-26 11:53:52 +01:00
Timofey Kachalov
21f673ccbb Fix release-embedding-sdk.yml syntax error (#62721) 2025-08-26 14:12:52 +04:00
Sébastien
f0448ada69 closes EMB-665 do not try to change embedding_params if dashboard is not embedded (#62496) 2025-08-26 11:14:49 +02:00
Nicola Mometto
34c3a5f9e6 quick fix for error detection 2025-08-26 09:57:14 +01:00
Nicolò Pretto
e1c0570dc5 feat(embed js flow): use widget for initial parameters (#62356)
* wip

* make parameter widget have the dropdown

* update tests

* cleanup

* slug -> id so that the parameter dropdowns on charts show the current
value

* remove deprecation message from addFields

https://metaboat.slack.com/archives/C063Q3F1HPF/p1755875062460719?thread_ts=1755874422.198989&cid=C063Q3F1HPF

* fix parmeters not really being set lol
2025-08-26 10:26:27 +02:00
Timofey Kachalov
1b89bf16ba ci(sdk): Adjust release CI workflow to release alpha versions from master branch (#62507) 2025-08-26 11:39:06 +04:00
Romeo Van Snick
43d2b9ac84 Make readOnly Notebook non-editable (#62388)
* Make readOnly notebook completely non-interactive

* Add readOnly prop to PopoverBackButton

* Add readOnly to FilterPickerHeader

* Add readOnly prop to FilterPickers

* Allow making filter body readOnly

* Pass readOnly to FilterPicker from FilterStep

* Add disabled prop to ClausePopover

* Disable step popovers when readOnly (except for filters)

* Do not disable pointer-events for notebook preview

* Disable popover when button is disabled

* Render readOnly expression popover in readOnly mode

* Make limit step readOnly when readOnly is set

* Add test for readonly notebook

* Disable tooltip on join picker when read-only

* Disable join picker popover when read-only

* Hide back button on date picker

* Simplify backbutton props

* Do not allow going back in readOnly ExpressionWidget

* Allow readOnly AggregationPicker

* Allow opening aggregation popover when it is an expression

* Render aggregation popover when it is a custom expression

* Fix types

* Remove renderPopoverWhenReadOnly flag

* Fix cursor logic on SortStep

* Do not render pointer cursor when step does not have popover

* Render custom expression popover for non-custom aggregations in read-only mode
2025-08-26 11:15:22 +10:00
William
c1a8102d17 Keep fields when adding aggregations, and ignore them when compiling (#62539)
What it says on the tin.  When we add an aggregation, don't drop :fields, but instead drop :fields when compiling a
stage with an aggregation.
2025-08-25 19:21:52 -05:00
Dennis Schridde
6bf6cb679d Button in Metabase Admin section to purchase Metabase AI add-on (#62513)
== Goal ==

In case the Metabase instance does not have the Metabot AI add-on, we
want to show a page in the admin section to purchase it.

== How to test ==

1. Pick a valid token from staging with the `offer-metabase-ai` feature, but without the `metabot-v3` feature (`metabase-ai` add-on)
2. Pick the token's instance's Metabase API key
3. Pick an email address that matches a store user of the token's organization
4. Spin up a Metabase instance with that API key, token and user
5. Navigate to the admin section, AI tab
6. See the new page to purchase the add-on and click the button

Closes: https://linear.app/metabase/issue/CLO-4370/button-in-metabase-admin-section-to-purchase-metabot-ai-add-on
2025-08-26 00:44:00 +02:00
Fraser
30c56819ca Use latest version for none available case (#62703) 2025-08-25 22:29:21 +00:00
Brad Anderson
52e84b6a7c Fix: UXW-503 Improve error handling for deleted embedded questions (#62618)
* UXW-503 Triggers error state when underlying card has been deleted

* UXW-503 Makes CardEmbed error state selectable, bordered

* UXW-503 Updates error state per design feedback (less of a jump between loading and error state, fewer different error visuals)

* UXW-503 Adds e2e test

* UXW-503 Removes useMemo per PR feedback

* UXW-503 Simplifies an e2e test, makes it less prone to flakiness
2025-08-25 17:48:53 -04:00
Noah Moss
c6a9193bff Add gate table tombstone cleanup to semantic search index cleanup task (#62605)
* Add gate table tombstone cleanup to index cleanup job

* add partial index on gated_at for just the tombstone rows

* fix up index creation syntax

* WIP - adding check that indexer ran within last 24 hours

* fix tests

* fix whitespace, adjust log/docstring

* kondo

* fix build, maybe broken from bad rebase?
2025-08-25 15:54:13 -04:00
Rodrigo López Dato
f1e4a05f67 Fix references to pre-56 Troubleshooting admin menu (#62695) 2025-08-25 16:31:35 -03:00
Nicola Mometto
7ea8fc3b61 convert mysql booleans to real booleans during semantic indexing (#62578)
* Ensure mysql booleans are treated as real booleans

* add tests

* Update enterprise/backend/src/metabase_enterprise/semantic_search/index.clj

Co-authored-by: appleby <86076+appleby@users.noreply.github.com>

---------

Co-authored-by: appleby <86076+appleby@users.noreply.github.com>
2025-08-25 19:18:11 +00:00
Nick Fitzpatrick
79cc5d8230 Update Command Suggestion selected index on MouseEnter (#62603)
* Update selected index on MouseEnter

* support mention extension

* PR Feedback
2025-08-25 15:41:11 -03:00
Cam Saul
f4da670b85 Remove dead dimension options code (#62630)
* Remove dead dimension options code

* Remove EVEN MORE dead code.
2025-08-25 17:47:22 +00:00
Cam Saul
d4a2e17537 Remove pre-alias-aggregations QP middleware (#62606)
* Remove pre-alias-aggregations QP middleware

* Kondo
2025-08-25 17:44:09 +00:00
Jeff Bruemmer
e7edd17483 Update version.md with pinning instructions (#62678)
* Update version.md with pinning instructions

Clarified instructions on pinning SDK versions for Metabase Cloud instances.

* Update docs/embedding/sdk/version.md
2025-08-25 16:22:45 +00:00
Timofey Kachalov
1dcee6ed85 fix(sdk): Properly calculate the dirty state for the InteractiveQuestion.SaveButton button (#62423) 2025-08-25 20:13:40 +04:00
Nick Fitzpatrick
4f1ff924a8 Update document cache with creation result (#62612)
* update document cache with creation result

* update test
2025-08-25 13:11:09 -03:00
Edward Paget
c9777da390 fix: handle more header names in translation csv (#62241)
* fix: handle more header names in translation csv

Handle the locale being specified as 'locale', 'locale code', 'language'
also make the check for header a little looser so we can report errors
in the header row more accurately.

* fixup! have sample CSV match copy
2025-08-25 10:48:00 -05:00
Timofey Kachalov
c7ae69b2d7 test(sdk): Add tests for remaining exported from SDK public hooks (#62536) 2025-08-25 19:43:34 +04:00
Anderson
4f24f5fe40 Fix invitation not being sent from /setup flow (#62320)
* Call createUser action when inviting new user on the /setup page

* Add e2e test case

* Add invite_sent event / Check user went to next step in e2e test

* Let the backend handle the invite_sent snowplow event

* Change approach to set source value

* Fix unit tests

* Add unwrap() to createUser dispatch

* Remove unused invite param from the /setup endpoint

* Remove unneeded frontend code

* Fix kondo issues
2025-08-25 12:26:11 -03:00
Chris Truter
ce0372fd73 fixes 2025-08-25 17:18:55 +02:00
Sloan Sparger
694fbaa5a2 [Search] Increase search reporting (#62200)
* track search_engine

* track request id

* record request id on search_query event

* fix bug with search_click position not factoring in pagination

* report offset on search_query

* report on the entity model

* move changes into new schema file and update referenced schema

* add back view_more event

* track hashed + salted search term on search_click + search_query events

* refactor trackSearchClick to accept object param instead of long list of args

* report search term for internal purposes only

* pr feedback

* add test coverage for new search reporting attributes

* maybe fix e2e in ci

* fix failing e2e
2025-08-25 10:15:19 -05:00
Timofey Kachalov
be2773de2b Make SDK backward-compatibility tests required (#62561) 2025-08-25 18:56:57 +04:00
Chris Truter
6df12e022a Extract util that we'll need for demo 2025-08-25 16:55:47 +02:00
Chris Truter
5e5ff95ef7 test with temp db 2025-08-25 16:54:59 +02:00
Chris Truter
c8c39cfeb1 kondo 2025-08-25 16:54:59 +02:00
Timofey Kachalov
15f7d3d20e refactor(sdk): Split embedding-sdk-bundle directory into 3 directories (#62613) 2025-08-25 18:36:56 +04:00
Ngoc Khuat
89056a9d5d placeholder connection string 2025-08-25 21:31:28 +07:00
Ngoc Khuat
db4f81cb38 wire up with upload 2025-08-25 21:27:34 +07:00
Riley Thompson
b39d5925b0 Enable specifying a database for Athena (#62183) 2025-08-25 10:14:41 -04:00
Chris Truter
2daba8f0b4 read frames 2025-08-25 16:14:04 +02:00
Chris Truter
4e1bb2a25a Inversion of control to hide output file 2025-08-25 16:14:03 +02:00
Nick Fitzpatrick
8879b09200 Fix Back Button for document questions and drill thrus (#62519)
* generalize back button

* update document back button

* test adjustments

* back button on document question drill thru
2025-08-25 11:11:57 -03:00
Alexander Polyankin
c7b3f9e02d Fix canceling queries on Cmd+Enter (#62600) 2025-08-25 13:43:01 +00:00
Ngoc Khuat
9fcc08fc3a Assume all h2 tables are writable (#62485) 2025-08-25 13:29:14 +00:00
Alexander Polyankin
81611988c3 Preserve viz settings when doing drills in the raw table mode (#62509) 2025-08-25 09:22:10 -04:00
github-automation-metabase
bfa2adc9ce Update generated docs (master) (#62658)
Co-authored-by: github-actions <github-actions@github.com>
2025-08-25 09:18:13 -04:00
Alexander Polyankin
b4cc30dc29 E2E repro (#62588) 2025-08-25 09:11:37 -04:00
Alexander Polyankin
e236250e5b E2E repro for "Suggestion editor popover middle/right click closes the popover" (#62592) 2025-08-25 09:06:00 -04:00
Ngoc Khuat
7e9d0e6a2b wiring up with python executor 2025-08-25 19:44:15 +07:00
Ngoc Khuat
0e9f773d55 Integerate with FE 2025-08-25 19:24:42 +07:00
Ngoc Khuat
8ac019cefb CRUD python transform 2025-08-25 19:24:42 +07:00
Nick Fitzpatrick
0d677e4f51 analytics events for documents (#62447)
* analytics events for documents

* fixing unit test
2025-08-25 09:14:22 -03:00
Romeo Van Snick
aaf6c6c72e Allow entity picker skeleton to grow to top of container (#62659) 2025-08-25 12:03:25 +00:00
Chris Truter
ac78a328eb Stub python execution service api 2025-08-25 14:01:12 +02:00
Nicolo-Maria
0e915e0437 feat: add Python transform frontend pages 2025-08-25 12:42:08 +02:00
Chris Truter
d23bea5a3a Stub python container to execute user code 2025-08-25 12:30:30 +02:00
Uladzimir Havenchyk
4a2f553be7 chore: upgrade vulnerable sha.js package (#62558) 2025-08-25 12:42:20 +03:00
Timofey Kachalov
7337591710 Fix rspack library-related warning (#62660) 2025-08-25 13:01:25 +04:00
Oleksandr Yakushev
ed6ec28ab4 [pivot] Optimize pivot construction for both backend and frontend (#61477) 2025-08-25 01:36:42 +03:00
Aleksandr Lesnenko
250533e660 skip PreserveWhitespaceWrapped table flaky loki test (#62639) 2025-08-24 17:18:17 +00:00
Aleksandr Lesnenko
1c1b2ea9f4 hide edit visualization in view mode on visualizer cards (#62611) 2025-08-24 04:33:08 +00:00
Aleksandr Lesnenko
8cd9b383ad remove excessive font-weight from dashboard creation form (#62623) 2025-08-23 06:20:08 +00:00
Eric Normand
a673032d34 Localize rows of initial tags and initial jobs in db on setup or startup (#62301)
* Localize rows of initial tags and initial jobs in db on setup or startup

* Also translate job descriptions.

* Use fewer hits to the db on startup

* Use site locale

* kick ci

* Remove extraneous arg

* Remove extraneous strs

* Different translation model (on select)

* setup no longer needed from transforms

* Fix

* Test transform tag translation

* Test transform job initial translations
2025-08-22 18:00:38 -05:00
Denis Berezin
6829370337 Fix runtime crash on field visibility change with preview open (#62622)
* Fix runtime crash on field visibility change with preview open

* Update Loki Snapshots

---------

Co-authored-by: Metabase Automation <github-automation@metabase.com>
2025-08-23 01:19:46 +03:00
Denis Berezin
431cbbc6c3 Query builder breadcrumbs can link back to archived models (#62589)
* Query builder breadcrumbs can link back to archived models

* Update Loki Snapshots

---------

Co-authored-by: Metabase Automation <github-automation@metabase.com>
2025-08-23 00:28:22 +03:00
Aleksandr Lesnenko
29a312d9ef Fixes static row chart ignores custom series names in its legend (#62473)
* fix static row chart by reusing more visualizations code

* Update Loki Snapshots

* Update Loki Snapshots

* Revert "Update Loki Snapshots"

This reverts commit 0fc74e3e68.

* Revert "Update Loki Snapshots"

This reverts commit 438a00eaba.

* Update Loki Snapshots

---------

Co-authored-by: Metabase Automation <github-automation@metabase.com>
2025-08-22 17:30:31 -03:00
Braden Shepherdson
107dae72db [QP] Don't apply :coercion-strategy to joined fields twice (#62367)
Closes #62099

When a Field has a coercion strategy (say, `UnixSeconds->DateTime`) set in the `Table Metadata`,
and then that field is **joined**, it will get double-coerced. The first time in the inner query for the join,
the second at the top level `SELECT`.

Since after the first coercion it will be a `TIMESTAMP` instead of and `INTEGER`, the second coercion is a SQL error.

The solution is to add `:qp/ignore-coercion true` in the `resolve-joins` middleware, when the `:fields` of the outer
query are being populated with joined fields. That prevents the QP from re-applying type coercions and date truncations.
2025-08-22 15:43:54 -04:00
Aleksandr Lesnenko
acfc829c9e table viz should not collapse whitespaces (#62521)
* configurable white-space collapse in tables

* make it the new default

* snapshots
2025-08-22 15:11:22 -03:00
Alex Yarosh
ee8247ec03 docs: translations limitations (#62604)
* translations

* Apply suggestions from code review

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>

* markdown

---------

Co-authored-by: Jeff Bruemmer <jeff.bruemmer@gmail.com>
2025-08-22 18:05:48 +00:00
Aleksandr Lesnenko
b81fcbdfd5 skip flaky loki row chart tests (#62597) 2025-08-22 13:27:00 -03:00
Ryan Laurie
8b6e21c991 Flake Jail 🚓 (#62533)
* mark column click test flaky

* more flaky
2025-08-22 09:39:59 -06:00
appleby
109af9e274 Add user-recency scorer to the semantic search backend (#62474)
* Add user-recency scorer to the semantic search backend

* Only query the recent_views table for models it knows about

* Replace group-by with m/index-by in user-recency scorer

* Cleanup comments

* Improve prometheus metrics for user-recency and add tests

Permission filtering is already recorded in :metabase-search/permission-filtering-ms so no need for a new metric that
records it + collection filtering. Instead, add a new metric :metabase-search/semantic-collection-filter-ms so there
is no overlap.

Also remove embedding label from the collection filter and appdb scorer metrics, as these don't currently depend on
the embedding model in any meaningful way.

* Rename :metabase-search/permission-filtering-ms to :metabase-search/semantic-permission-filter-ms

To match the naming convention of other metrics exposed by the semantic search backend.
2025-08-22 08:35:50 -07:00
Alexander Polyankin
ff8e978614 Fix QB crashing for mongo (#62585) 2025-08-22 11:08:24 -04:00
1571 changed files with 47634 additions and 11291 deletions

View File

@@ -1,7 +1,7 @@
;; -*- comment-column: 100; -*-
{:config-paths ["macros" "src" "config"]
:linters
{ ;;
{;;
;; enabled optional linters (these are disabled by default)
;;
@@ -173,7 +173,6 @@
metabase.driver.sql-jdbc.execute/execute-prepared-statement!
metabase.notification.models/create-notification!
metabase.pulse.send/send-pulse!
metabase.query-processor.store/store-database!
;; Safe in tests, where we typically use a private, temporary index per thread.
metabase.search.core/reindex!
metabase.util/run-count!
@@ -187,7 +186,7 @@
:metabase/disallow-hardcoded-driver-names-in-tests
;; don't include `:h2` since that will probably lead to a mountain of tests where we are specifically testing
;; middleware or compilation behavior with just H2 since it's the default.
{:drivers #{ ;; core drivers
{:drivers #{;; core drivers
#_:h2
:postgres
:mysql
@@ -250,16 +249,15 @@
(taoensso.nippy/extend-freeze)
(taoensso.nippy/extend-thaw)]}
;; TODO (Cam 8/22/25) -- what's the point of marking stuff deprecated if we don't have Kondo enforce it? We should
;; remove all of these and add individual ignores as needed.
:deprecated-var
{:exclude
{metabase.cmd.core/dump {:namespaces ["metabase\\.cmd-test" "metabase-enterprise\\.serialization\\.cmd-test"]}
metabase.cmd.core/load {:namespaces ["metabase\\.cmd-test" "metabase-enterprise\\.serialization\\.cmd-test"]}
metabase.driver.sql-jdbc.execute.old-impl/set-timezone-sql {:namespaces ["metabase\\.driver.*"]}
metabase.driver.sql-jdbc.execute/set-time-zone-if-supported! {:namespaces ["metabase\\.driver.*"]}
metabase.driver/current-db-time {:namespaces ["metabase.*"]}
metabase.driver/supports? {:namespaces ["metabase.*"]}
metabase.query-processor.middleware.resolve-joins/maybe-resolve-source-table {:namespaces ["metabase.*"]}
metabase.query-processor.util/normalize-token {:namespaces ["metabase.*"]}}}
{metabase.driver.sql-jdbc.execute.old-impl/set-timezone-sql {:namespaces ["metabase\\.driver.*"]}
metabase.driver.sql-jdbc.execute/set-time-zone-if-supported! {:namespaces ["metabase\\.driver.*"]}
metabase.driver/current-db-time {:namespaces ["metabase.*"]}
metabase.driver/supports? {:namespaces ["metabase.*"]}
metabase.query-processor.util/normalize-token {:namespaces ["metabase.*"]}}}
:discouraged-var
{clojure.core/print {:message "Use metabase.util.log instead of clojure.core/print"}
@@ -302,6 +300,7 @@
:discouraged-namespace
{camel-snake-kebab.core {:message "CSK is not Turkish-safe, use the versions in metabase.util instead."}
cheshire.core {:message "Use metabase.util.json instead of cheshire.core directly."}
clj-time.core {:message "Use java-time.api or metabase.util.date-2 instead of clj-time"}
clojure.tools.logging {:message "Use metabase.util.log instead of clojure.tools.logging directly"}
grouper.core {:message "Use metabase.util.grouper instead of grouper.core"}
honeysql.core {:message "Use Honey SQL 2. Honey SQL 1 is removed as a dependency in Metabase 49+."}
@@ -419,6 +418,7 @@
metabase-enterprise.transforms.api-test/with-transform-tags clojure.core/let
metabase-enterprise.transforms.api-test/with-worker-runs clojure.core/let
metabase-enterprise.transforms.test-util/with-transform-cleanup! clojure.core/let
metabase-enterprise.transforms.execute/with-transform-lifecycle clojure.core/let
metabase.actions.test-util/with-actions clojure.core/let
metabase.api.common/let-404 clojure.core/let
metabase.app-db.custom-migrations.util/with-temp-scheduler! clojure.core/fn
@@ -735,7 +735,9 @@
;; `metabase-enterprise.sandbox.query-processor*-test`
;;
{:pattern "^metabase(?:((?:-enterprise\\.sandbox)?\\.query-processor)|(?:\\.driver\\.sql(?!server)(?!ite))).*-test$"
:name general-qp-and-driver-test-namespaces}]
:name general-qp-and-driver-test-namespaces}
{:pattern "^metabase\\.python-runner\\..*"
:name python-runner-namespaces}]
:config-in-ns
{test-namespaces

View File

@@ -303,6 +303,7 @@
models
premium-features
settings
store-api
task
util}}
@@ -515,6 +516,7 @@
public-sharing
queries
query-processor
server
settings
tiles
util}}
@@ -716,6 +718,7 @@
metabase.native-query-snippets.core}
:uses #{api
collections
lib
models
permissions
premium-features
@@ -884,6 +887,19 @@
enterprise/advanced-permissions
enterprise/sandbox}}
python-runner
{:team "Workflows"
:api #{metabase.python-runner.api
metabase.python-runner.core
metabase.python-runner.init}
:uses #{api
driver
models
query-processor
request
util
enterprise/transforms}}
queries
{:team "Querying"
:api #{metabase.queries.api
@@ -1096,6 +1112,7 @@
:api #{metabase.server.core
metabase.server.init
metabase.server.middleware.session
metabase.server.settings
metabase.server.streaming-response} ; TODO -- too many API namespaces
:uses #{analytics
api
@@ -1190,6 +1207,14 @@
:api #{metabase.startup.core}
:uses #{util}}
store-api
{:team "Cloud"
:api #{metabase.store-api.core
metabase.store-api.init}
:uses #{config
settings
util}}
sync
{:team "Querying"
:api #{metabase.sync.api
@@ -1557,6 +1582,7 @@
app-db
audit-app
classloader
config
driver
lib
models
@@ -1592,6 +1618,15 @@
task
util}}
enterprise/cloud-add-ons
{:team "Cloud"
:api #{metabase-enterprise.cloud-add-ons.api}
:uses #{api
events
premium-features
util
enterprise/harbormaster}}
enterprise/content-translation
{:team "UX West"
:api #{metabase-enterprise.content-translation.dictionary
@@ -1635,6 +1670,7 @@
metabase-enterprise.database-replication.init}
:uses #{analytics
api
driver
premium-features
settings
util
@@ -1704,7 +1740,7 @@
{:team "Cloud"
:api #{metabase-enterprise.harbormaster.client}
:uses #{api
cloud-migration
store-api
util}}
enterprise/impersonation
@@ -1838,8 +1874,10 @@
:api #{metabase-enterprise.semantic-search.api
metabase-enterprise.semantic-search.core
metabase-enterprise.semantic-search.init}
:uses #{analytics
:uses #{activity-feed
analytics
api
app-db
config
connection-pool
models
@@ -1923,8 +1961,11 @@
{:team "Querying"
:api #{metabase-enterprise.transforms.api
metabase-enterprise.transforms.core
metabase-enterprise.transforms.init}
:uses #{api
metabase-enterprise.transforms.init
;; TODO: Remove this from API once we remove the python-runner callback to metabase
metabase-enterprise.transforms.settings}
:uses #{analytics
api
app-db
config
driver
@@ -1940,6 +1981,8 @@
sync
task
task-history
;; TODO: Remove this once we're using a better file format than CSV
upload
util}}
enterprise/upload-management

View File

@@ -14,6 +14,7 @@ if (shouldLintCssModules) {
}
module.exports = {
ignorePatterns: ["!.storybook"],
rules: {
strict: [2, "never"],
"no-undef": 2,
@@ -179,6 +180,7 @@ module.exports = {
{
files: ["*.js", "*.jsx", "*.ts", "*.tsx"],
rules: {
"jtag-missing-key": "error",
"no-unconditional-metabase-links-render": "error",
"no-color-literals": "error",
"no-literal-metabase-strings": "error",
@@ -203,6 +205,7 @@ module.exports = {
"enterprise/frontend/src/metabase-enterprise/whitelabel/**/*",
"frontend/lint/**/*",
"*.stories.*",
"**/.storybook/*",
"stories-data.*",
"e2e/**/*",
"**/tests/*",

2
.github/CODEOWNERS vendored
View File

@@ -1,7 +1,9 @@
# Before changing this file, make sure you have read how we use it:
# https://www.notion.so/metabase/Pull-Request-Code-Review-Guide-374f05df889748b69d67af753f9bc9b8?pvs=4#36550c04ceab40b5a8b8bee6264b090c
enterprise/frontend/src/embedding-sdk-package @metabase/embedding
enterprise/frontend/src/embedding-sdk-bundle @metabase/embedding
enterprise/frontend/src/embedding-sdk-shared @metabase/embedding
frontend/src/metabase/embedding-sdk @metabase/embedding
frontend/src/metabase/public/containers/PublicOrEmbeddedQuestion @metabase/embedding
frontend/src/metabase/public/containers/PublicOrEmbeddedDashboard @metabase/embedding

View File

@@ -11,6 +11,18 @@ runs:
- name: Wait for port ${{ inputs.port }} to be ready
shell: bash
run: |
echo "Waiting for port ${{ inputs.port }} to be ready..."
timeout=300 # 5 minutes timeout
elapsed=0
while ! nc -z localhost ${{ inputs.port }}; do
sleep 0.1;
if [ $elapsed -ge $timeout ]; then
echo "❌ Timeout waiting for port ${{ inputs.port }} after ${timeout} seconds"
exit 1
fi
sleep 1
elapsed=$((elapsed + 1))
if [ $((elapsed % 10)) -eq 0 ]; then
echo " Still waiting for port ${{ inputs.port }}... ($elapsed seconds)"
fi
done
echo "✅ Port ${{ inputs.port }} is ready!"

View File

@@ -1,4 +1,7 @@
name: Prepare back-end environment
description: |
Prepare the backend. Installs jdk, Clojure, and fetches the cache for m2. The CI config fetchs `ci-test-config.json`
from master and lets us ignore tests at the var level if they are flaking.
inputs:
java-version:
required: true
@@ -21,9 +24,14 @@ runs:
distribution: 'temurin'
- name: Install Clojure CLI
shell: bash
continue-on-error: true
run: |
curl -O https://download.clojure.org/install/linux-install-${{ inputs.clojure-version }}.sh &&
sudo bash ./linux-install-${{ inputs.clojure-version }}.sh
- name: Fetch CI config
shell: bash
run: |
curl -o ci-test-config.json https://raw.githubusercontent.com/metabase/metabase/refs/heads/master/ci-test-config.json
- name: Check to see if dependencies should be cached
if: ${{ contains(github.event.head_commit.message, '[ci nocache]') }}
run: echo "Commit message includes [ci nocache]; dependencies will NOT be cached"

View File

@@ -40,7 +40,7 @@ runs:
list-tests: failed
fail-on-error: false
- name: Upload Logs on Failure
if: failure()
if: always() && !success()
uses: actions/upload-artifact@v4
with:
name: test-logs-${{ github.job }}

84
.github/scripts/get-issue-data.js vendored Normal file
View File

@@ -0,0 +1,84 @@
const githubSlackMap = require("../../release/github-slack-map.json");
async function getIssueData({ context, github, manualIssueNumber }) {
let issueNumber;
let issueData;
let prReviews = [];
const triggerType = context.eventName;
if (context.eventName === "issues") {
issueNumber = context.payload.issue.number;
issueData = context.payload.issue;
} else if (context.eventName === "workflow_dispatch") {
issueNumber = parseInt(manualIssueNumber);
const { data } = await github.rest.issues.get({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issueNumber,
});
issueData = data;
} else if (context.eventName === "pull_request_review") {
const prNumber = context.payload.pull_request.number;
const { data: prData } = await github.rest.pulls.get({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: prNumber,
});
// Extract issue number from branch name (e.g., "claude-fix/issue-12345-some-title")
const branchMatch = prData.head.ref.match(/claude-fix\/issue-(\d+)/);
if (!branchMatch) {
throw new Error(
`Could not extract issue number from branch name: ${prData.head.ref}`,
);
}
issueNumber = parseInt(branchMatch[1]);
const { data } = await github.rest.issues.get({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issueNumber,
});
issueData = data;
const { data: reviews } = await github.rest.pulls.listReviews({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: prNumber,
});
prReviews = reviews.filter(
(review) =>
review.state === "CHANGES_REQUESTED" &&
isMetabaseMember(review.user.login),
);
}
const { data: comments } = await github.rest.issues.listComments({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issueNumber,
});
const employeeComments = comments.filter((comment) =>
isMetabaseMember(comment.user.login),
);
return {
issueNumber,
issueData,
employeeComments,
prReviews,
triggerType,
isIssueAuthorEmployee: isMetabaseMember(issueData.user.login),
};
}
function isMetabaseMember(username) {
return username in githubSlackMap;
}
module.exports = {
getIssueData,
};

View File

@@ -154,7 +154,7 @@ jobs:
fail-on-error: false
- name: Upload Logs on Failure
if: failure()
if: always() && !success()
uses: actions/upload-artifact@v4
with:
name: test-logs-${{ matrix.java-version }}-${{ matrix.job.edition }}-${{ github.job }}
@@ -195,6 +195,7 @@ jobs:
- name: Run cljfmt
run: ./bin/mage cljfmt-all --force-check
be-tests-result:
needs:
- be-linter-eastwood

View File

@@ -0,0 +1,14 @@
name: Block Master Branch PRs
on:
pull_request:
types: [opened, synchronize]
jobs:
check-source-branch:
runs-on: ubuntu-latest
steps:
- name: Block master branch PRs
if: github.head_ref == 'master'
run: |
echo "PRs from `master` branches are not allowed, please use a new branch name for your PR."
exit 1

View File

@@ -4,97 +4,22 @@ on:
issues:
types:
- labeled
pull_request_review:
types:
- submitted
workflow_dispatch:
inputs:
issue_number:
description: "Issue number to fix"
required: true
type: string
override_employee_check:
description: "Override employee check for issue creator"
required: false
default: false
type: boolean
jobs:
check-employee-and-issue:
runs-on: ubuntu-latest
timeout-minutes: 2
permissions:
contents: read
issues: read
if: |
(github.event_name == 'issues' && github.event.label.name == 'Claude Bug Fix' && github.event.issue.state == 'open') ||
(github.event_name == 'workflow_dispatch')
outputs:
is_employee: ${{ steps.check_employee.outputs.is_employee }}
issue_number: ${{ steps.get_issue.outputs.issue_number }}
issue_data: ${{ steps.get_issue.outputs.issue_data }}
steps:
- name: Generate GitHub App Token
uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ secrets.METABASE_BOT_APP_ID }}
private-key: ${{ secrets.METABASE_BOT_APP_PRIVATE_KEY }}
- name: Get issue data
id: get_issue
uses: actions/github-script@v7
with:
script: |
let issueNumber, issueData;
if (context.eventName === 'issues') {
// Original issue label event
issueNumber = context.payload.issue.number;
issueData = context.payload.issue;
} else if (context.eventName === 'workflow_dispatch') {
// Manual trigger with issue number input
issueNumber = parseInt('${{ github.event.inputs.issue_number }}');
const { data } = await github.rest.issues.get({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issueNumber
});
issueData = data;
}
core.setOutput('issue_number', issueNumber);
core.setOutput('issue_data', JSON.stringify(issueData));
console.log(`Issue #${issueNumber}: ${issueData.title}`);
console.log(`Issue author: ${issueData.user.login}`);
- name: Check if issue creator is a Metabase employee
id: check_employee
uses: actions/github-script@v7
env:
ISSUE_DATA: ${{ steps.get_issue.outputs.issue_data }}
with:
github-token: ${{ steps.app-token.outputs.token }}
script: |
const issueData = JSON.parse(process.env.ISSUE_DATA);
const issueAuthor = issueData.user.login;
try {
// Check if user is a member of the metabase organization (including private members)
const { data: membership } = await github.rest.orgs.getMembershipForUser({
org: 'metabase',
username: issueAuthor
});
if (membership.state === 'active') {
console.log(`User ${issueAuthor} is an active member of the Metabase organization. Proceeding with bug fix automation.`);
core.setOutput('is_employee', 'true');
} else {
console.log(`User ${issueAuthor} is not an active member of the Metabase organization. Skipping bug fix automation.`);
core.setOutput('is_employee', 'false');
}
} catch (error) {
if (error.status === 404) {
console.log(`User ${issueAuthor} is not a member of the Metabase organization. Skipping bug fix automation.`);
} else {
console.error('Error checking organization membership:', error);
}
core.setOutput('is_employee', 'false');
}
auto-fix-bug:
runs-on: ubuntu-latest
timeout-minutes: 30
@@ -103,8 +28,10 @@ jobs:
issues: write
pull-requests: write
id-token: write
needs: check-employee-and-issue
if: needs.check-employee-and-issue.outputs.is_employee == 'true'
if: |
(github.event_name == 'issues' && github.event.label.name == 'Claude Bug Fix' && github.event.issue.state == 'open') ||
(github.event_name == 'workflow_dispatch') ||
(github.event_name == 'pull_request_review' && github.event.review.state == 'changes_requested' && startsWith(github.event.pull_request.head.ref, 'claude-fix/'))
steps:
- name: Checkout repository
uses: actions/checkout@v4
@@ -112,67 +39,95 @@ jobs:
fetch-depth: 0
token: ${{ secrets.GITHUB_TOKEN }}
- name: Get issue data and check employee status
id: get_issue
uses: actions/github-script@v7
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const { getIssueData } = require('${{ github.workspace }}/.github/scripts/get-issue-data.js');
try {
const result = await getIssueData({
context,
github,
manualIssueNumber: '${{ github.event.inputs.issue_number }}'
});
const { issueNumber, issueData, employeeComments, prReviews, triggerType, isIssueAuthorEmployee } = result;
// Check employee status and fail if not authorized
if (!result.isIssueAuthorEmployee && '${{ github.event.inputs.override_employee_check }}' !== 'true') {
core.setFailed(`User ${result.issueData.user.login} is not a Metabase employee. Skipping bug fix automation.`);
}
core.setOutput('issue_number', issueNumber);
core.setOutput('issue_data', JSON.stringify(issueData));
core.setOutput('issue_comments', JSON.stringify(employeeComments));
core.setOutput('pr_reviews', JSON.stringify(prReviews));
core.setOutput('trigger_type', triggerType);
} catch (error) {
core.setFailed(error.message);
}
- name: Set up git configuration
run: |
git config --global user.name "Claude Code[bot]"
git config --global user.email "noreply@anthropic.com"
- name: Prepare dynamic issue info
id: prepare_issue_info
- name: Prepare issue context and bug fix prompt
id: prepare_prompt
uses: actions/github-script@v7
env:
ISSUE_DATA: ${{ needs.check-employee-and-issue.outputs.issue_data }}
ISSUE_DATA: ${{ steps.get_issue.outputs.issue_data }}
ISSUE_COMMENTS: ${{ steps.get_issue.outputs.issue_comments }}
PR_REVIEWS: ${{ steps.get_issue.outputs.pr_reviews }}
TRIGGER_TYPE: ${{ steps.get_issue.outputs.trigger_type }}
with:
script: |
const issueData = JSON.parse(process.env.ISSUE_DATA);
const issueNumber = '${{ needs.check-employee-and-issue.outputs.issue_number }}';
const issueComments = JSON.parse(process.env.ISSUE_COMMENTS);
const prReviews = JSON.parse(process.env.PR_REVIEWS);
const triggerType = process.env.TRIGGER_TYPE;
const issueNumber = '${{ steps.get_issue.outputs.issue_number }}';
// Convert issue title to kebab case
// Convert issue title to kebab case and create branch name
const issueTitle = issueData.title || 'untitled';
const kebabTitle = issueTitle
.toLowerCase()
.replace(/[^a-z0-9]+/g, '-')
.replace(/^-+|-+$/g, '')
.replace(/-+/g, '-')
.substring(0, 50); // Limit length
.substring(0, 50);
const branchName = `claude-fix/issue-${issueNumber}-${kebabTitle}`;
// Create base branch name
const baseBranchName = `claude-fix/issue-${issueNumber}-${kebabTitle}`;
core.exportVariable('BASE_BRANCH_NAME', baseBranchName);
// Format data for bash environment
const formattedComments = issueComments.length > 0
? issueComments.map(comment =>
`**Comment by @${comment.user.login} on ${comment.created_at}:**\n${comment.body}`
).join('\n\n---\n\n')
: '';
const formattedReviews = prReviews.length > 0
? prReviews.map(review =>
`**Review by @${review.user.login} on ${review.submitted_at} (Changes Requested):**\n${review.body || 'No review comment provided'}`
).join('\n\n---\n\n')
: '';
// Export issue info for the prompt
core.exportVariable('BRANCH_NAME', branchName);
core.exportVariable('ISSUE_NUMBER', issueNumber);
core.exportVariable('ISSUE_TITLE', issueData.title);
core.exportVariable('ISSUE_AUTHOR', issueData.user.login);
core.exportVariable('ISSUE_CREATED', issueData.created_at);
core.exportVariable('ISSUE_BODY', issueData.body || 'No description provided');
core.exportVariable('ISSUE_COMMENTS_FORMATTED', formattedComments);
core.exportVariable('PR_REVIEWS_FORMATTED', formattedReviews);
core.exportVariable('TRIGGER_TYPE', triggerType);
- name: Determine branch strategy
- name: Generate bug fix prompt
run: |
# Use the base branch name (no counters)
BRANCH_NAME="${{ env.BASE_BRANCH_NAME }}"
# Check if this exact branch already exists
if git branch -r --list "origin/${BRANCH_NAME}" | grep -q .; then
echo "Branch already exists: $BRANCH_NAME"
echo "Will push to existing branch and skip PR creation"
echo "BRANCH_EXISTS=true" >> $GITHUB_ENV
else
echo "Creating new branch: $BRANCH_NAME"
echo "Will create new PR"
echo "BRANCH_EXISTS=false" >> $GITHUB_ENV
fi
# Export the branch name
echo "BRANCH_NAME=$BRANCH_NAME" >> $GITHUB_ENV
- name: Prepare bug fix prompt
id: prepare_prompt
run: |
# Prepare the prompt for Claude
cat << 'EOF' >> $GITHUB_ENV
BUG_FIX_PROMPT<<PROMPT_END
You are helping to automatically fix a bug reported in GitHub issue #${{ env.ISSUE_NUMBER }}.
You are helping to fix a bug reported in GitHub issue #${{ env.ISSUE_NUMBER }}.
## Bug Report Details
**Title:** ${{ env.ISSUE_TITLE }}
@@ -182,8 +137,27 @@ jobs:
**Description:**
${{ env.ISSUE_BODY }}
**Comments:**
${{ env.ISSUE_COMMENTS_FORMATTED }}
EOF
# Add review feedback section only if this is a review trigger
if [ "${{ env.TRIGGER_TYPE }}" = "pull_request_review" ]; then
cat << 'EOF' >> $GITHUB_ENV
## Previous Fix Attempt - Review Feedback (MUST ADDRESS)
Your previous automated fix attempt received the following feedback that needs to be addressed:
${{ env.PR_REVIEWS_FORMATTED }}
EOF
fi
# Add the rest of the prompt (always the same)
cat << 'EOF' >> $GITHUB_ENV
## Instructions
1. **Analyze the bug report** - Understand what the issue is describing
1. **Analyze the issue description and comments** - Understand what the issue is describing
a. Pay particular attention to reproduction steps and if there's an agreed upon fix.
2. **Search the codebase** - Use Grep and Glob tools to find relevant files
3. **Implement a fix** - Follow existing code patterns and conventions
4. **Test the fix** - Run appropriate tests using the commands in CLAUDE.md:
@@ -205,15 +179,26 @@ jobs:
- Only modify actual production code in the main repository directories
- The scratchpad will be cleaned up automatically - nothing from it will be committed
## If You Cannot Fix The Bug
If you determine that you cannot create a definitive fix, create a file called `FAILED_FIX_ANALYSIS.md` with:
1. **Why No Fix** - Specific reason why you couldn't implement a fix
2. **Tool Limitations** - If you needed additional tools/access that weren't available
Start by understanding the bug and then systematically work toward a solution.
PROMPT_END
EOF
- name: Determine branch strategy
run: |
BRANCH_NAME="${{ env.BRANCH_NAME }}"
if git branch -r --list "origin/${BRANCH_NAME}" | grep -q .; then
echo "Branch already exists: $BRANCH_NAME"
echo "Will push to existing branch and skip PR creation"
echo "BRANCH_EXISTS=true" >> $GITHUB_ENV
else
echo "Creating new branch: $BRANCH_NAME"
echo "Will create new PR"
echo "BRANCH_EXISTS=false" >> $GITHUB_ENV
fi
# Export the branch name
echo "BRANCH_NAME=$BRANCH_NAME" >> $GITHUB_ENV
- name: Create scratchpad directory for Claude
run: |
# Create a scratchpad directory for Claude to use for temporary files
@@ -249,20 +234,6 @@ jobs:
- name: Check for changes and analysis
id: check_changes
run: |
# Check if Claude created an analysis file first and store its content
if [ -f "FAILED_FIX_ANALYSIS.md" ]; then
echo "has_analysis=true" >> $GITHUB_OUTPUT
echo "Analysis file found"
# Store analysis content in a GitHub output (base64 encoded to handle multiline)
ANALYSIS_CONTENT=$(base64 -w 0 FAILED_FIX_ANALYSIS.md)
echo "analysis_content=$ANALYSIS_CONTENT" >> $GITHUB_OUTPUT
# Remove analysis file so it doesn't count as a code change
rm -f FAILED_FIX_ANALYSIS.md
else
echo "has_analysis=false" >> $GITHUB_OUTPUT
echo "No analysis file found"
fi
# Now check for actual code changes (excluding analysis file)
if [ -n "$(git status --porcelain)" ]; then
echo "has_changes=true" >> $GITHUB_OUTPUT
@@ -278,25 +249,16 @@ jobs:
id: prepare_reviewers
uses: actions/github-script@v7
env:
ISSUE_DATA: ${{ needs.check-employee-and-issue.outputs.issue_data }}
ISSUE_DATA: ${{ steps.get_issue.outputs.issue_data }}
with:
script: |
// Get existing team labels from the issue
const issueData = JSON.parse(process.env.ISSUE_DATA);
const issueLabels = issueData.labels.map(label => label.name);
const teamLabels = issueLabels.filter(label => label.startsWith('.Team/'));
console.log('Issue labels:', issueLabels);
console.log('Team labels found:', teamLabels);
// Add issue creator as reviewer
const issueCreator = issueData.user.login;
core.setOutput('team_labels', teamLabels.join(','));
core.setOutput('reviewers', issueCreator);
console.log('Reviewer:', issueCreator);
- name: Create Pull Request
if: steps.check_changes.outputs.has_changes == 'true'
uses: peter-evans/create-pull-request@v6
@@ -363,25 +325,3 @@ jobs:
with:
script: |
console.log('🤖 No code changes were made by Claude.');
// Check if Claude provided a detailed analysis
if ('${{ steps.check_changes.outputs.has_analysis }}' === 'true') {
try {
// Decode the base64-encoded analysis content
const analysisBase64 = '${{ steps.check_changes.outputs.analysis_content }}';
const analysisContent = Buffer.from(analysisBase64, 'base64').toString('utf8');
console.log('📋 Claude provided detailed analysis:');
console.log('='.repeat(50));
console.log(analysisContent);
console.log('='.repeat(50));
} catch (error) {
console.log('❌ Could not decode analysis content:', error);
}
} else {
console.log('ℹ️ No detailed analysis file was created by Claude.');
console.log('This could be because:');
console.log('- The issue requires more context or clarification');
console.log('- The fix is complex and requires human judgment');
console.log('- The issue is not a straightforward code bug');
console.log('- Claude couldn\'t locate the relevant code to modify');
}

36
.github/workflows/docs-links.yml vendored Normal file
View File

@@ -0,0 +1,36 @@
name: Check doc links
on:
pull_request:
paths:
- "docs/**"
workflow_dispatch:
jobs:
link-checker:
name: Check documentation links
runs-on: ubuntu-latest
timeout-minutes: 5
permissions:
contents: read
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
sparse-checkout: |
docs
.lychee
- name: Cache lychee
uses: actions/cache@v3
with:
path: ~/.cache/lychee
key: lychee-${{ runner.os }}-${{ hashFiles('.lychee/config.toml') }}
- name: Run link checker
id: link-check
uses: lycheeverse/lychee-action@v2
with:
fail: true
args: docs --config ./.lychee/config.toml --offline
format: markdown

View File

@@ -44,7 +44,7 @@ jobs:
echo "A relevant team label is present. Tier 3 driver tests will run."
else
echo "Checking for changes in relevant folders..."
CHANGED_FILES=$(git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.sha }})
CHANGED_FILES=$(git diff --name-only $(git merge-base ${{ github.event.pull_request.base.sha }} ${{ github.sha }}) ${{ github.sha }})
# Initialize an empty array to store folders with changes
CHANGED_FOLDERS=()
@@ -338,6 +338,12 @@ jobs:
name: H2
steps:
- uses: actions/checkout@v4
with:
submodules: true
token: ${{ secrets.METABASE_AUTOMATION_USER_TOKEN }}
- name: Start python-runner
working-directory: python-runner
run: make run-all
- name: Test H2 driver
uses: ./.github/actions/test-driver
with:
@@ -442,6 +448,12 @@ jobs:
name: "${{ matrix.version.name }} ${{ matrix.job.name }}"
steps:
- uses: actions/checkout@v4
with:
submodules: true
token: ${{ secrets.METABASE_AUTOMATION_USER_TOKEN }}
- name: Start python-runner
working-directory: python-runner
run: make run-all
- name: Test ${{ matrix.version.name }}
uses: ./.github/actions/test-driver
with:
@@ -745,6 +757,12 @@ jobs:
POSTGRES_HOST_AUTH_METHOD: trust
steps:
- uses: actions/checkout@v4
with:
submodules: true
token: ${{ secrets.METABASE_AUTOMATION_USER_TOKEN }}
- name: Start python-runner
working-directory: python-runner
run: make run-all
- name: Test ${{ matrix.version.name }} (${{ matrix.job.name }})
uses: ./.github/actions/test-driver
with:
@@ -1040,43 +1058,44 @@ jobs:
aws-region: ${{ vars.AWS_REGION }}
trunk-api-token: ${{ secrets.TRUNK_API_TOKEN }}
be-tests-starburst-ee:
needs: determine-driver-skips
if: ${{ !inputs.skip && !(needs.determine-driver-skips.outputs.skip == 'true') }}
runs-on: ubuntu-22.04
timeout-minutes: 60
env:
CI: 'true'
DRIVERS: starburst
services:
starburst:
image: trinodb/trino:latest
env:
CATALOG_MANAGEMENT: dynamic
ports:
- "8080:8080"
name: Starburst
steps:
- uses: actions/checkout@v4
- name: Make plugins directory
run: mkdir plugins
- name: Test Starburst driver
uses: ./.github/actions/test-driver
with:
junit-name: 'be-tests-starburst-ee'
test-args: >-
:only-tags [:mb/driver-tests]
- name: Upload Test Results
uses: ./.github/actions/upload-test-results
if: always()
with:
input-path: ./target/junit/
output-name: ${{ github.job }}
bucket: ${{ vars.AWS_S3_TEST_RESULTS_BUCKET }}
aws-access-key-id: ${{ secrets.AWS_TEST_RESULTS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_TEST_RESULTS_SECRET_ACCESS_KEY }}
aws-region: ${{ vars.AWS_REGION }}
trunk-api-token: ${{ secrets.TRUNK_API_TOKEN }}
# TODO(dpsutton, 2025-08-20): Re-enable starburst when we figure out why it randomly dies in CI
# be-tests-starburst-ee:
# needs: determine-driver-skips
# if: ${{ !inputs.skip && !(needs.determine-driver-skips.outputs.skip == 'true') }}
# runs-on: ubuntu-22.04
# timeout-minutes: 60
# env:
# CI: 'true'
# DRIVERS: starburst
# services:
# starburst:
# image: trinodb/trino:latest
# env:
# CATALOG_MANAGEMENT: dynamic
# ports:
# - "8080:8080"
# name: Starburst
# steps:
# - uses: actions/checkout@v4
# - name: Make plugins directory
# run: mkdir plugins
# - name: Test Starburst driver
# uses: ./.github/actions/test-driver
# with:
# junit-name: 'be-tests-starburst-ee'
# test-args: >-
# :only-tags [:mb/driver-tests]
# - name: Upload Test Results
# uses: ./.github/actions/upload-test-results
# if: always()
# with:
# input-path: ./target/junit/
# output-name: ${{ github.job }}
# bucket: ${{ vars.AWS_S3_TEST_RESULTS_BUCKET }}
# aws-access-key-id: ${{ secrets.AWS_TEST_RESULTS_ACCESS_KEY_ID }}
# aws-secret-access-key: ${{ secrets.AWS_TEST_RESULTS_SECRET_ACCESS_KEY }}
# aws-region: ${{ vars.AWS_REGION }}
# trunk-api-token: ${{ secrets.TRUNK_API_TOKEN }}
# TODO(rileythomp, 2025-08-20): Re-enable vertica tests once the docker image is updated
# be-tests-vertica-ee:
@@ -1136,7 +1155,7 @@ jobs:
- be-tests-sparksql-ee
- be-tests-sqlite-ee
- be-tests-sqlserver
- be-tests-starburst-ee
# - be-tests-starburst-ee
# TODO(rileythomp, 2025-08-20): Re-enable vertica tests once the docker image is updated
# - be-tests-vertica-ee
- be-tests-clickhouse-ee

View File

@@ -192,7 +192,7 @@ jobs:
# - starts it
# - runs its Cypress tests against the local metabase.jar and local @metabase/embedding-sdk-react package.
# The job is not required, though if it's failing better to be sure that it's not caused by a breaking change.
# For more details see `Sample Apps compatibility with Embedding SDK tests` in `enterprise/frontend/src/embedding-sdk-bundle/dev.md`
# For more details see `Sample Apps compatibility with Embedding SDK tests` in `enterprise/frontend/src/embedding-sdk-package/dev.md`
e2e-sample-apps-tests:
needs: [get-build-requirements, get-sample-apps-data, build]
strategy:
@@ -316,7 +316,7 @@ jobs:
# - starts an app
# - runs its Cypress tests against the e2e test metabase instance and local @metabase/embedding-sdk-react package.
# The job is not required, though if it's failing better to be sure that it's not caused by a breaking change.
# For more details see `Embedding SDK integration tests with Host Apps` in `enterprise/frontend/src/embedding-sdk-bundle/dev.md`
# For more details see `Embedding SDK integration tests with Host Apps` in `enterprise/frontend/src/embedding-sdk-package/dev.md`
e2e-host-apps-tests:
needs: [get-build-requirements, build]
strategy:

View File

@@ -137,7 +137,7 @@ jobs:
if: ${{ steps.docs-generation.outcome == 'failure' }}
run: exit 1
# See `Component e2e tests` in `enterprise/frontend/src/embedding-sdk-bundle/dev.md`
# See `Component e2e tests` in `enterprise/frontend/src/embedding-sdk-package/dev.md`
sdk-e2e-tests:
name: "SDK e2e tests"
uses: ./.github/workflows/e2e-component-tests-embedding-sdk.yml
@@ -160,7 +160,7 @@ jobs:
- embedding-sdk-docs-snippets-type-check
- embedding-sdk-api-documentation-generation-validation
- sdk-e2e-tests
# - e2e-component-tests-embedding-sdk-backward-compatibility
- e2e-component-tests-embedding-sdk-backward-compatibility
if: always() && !cancelled()
runs-on: ubuntu-latest
timeout-minutes: 5

View File

@@ -52,6 +52,8 @@ jobs:
run: yarn run lint-prettier-pure
- name: Run ESLint linter
run: yarn run lint-eslint-pure
- name: Run CSS linter
run: yarn run lint-css
fe-type-check:
if: ${{ !inputs.skip }}

View File

@@ -1,32 +0,0 @@
name: Links
on:
repository_dispatch:
workflow_dispatch:
schedule:
- cron: "0 0 * * 0"
jobs:
linkChecker:
runs-on: ubuntu-latest
permissions:
issues: write # required for peter-evans/create-issue-from-file
steps:
- uses: actions/checkout@v4
- name: Link Checker
id: lychee
uses: lycheeverse/lychee-action@v2
with:
fail: false
args: docs --include-fragments --config ./.lychee/config.toml --verbose --no-progress
format: markdown
- name: Create Issue From File
if: steps.lychee.outputs.exit_code != 0
uses: peter-evans/create-issue-from-file@v5
with:
title: Link Checker Report
content-filepath: ./.lychee/out.md
labels: "Type:Documentation"
assignees: jeff-bruemmer

View File

@@ -5,19 +5,12 @@ on:
workflow_dispatch:
inputs:
branch:
description: "Branch we want to release the SDK from"
description: "Branch we want to release the SDK from (to release from other branches use the workflow from those branches)"
type: choice
required: true
default: "master"
options:
- master
- release-x.51.x
- release-x.52.x
- release-x.53.x
- release-x.54.x
- release-x.55.x
- release-x.56.x
- esbuild-main
concurrency:
# We want to ensure only one job is running at a time per branch because
@@ -178,41 +171,39 @@ jobs:
outputs:
sdk_version: ${{ fromJson(steps.new-sdk-version.outputs.result).version }}
major_version: ${{ fromJson(steps.new-sdk-version.outputs.result).majorVersion }}
pre_release_label: ${{ fromJson(steps.new-sdk-version.outputs.result).preReleaseLabel }}
steps:
- name: Check out the code using the provided branch
uses: actions/checkout@v4
with:
ref: ${{ inputs.branch }}
- name: Prepare build scripts
run: yarn --cwd release --frozen-lockfile && yarn --cwd release build
- name: Get current SDK version
id: current-sdk-version
run: |
VERSION=$(jq -r .version ./enterprise/frontend/src/embedding-sdk-bundle/package.template.json)
VERSION=$(jq -r .version ./enterprise/frontend/src/embedding-sdk-package/package.template.json)
echo "sdk_current_version=$VERSION" >> $GITHUB_OUTPUT
- name: Get next SDK patch version
- name: Get next SDK patch or pre-release version
id: new-sdk-version
uses: actions/github-script@v7
with:
script: |
const currentVersion = "${{ steps.current-sdk-version.outputs.sdk_current_version }}";
const [currentVersionWithoutSuffix, suffix] = currentVersion.split("-");
const versionParts = currentVersionWithoutSuffix.split(".");
versionParts[versionParts.length - 1] = parseInt(versionParts.at(-1)) + 1;
const newVersion = versionParts.join(".");
const [_, majorVersion] = versionParts
script: | #js
const { getNextSdkVersion } = require('${{ github.workspace }}/release/dist/index.cjs');
if (!suffix) {
return {
version: newVersion,
majorVersion
};
}
const branch = "${{ inputs.branch }}";
const currentVersion = "${{ steps.current-sdk-version.outputs.sdk_current_version }}";
const result = getNextSdkVersion(branch, currentVersion);
return {
version: `${newVersion}-${suffix}`,
majorVersion
}
version: result.version,
preReleaseLabel: result.preReleaseLabel,
majorVersion: result.majorVersion
};
- name: Append workflow summary
run: |
@@ -336,6 +327,7 @@ jobs:
git config --global user.name "Metabase Automation"
- name: Update readme
if: inputs.branch != 'master'
run: |
bash ./bin/embedding-sdk/release_utils.bash update_readme ${{ env.sdk_version }}
@@ -344,11 +336,13 @@ jobs:
bash ./bin/embedding-sdk/release_utils.bash update_package_json_template ${{ env.sdk_version }}
- name: Retrieve SDK changelog diff
if: inputs.branch != 'master'
uses: actions/download-artifact@v4
with:
name: sdk-changelog-diff
- name: Update changelog
if: inputs.branch != 'master'
run: |
cat changelog-diff enterprise/frontend/src/embedding-sdk-bundle/CHANGELOG.md > new-changelog
mv new-changelog enterprise/frontend/src/embedding-sdk-bundle/CHANGELOG.md
@@ -356,12 +350,23 @@ jobs:
- name: Create a PR updating readme + published version, and changelog (using GitHub Metabase Automation account)
run: |
git checkout -b update-sdk-version-${{ env.sdk_version }}
git commit -a -m 'Update Readme version references and published npm version to ${{ env.sdk_version }}'
if [ "${{ inputs.branch }}" = "master" ]; then
COMMIT_MSG="chore(sdk): Update published npm version to ${{ env.sdk_version }}"
PR_TITLE="chore(sdk): Update SDK version to ${{ env.sdk_version }}"
PR_BODY="Update published npm package version to ${{ env.sdk_version }}"
else
COMMIT_MSG="docs(sdk): Update Readme version references and published npm version to ${{ env.sdk_version }}"
PR_TITLE="docs(sdk): Update SDK version to ${{ env.sdk_version }}"
PR_BODY="Update Readme version references and published npm package version to ${{ env.sdk_version }}"
fi
git commit -a -m "$COMMIT_MSG"
git push origin HEAD
gh pr create --base ${{ inputs.branch }}\
--assignee "${GITHUB_ACTOR}"\
--title "docs(sdk): Update SDK version to ${{ env.sdk_version }}"\
--body "Update Readme version references and published npm package version to ${{ env.sdk_version }}"
gh pr create --base "${{ inputs.branch }}" \
--assignee "${GITHUB_ACTOR}" \
--title "$PR_TITLE" \
--body "$PR_BODY"
env:
GH_TOKEN: ${{ secrets.METABASE_AUTOMATION_USER_TOKEN }}
@@ -389,21 +394,36 @@ jobs:
name: metabase-sdk
path: sdk
- name: Compute master tag
id: compute-tag
run: |
if [ -n "${{ needs.determine-sdk-version.outputs.pre_release_label }}" ]; then
echo "masterTag=${{ needs.determine-sdk-version.outputs.pre_release_label }}" >> $GITHUB_OUTPUT
else
echo "masterTag=nightly" >> $GITHUB_OUTPUT
fi
- name: Publish to NPM
working-directory: sdk
run: |
echo //registry.npmjs.org/:_authToken=${{ secrets.NPM_RELEASE_TOKEN }} > .npmrc
# Please keep the value in sync with `inputs.branch`'s release branch
npm publish --tag ${{fromJson('{
"master": "nightly",
"release-x.51.x": "51-stable",
"release-x.52.x": "52-stable",
"release-x.53.x": "53-stable",
"release-x.54.x": "54-stable",
"release-x.55.x": "55-stable",
"release-x.56.x": "56-stable",
"esbuild-main": "56-esbuild"
}')[inputs.branch]}}
TAG=$(jq -r --null-input \
--arg branch "${{ inputs.branch }}" \
--arg masterTag "${{ steps.compute-tag.outputs.masterTag }}" '
{
"master": $masterTag,
"release-x.51.x": "51-stable",
"release-x.52.x": "52-stable",
"release-x.53.x": "53-stable",
"release-x.54.x": "54-stable",
"release-x.55.x": "55-stable",
"release-x.56.x": "56-stable"
}[$branch]'
)
echo "Resolved npm tag: $TAG"
npm publish --tag "$TAG"
- name: Add `latest` tag to the latest release branch (`release-x.55.x`) deployment
if: ${{ inputs.branch == 'release-x.56.x' }}

View File

@@ -12,7 +12,7 @@ concurrency:
cancel-in-progress: true
jobs:
semantic-search-tests-pgvector:
semantic-search-tests-h2:
if: ${{ !inputs.skip }}
runs-on: ubuntu-22.04
timeout-minutes: 60
@@ -20,11 +20,9 @@ jobs:
fail-fast: false
matrix:
version:
- name: pgvector pg16
junit-name: semantic-search-tests-pgvector-16
image: pgvector/pgvector:pg16
env:
enable-ssl-tests: 'false'
- name: H2 with pgvector pg17
junit-name: semantic-search-tests-h2-pgvector-17
pgvector-image: pgvector/pgvector:pg17
job:
- name: Semantic Search Tests
build-static-viz: false
@@ -34,7 +32,7 @@ jobs:
services:
pgvector:
image: ${{ matrix.version.image }}
image: ${{ matrix.version.pgvector-image }}
ports:
- "5432:5432"
env:
@@ -42,21 +40,6 @@ jobs:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
env:
# Only run old migrations tests on pushes to master or release branches. All other branches should skip tests
# with the tag `mb/old-migrations-test`. `__ADDITIONAL_EXCLUDED_TAG__` is not used anywhere outside of splicing
# it in to the command below.
__ADDITIONAL_EXCLUDED_TAG__: >-
${{
(
github.event_name == 'push' &&
(
github.ref == 'master' ||
startsWith(github.ref, 'release-')
) &&
''
) ||
':mb/old-migrations-test'
}}
MB_PGVECTOR_DB_URL: 'jdbc:postgres://localhost:5432/mb_semantic_search?user=postgres&password=postgres'
CI: 'true'
name: "${{ matrix.version.name }} ${{ matrix.job.name }}"
@@ -69,7 +52,224 @@ jobs:
junit-name: ${{ matrix.version.junit-name }}
test-args: >-
${{ matrix.job.test-args }}
:exclude-tags '[ ${{ matrix.job.exclude-tag }} ${{ env.__ADDITIONAL_EXCLUDED_TAG__ }}]'
:exclude-tags '[${{ matrix.job.exclude-tag }}]'
- name: Upload Test Results
uses: ./.github/actions/upload-test-results
if: always()
with:
input-path: ./target/junit/
output-name: ${{ github.job }}
bucket: ${{ vars.AWS_S3_TEST_RESULTS_BUCKET }}
aws-access-key-id: ${{ secrets.AWS_TEST_RESULTS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_TEST_RESULTS_SECRET_ACCESS_KEY }}
aws-region: ${{ vars.AWS_REGION }}
trunk-api-token: ${{ secrets.TRUNK_API_TOKEN }}
semantic-search-tests-mariadb:
if: ${{ !inputs.skip }}
runs-on: ubuntu-22.04
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
version:
- name: MariaDB 10.2 with pgvector pg17
junit-name: semantic-search-tests-mariadb-10-2
mariadb-image: circleci/mariadb:10.2.23
pgvector-image: pgvector/pgvector:pg17
- name: MariaDB Latest with pgvector pg17
junit-name: semantic-search-tests-mariadb-latest
mariadb-image: circleci/mariadb:latest
pgvector-image: pgvector/pgvector:pg17
job:
- name: Semantic Search Tests
build-static-viz: false
test-args: >-
:only '"enterprise/backend/test/metabase_enterprise/semantic_search"'
exclude-tag: ':mb/driver-tests'
services:
pgvector:
image: ${{ matrix.version.pgvector-image }}
ports:
- "5432:5432"
env:
POSTGRES_DB: mb_semantic_search
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
mysql:
image: ${{ matrix.version.mariadb-image }}
ports:
- "3306:3306"
env:
MYSQL_ALLOW_EMPTY_PASSWORD: true
MYSQL_DATABASE: circle_test
env:
CI: 'true'
DRIVERS: mysql
MB_DB_TYPE: mysql
MB_DB_HOST: localhost
MB_DB_PORT: 3306
MB_DB_DBNAME: circle_test
MB_DB_USER: root
MB_MYSQL_TEST_USER: root
MB_PGVECTOR_DB_URL: 'jdbc:postgres://localhost:5432/mb_semantic_search?user=postgres&password=postgres'
name: "${{ matrix.version.name }} ${{ matrix.job.name }}"
steps:
- uses: actions/checkout@v4
- name: Test ${{ matrix.version.name }}
uses: ./.github/actions/test-driver
with:
build-static-viz: ${{ matrix.job.build-static-viz }}
junit-name: ${{ matrix.version.junit-name }}
test-args: >-
${{ matrix.job.test-args }}
:exclude-tags '[${{ matrix.job.exclude-tag }}]'
- name: Upload Test Results
uses: ./.github/actions/upload-test-results
if: always()
with:
input-path: ./target/junit/
output-name: ${{ github.job }}
bucket: ${{ vars.AWS_S3_TEST_RESULTS_BUCKET }}
aws-access-key-id: ${{ secrets.AWS_TEST_RESULTS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_TEST_RESULTS_SECRET_ACCESS_KEY }}
aws-region: ${{ vars.AWS_REGION }}
trunk-api-token: ${{ secrets.TRUNK_API_TOKEN }}
semantic-search-tests-mysql:
if: ${{ !inputs.skip }}
runs-on: ubuntu-22.04
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
version:
- name: MySQL 8.0 with pgvector pg17
junit-name: semantic-search-tests-mysql-8-0
mysql-image: cimg/mysql:8.0
pgvector-image: pgvector/pgvector:pg17
- name: MySQL Latest with pgvector pg17
junit-name: semantic-search-tests-mysql-latest
mysql-image: mysql:latest
pgvector-image: pgvector/pgvector:pg17
job:
- name: Semantic Search Tests
build-static-viz: false
test-args: >-
:only '"enterprise/backend/test/metabase_enterprise/semantic_search"'
exclude-tag: ':mb/driver-tests'
services:
pgvector:
image: ${{ matrix.version.pgvector-image }}
ports:
- "5432:5432"
env:
POSTGRES_DB: mb_semantic_search
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
mysql:
image: ${{ matrix.version.mysql-image }}
ports:
- "3306:3306"
env:
MYSQL_ALLOW_EMPTY_PASSWORD: true
MYSQL_DATABASE: circle_test
env:
CI: 'true'
DRIVERS: mysql
MB_DB_TYPE: mysql
MB_DB_HOST: localhost
MB_DB_PORT: 3306
MB_DB_DBNAME: circle_test
MB_DB_USER: root
MB_MYSQL_TEST_USER: root
MB_PGVECTOR_DB_URL: 'jdbc:postgres://localhost:5432/mb_semantic_search?user=postgres&password=postgres'
name: "${{ matrix.version.name }} ${{ matrix.job.name }}"
steps:
- uses: actions/checkout@v4
- name: Test ${{ matrix.version.name }}
uses: ./.github/actions/test-driver
with:
build-static-viz: ${{ matrix.job.build-static-viz }}
junit-name: ${{ matrix.version.junit-name }}
test-args: >-
${{ matrix.job.test-args }}
:exclude-tags '[${{ matrix.job.exclude-tag }}]'
- name: Upload Test Results
uses: ./.github/actions/upload-test-results
if: always()
with:
input-path: ./target/junit/
output-name: ${{ github.job }}
bucket: ${{ vars.AWS_S3_TEST_RESULTS_BUCKET }}
aws-access-key-id: ${{ secrets.AWS_TEST_RESULTS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_TEST_RESULTS_SECRET_ACCESS_KEY }}
aws-region: ${{ vars.AWS_REGION }}
trunk-api-token: ${{ secrets.TRUNK_API_TOKEN }}
semantic-search-tests-postgres:
if: ${{ !inputs.skip }}
runs-on: ubuntu-22.04
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
version:
- name: Postgres 12.x with pgvector pg17
junit-name: semantic-search-tests-postgres-12
postgres-image: postgres:12-alpine
pgvector-image: pgvector/pgvector:pg17
- name: Postgres Latest with pgvector pg17
junit-name: semantic-search-tests-postgres-latest
postgres-image: postgres:latest
pgvector-image: pgvector/pgvector:pg17
job:
- name: Semantic Search Tests
build-static-viz: false
test-args: >-
:only '"enterprise/backend/test/metabase_enterprise/semantic_search"'
exclude-tag: ':mb/driver-tests'
services:
pgvector:
image: ${{ matrix.version.pgvector-image }}
ports:
- "5432:5432"
env:
POSTGRES_DB: mb_semantic_search
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
postgres:
image: ${{ matrix.version.postgres-image }}
ports:
- "5433:5432"
env:
POSTGRES_USER: mb_test
POSTGRES_DB: mb_test
POSTGRES_HOST_AUTH_METHOD: trust
env:
CI: 'true'
DRIVERS: postgres
MB_DB_TYPE: postgres
MB_DB_PORT: 5433
MB_DB_HOST: localhost
MB_DB_DBNAME: mb_test
MB_DB_USER: mb_test
MB_POSTGRESQL_TEST_USER: mb_test
MB_PGVECTOR_DB_URL: 'jdbc:postgres://localhost:5432/mb_semantic_search?user=postgres&password=postgres'
name: "${{ matrix.version.name }} ${{ matrix.job.name }}"
steps:
- uses: actions/checkout@v4
- name: Test ${{ matrix.version.name }}
uses: ./.github/actions/test-driver
with:
build-static-viz: ${{ matrix.job.build-static-viz }}
junit-name: ${{ matrix.version.junit-name }}
test-args: >-
${{ matrix.job.test-args }}
:exclude-tags '[${{ matrix.job.exclude-tag }}]'
- name: Upload Test Results
uses: ./.github/actions/upload-test-results
if: always()
@@ -84,7 +284,10 @@ jobs:
semantic-search-tests-result:
needs:
- semantic-search-tests-pgvector
- semantic-search-tests-h2
- semantic-search-tests-mariadb
- semantic-search-tests-mysql
- semantic-search-tests-postgres
runs-on: ubuntu-latest
timeout-minutes: 5
name: semantic-search-tests-result

View File

@@ -2,7 +2,7 @@ name: Uberjar Containerize labeled
on:
pull_request:
types: [ labeled ]
types: [ labeled, opened, synchronize, reopened ]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
@@ -10,12 +10,12 @@ concurrency:
jobs:
uberjar:
if: ${{ github.event.label.name == 'build-docker-uberjar' }}
if: ${{ contains(github.event.pull_request.labels.*.name, 'build-docker-uberjar') || github.event.label.name == 'build-docker-uberjar' }}
uses: ./.github/workflows/uberjar.yml
secrets: inherit
containerize:
needs: [uberjar]
if: ${{ github.event.label.name == 'build-docker-uberjar' }}
if: ${{ contains(github.event.pull_request.labels.*.name, 'build-docker-uberjar') || github.event.label.name == 'build-docker-uberjar' }}
uses: ./.github/workflows/containerize-uberjar.yml
secrets: inherit

8
.gitignore vendored
View File

@@ -98,6 +98,13 @@ xcuserdata
dev/src/dev/nocommit/
dev/serialization_deltas/
*~
# TypeScript compilation artifacts
/build/
*.tsbuildinfo
/trace-output/
/temp-types/
**/cypress_sample_database.json
**/cypress_sample_instance_data.json
/frontend/src/cljs
@@ -156,3 +163,4 @@ CLAUDE.local.md
/logs
/.clojure-mcp
__pycache__/

4
.gitmodules vendored Normal file
View File

@@ -0,0 +1,4 @@
[submodule "python-runner"]
path = python-runner
url = https://github.com/metabase/python-runner-container.git
branch = prototype

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 75 KiB

After

Width:  |  Height:  |  Size: 75 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 71 KiB

After

Width:  |  Height:  |  Size: 71 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 73 KiB

After

Width:  |  Height:  |  Size: 73 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 77 KiB

After

Width:  |  Height:  |  Size: 77 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 69 KiB

After

Width:  |  Height:  |  Size: 69 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 75 KiB

After

Width:  |  Height:  |  Size: 75 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 74 KiB

After

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 73 KiB

After

Width:  |  Height:  |  Size: 73 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 75 KiB

After

Width:  |  Height:  |  Size: 75 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 73 KiB

After

Width:  |  Height:  |  Size: 73 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 69 KiB

After

Width:  |  Height:  |  Size: 69 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 69 KiB

After

Width:  |  Height:  |  Size: 69 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 73 KiB

After

Width:  |  Height:  |  Size: 73 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 70 KiB

After

Width:  |  Height:  |  Size: 70 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 108 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 66 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 90 KiB

After

Width:  |  Height:  |  Size: 102 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 102 KiB

After

Width:  |  Height:  |  Size: 107 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 167 KiB

After

Width:  |  Height:  |  Size: 167 KiB

View File

@@ -1 +1,5 @@
accept = ["200..=204", "429"]
exclude_path = ["docs/embedding/sdk"]
no_progress = true
include_fragments = true
verbose = "error"

View File

View File

@@ -2,4 +2,4 @@ frontend/src/cljs
docs/configuring-metabase/environment-variables.md
docs/api/*
docs/api-documentation.md
.storybook-sdk/msw-public/mockServiceWorker.js
enterprise/frontend/src/embedding-sdk-shared/.storybook/msw-public/mockServiceWorker.js

View File

@@ -1,5 +1,6 @@
{
"extends": ["stylelint-config-standard", "stylelint-config-css-modules"],
"plugins": ["./frontend/lint/stylelint-rules/no-base-colors.js"],
"rules": {
"alpha-value-notation": null,
"color-function-notation": null,
@@ -26,6 +27,7 @@
"comment-empty-line-before": null,
"selector-pseudo-element-colon-notation": null,
"no-empty-source": null,
"font-family-no-missing-generic-family-keyword": null
"font-family-no-missing-generic-family-keyword": null,
"metabase/no-base-colors": true
}
}

View File

@@ -14,8 +14,7 @@
### JavaScript/TypeScript
- **Lint:** `yarn lint-eslint-pure`
- **Test:** `yarn test-unit path/to/file.unit.spec.js` or `yarn test-unit -t "pattern"`
- **Watch:** `yarn test-unit-watch path/to/file.unit.spec.js`
- **Test:** `yarn test-unit-keep-cljs path/to/file.unit.spec.js` or `yarn test-unit-keep-cljs -t "pattern"`
- **Format:** `yarn prettier`
- **Type Check:** `yarn type-check-pure`

2
bb.edn
View File

@@ -217,6 +217,8 @@
:task (let [{:keys [arguments]} (cli/parse! (current-task))]
(apply readability/check arguments))}
;; Uncomment this if you want to play with the example calculator task:
#_#_
-example-calculator
{;; `:doc` is a short docstring for the task, will be listed in `./bin/mage -h` and other help info.
;; Keep these short, they need to fit on one line in the output from `./bin/mage -h`.

View File

@@ -19,13 +19,15 @@ const REPLACES_MAP = {
"metabase-lib": "frontend/src/metabase-lib",
"metabase-types": "frontend/src/metabase-types",
metabase: "frontend/src/metabase",
"embedding-sdk-package": "enterprise/frontend/src/embedding-sdk-package",
"embedding-sdk-bundle": "enterprise/frontend/src/embedding-sdk-bundle",
"embedding-sdk-shared": "enterprise/frontend/src/embedding-sdk-shared",
cljs: "target/cljs_release",
};
const API_EXTRACTOR_CONFIG_PATH = path.join(
__dirname,
"../../enterprise/frontend/src/embedding-sdk-bundle/embedding-sdk-api-extractor.json",
"../../enterprise/frontend/src/embedding-sdk-package/embedding-sdk-api-extractor.json",
);
const getLogger = (prefix) => {
@@ -131,7 +133,7 @@ const generateDtsRollup = () => {
const dtsRollupEntryPointPath = path.resolve(
path.join(
__dirname,
"../../resources/embedding-sdk/dist/enterprise/frontend/src/embedding-sdk-bundle/index.d.ts",
"../../resources/embedding-sdk/dist/enterprise/frontend/src/embedding-sdk-package/index.d.ts",
),
);
const dtsRollupEntryPointPathExist = fs.existsSync(dtsRollupEntryPointPath);

View File

@@ -36,7 +36,7 @@ function generateSdkPackage() {
const sdkPackageTemplateJson = fs.readFileSync(
path.resolve(
"./enterprise/frontend/src/embedding-sdk-bundle/package.template.json",
"./enterprise/frontend/src/embedding-sdk-package/package.template.json",
),
"utf-8",
);
@@ -87,7 +87,7 @@ if (!fs.existsSync(SDK_DIST_DIR)) {
generateSdkPackage();
copyFileToOutput("LICENSE.txt");
copyFileToOutput("frontend/src/embedding-sdk-bundle/README.md", "README.md");
copyFileToOutput("frontend/src/embedding-sdk-package/README.md", "README.md");
copyFileToOutput(
"frontend/src/embedding-sdk-bundle/CHANGELOG.md",
"CHANGELOG.md",

View File

@@ -1,11 +1,11 @@
#!/bin/bash
function update_readme() {
sed -i -E 's|(embedding-sdk-)[0-9.]+|\1'"$1"'|' enterprise/frontend/src/embedding-sdk-bundle/README.md
sed -i -E 's|(http://downloads.metabase.com/sdk/v)[0-9.]+|\1'"$1"'|' enterprise/frontend/src/embedding-sdk-bundle/README.md
sed -i -E 's|(embedding-sdk-)[0-9.]+|\1'"$1"'|' enterprise/frontend/src/embedding-sdk-package/README.md
sed -i -E 's|(http://downloads.metabase.com/sdk/v)[0-9.]+|\1'"$1"'|' enterprise/frontend/src/embedding-sdk-package/README.md
}
function update_package_json_template() {
sed -i -E 's/("version": ").*"/\1'"$1"'"/' enterprise/frontend/src/embedding-sdk-bundle/package.template.json
sed -i -E 's/("version": ").*"/\1'"$1"'"/' enterprise/frontend/src/embedding-sdk-package/package.template.json
}
$1 $2

View File

@@ -1,19 +1,19 @@
#! /usr/bin/env bash
function prepare_files() {
tsx ./enterprise/frontend/src/embedding-sdk-bundle/bin/generate-cli-snippets-for-testing.ts
tsx ./enterprise/frontend/src/embedding-sdk-package/bin/generate-cli-snippets-for-testing.ts
}
function install_dependencies() {
yarn --cwd ./enterprise/frontend/src/embedding-sdk-bundle/cli-snippets-tmp/express-server install --frozen-lockfile
yarn --cwd ./enterprise/frontend/src/embedding-sdk-package/cli-snippets-tmp/express-server install --frozen-lockfile
}
function type_check() {
tsc --project ./enterprise/frontend/src/embedding-sdk-bundle/tsconfig.cli-snippets.json
tsc --project ./enterprise/frontend/src/embedding-sdk-package/tsconfig.cli-snippets.json
}
function cleanup_files() {
rm -rf ./enterprise/frontend/src/embedding-sdk-bundle/cli-snippets-tmp
rm -rf ./enterprise/frontend/src/embedding-sdk-package/cli-snippets-tmp
}
cleanup_files

14
ci-test-config.json Normal file
View File

@@ -0,0 +1,14 @@
{
"version": "1.0.0",
"ignored": {
"vars": [
"metabase.session.models.session-test/send-email-on-first-login-from-new-device-test",
"metabase-enterprise.impersonation.driver-test/nested-do-with-connection-with-options-test"
]
},
"metadata": {
"last_updated": "2025-08-02",
"updated_by": "dpsutton",
"reason": "Two flakes: send-email-on-first-login-from-new-device-test has schema error if emails from another thread are present; nested-do-with-connection-with-options-test is causing deadlocks i believe."
}
}

View File

@@ -36,7 +36,7 @@
com.clearspring.analytics/stream {:mvn/version "2.9.8" ; Various sketching algorithms
:exclusions [it.unimi.dsi/fastutil
org.slf4j/slf4j-api]}
com.clojure-goes-fast/jvm-alloc-rate-meter{:mvn/version "0.1.4"} ; Monitor heap allocation rate.
com.clojure-goes-fast/jvm-alloc-rate-meter {:mvn/version "0.1.4"} ; Monitor heap allocation rate.
com.clojure-goes-fast/jvm-hiccup-meter {:mvn/version "0.1.1"} ; Monitor GC pauses and other system-induced pauses.
com.draines/postal {:mvn/version "2.0.5" ; SMTP library
:exclusions [com.sun.mail/jakarta.mail]}
@@ -45,7 +45,7 @@
com.github.albfernandez/juniversalchardet {:mvn/version "2.5.0"}
com.github.blagerweij/liquibase-sessionlock {:mvn/version "1.6.9"} ; session lock for liquibase migrations
com.github.jknack/handlebars ^:antq/exclude ; 4.4.0 requires java 17+
{:mvn/version "4.3.1"} ; templating engine
{:mvn/version "4.3.1"} ; templating engine
com.github.oliyh/martian-clj-http {:mvn/version "0.1.31"} ; openapi client
com.github.pangloss/transducers {:git/sha "c91d39046c8c64dc31b84ebb27154a8084fcda4c" ; like medley for transducers
:git/url "https://github.com/pangloss/transducers"}
@@ -55,14 +55,14 @@
com.github.vertical-blank/sql-formatter {:mvn/version "2.0.5"} ; Java SQL formatting library https://github.com/vertical-blank/sql-formatter
com.google.guava/guava {:mvn/version "33.4.8-jre"} ; dep for BigQuery, Spark, and GA. Require here rather than letting different dep versions stomp on each other — see comments on #9697
com.h2database/h2 ^:antq/exclude ; https://metaboat.slack.com/archives/CKZEMT1MJ/p1727191010259979
{:mvn/version "2.1.214"} ; embedded SQL database
{:mvn/version "2.1.214"} ; embedded SQL database
com.ibm.icu/icu4j {:mvn/version "77.1"} ; Used to transliterate Unicode characters into Latin characters
com.knuddels/jtokkit {:mvn/version "1.1.0"} ; Java tokenizer library for OpenAI models, used for token counting in semantic search
com.mchange/c3p0 {:mvn/version "0.10.1"} ; DB connection pool
com.snowplowanalytics/snowplow-java-tracker ^:antq/exclude ; 2+ depend on apache httpclient 5.x, but saml and clj-http depend on 4.x
{:mvn/version "1.0.1"} ; Snowplow analytics
{:mvn/version "1.0.1"} ; Snowplow analytics
com.sun.mail/jakarta.mail ^:antq/exclude ; 2+ changes imports from javax.mail to jakarta.mail
{:mvn/version "1.6.8"} ; SMTP lib, required by postal
{:mvn/version "1.6.8"} ; SMTP lib, required by postal
com.taoensso/nippy {:mvn/version "3.6.0"} ; Fast serialization (i.e., GZIP) library for Clojure
com.vladsch.flexmark/flexmark {:mvn/version "0.64.8"} ; Markdown parsing
com.vladsch.flexmark/flexmark-ext-autolink
@@ -92,7 +92,7 @@
;; TODO: replace back to normal artifact
io.github.metabase/macaw {:mvn/version "0.2.27"} ; Parse native SQL queries
io.github.resilience4j/resilience4j-retry ^:antq/exclude ; 2.x do not support Java 8
{:mvn/version "1.7.1"} ; Support for retrying operations
{:mvn/version "1.7.1"} ; Support for retrying operations
io.prometheus/simpleclient_hotspot {:mvn/version "0.16.0"} ; prometheus jvm collector
junegunn/grouper {:mvn/version "0.1.1"} ; Batch processing helper
kixi/stats {:mvn/version "0.5.7" ; Various statistic measures implemented as transducers
@@ -118,7 +118,7 @@
net.sf.cssbox/cssbox {:mvn/version "5.0.2" ; HTML / CSS rendering
:exclusions [org.slf4j/slf4j-api
junit/junit]}
net.thisptr/jackson-jq {:mvn/version "1.4.0"} ; Java implementation of the JQ json query language
net.thisptr/jackson-jq {:mvn/version "1.6.0"} ; Java implementation of the JQ json query language
org.apache.commons/commons-compress {:mvn/version "1.28.0"} ; compression utils
org.apache.commons/commons-lang3 {:mvn/version "3.18.0"} ; helper methods for working with java.lang stuff
org.apache.logging.log4j/log4j-1.2-api {:mvn/version "2.25.1"} ; apache logging framework
@@ -135,7 +135,7 @@
:exclusions [org.bouncycastle/bcpkix-jdk15on
org.bouncycastle/bcprov-jdk15on]}
org.apache.poi/poi-ooxml-full {:mvn/version "5.4.1"}
org.apache.sshd/sshd-core {:mvn/version "2.15.0" ; ssh tunneling and test server
org.apache.sshd/sshd-core {:mvn/version "2.16.0" ; ssh tunneling and test server
:exclusions [org.slf4j/slf4j-api
org.slf4j/jcl-over-slf4j]}
org.apache.tika/tika-core {:mvn/version "3.2.2"}
@@ -147,7 +147,7 @@
org.clj-commons/hickory {:mvn/version "0.7.7" ; Parse HTML into Clojure data structures
:exclusions [org.jsoup/jsoup]}
org.clojars.pntblnk/clj-ldap {:mvn/version "0.0.17"} ; LDAP client
org.clojure/clojure {:mvn/version "1.12.1"}
org.clojure/clojure {:mvn/version "1.12.2"}
org.clojure/core.async {:mvn/version "1.7.701"
:exclusions [org.clojure/tools.reader]}
org.clojure/core.logic {:mvn/version "1.1.0"} ; optimized pattern matching library for Clojure
@@ -198,6 +198,8 @@
org.eclipse.jetty.ee9/jetty-ee9-servlet
org.eclipse.jetty.ee9.websocket/jetty-ee9-websocket-jetty-server]}
slingshot/slingshot {:mvn/version "0.12.2"} ; enhanced throw/catch, used by other deps
software.amazon.awssdk/s3 {:mvn/version "2.33.0"}
software.amazon.awssdk/sts {:mvn/version "2.33.0"} ; AWS SDK v2 for S3
stencil/stencil {:mvn/version "0.5.0"} ; Mustache templates for Clojure
user-agent/user-agent {:mvn/version "0.1.1"} ; User-Agent string parser, for Login History page & elsewhere
weavejester/dependency {:mvn/version "1.0.0"} ; Dependency graphs and topological sorting
@@ -253,9 +255,9 @@
{:mvn/version "0.4.0"} ; Enables easy memory measurement
com.gfredericks/test.chuck {:mvn/version "0.2.15"} ; generating strings from regexes (useful with malli)
criterium/criterium {:mvn/version "0.4.6"} ; benchmarking library
djblue/portal {:mvn/version "0.60.2"} ; ui for inspecting values
djblue/portal {:mvn/version "0.61.0"} ; ui for inspecting values
io.github.camsaul/humane-are {:mvn/version "1.0.2"} ; cleaner test output
io.github.metabase/hawk {:sha "1fe839cfa48549e21b89c6418c747895eda7e7bc"} ; test runner
io.github.metabase/hawk {:mvn/version "1.0.11"} ; test runner
jonase/eastwood {:mvn/version "1.4.3" ; inspects namespaces and reports possible problems using tools.analyzer
:exclusions
[org.ow2.asm/asm-all]}
@@ -409,7 +411,7 @@
cider/piggieback {:mvn/version "0.6.0"}
cljs-bean/cljs-bean {:mvn/version "1.9.0"}
com.lambdaisland/glogi {:mvn/version "1.3.169"}
io.github.metabase/hawk {:mvn/version "1.0.7"}
io.github.metabase/hawk {:mvn/version "1.0.11"}
org.clojars.mmb90/cljs-cache {:mvn/version "0.1.4"}
refactor-nrepl/refactor-nrepl {:mvn/version "3.11.0"}
;; keep it in sync with package.json
@@ -836,8 +838,13 @@
:test/lib
{:exec-args {:only ["test/metabase/lib"
"test/metabase/lib_be"]}}
;; test the python transforms
;; clj -X:dev:ee:ee-dev:driver:test:test/python-transform
:test/python-transform
{:exec-args {:only [metabase-enterprise.transforms.api-test
"enterprise/backend/test/metabase_enterprise/transforms"]}}
;; test the Query Processor
;; test the Query Processor
;;
;; clj -X:dev:ee:ee-dev:test:test/qp
:test/qp

View File

@@ -92,6 +92,7 @@
(future
#_:clj-kondo/ignore
(println "Starting Metabase cider repl on port" port)
(spit ".nrepl-port" port)
(nrepl-server/start-server
:port port
:bind "0.0.0.0"

View File

@@ -139,6 +139,12 @@ Metabase's reference documentation.
- [Basic actions](./actions/basic.md)
- [Custom actions](./actions/custom.md)
### AI
- [AI overview](./ai/start.md)
- [Metabot](./ai/metabot.md)
- [Setting up Metabot](./ai/settings.md)
### Exploration and organization
- [Organization overview](./exploration-and-organization/start.md)

Binary file not shown.

After

Width:  |  Height:  |  Size: 158 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 402 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 151 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 172 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 206 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 349 KiB

BIN
docs/ai/images/metabot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

100
docs/ai/metabot.md Normal file
View File

@@ -0,0 +1,100 @@
---
title: Metabot - Metabase's AI assistant
summary: Metabot is Metabase's AI assistant that helps you analyze data, create charts, write SQL, fix errors, find content, and get answers from documentation.
---
# Metabot - Metabase's AI assistant
{% include beta-blockquote.html
message="For now, <a href='https://www.metabase.com/features/metabot-ai'>Metabot</a> is only available as an add-on for Pro and Enterprise plans on Metabase Cloud."
%}
![Meet Metabot](./images/metabot.png)
Metabot helps you analyze your data by creating charts from natural language, generating SQL queries, fixing query errors, and analyzing existing visualizations.
To set up Metabot, see [Metabot settings](./settings.md).
## What Metabot can do
Metabot can help you to:
- [Create a chart using the query builder](#how-metabot-uses-the-query-builder) from a natural language query.
- [Generate SQL in the native editor](../questions/native-editor/writing-sql.md) from natural language. (Currently, only SQL is supported.)
- [Analyze a chart](#analyze-charts-with-metabot).
- [Fix errors in SQL code](#have-metabot-fix-sql-queries).
- Answer questions from our documentation (as in, the literature you're reading right now).
Like with all generative AI, you'll always need to double-check results.
## The Metabot chat sidebar
![Metabot chat sidebar](./images/metabot-conversation-sidebar.png)
There are multiple ways to start a chat with Metabot:
- Type cmd+b on Mac, ctrl+b on Windows, to open up the [chat sidebar](#the-metabot-chat-sidebar).
- Click the Metabot icon in the search bar.
- Type cmd+k on Mac, or ctrl+k on Windows, to open the [command palette](../exploration-and-organization/exploration.md#command-palette). Select the Metabot option to **Ask me to do something, or ask a question**.
You can chat with Metabot (though predictably, it's only interested in helping you answer questions about your data).
Metabot will keep the context of the current question with each new prompt. Only the current conversation history is saved (you can scroll up to see it). If you start a new chat, Metabase will discard the previous conversation, so be mindful when resetting the conversation.
Some tips:
- Give Metabot as much context as you can. If you know the table or fields you want to query, tell Metabot.
- Whenever you want Metabot to do something completely different, you should reset the conversation, as Metabot might find that irrelevant historical context to be confusing.
- Once Metabot creates a question for you, you can follow up with more questions or take over yourself. You can drill through the chart or step into the editor to tweak the query (both in the query builder and the SQL editor).
- Metabot works best with English prompts. While it might understand other languages, you'll get the most reliable results by asking your questions in English.
### Metabot response menu
Hover over Metabot's response to:
- Copy the response.
- Give thumbs-up/thumbs-down feedback on responses. If you downvote a response, you can optionally contribute a bug report to help us improve Metabot.
- Re-run the prompt with Metabot. This is useful if you've updated the chart or just want to have Metabot take another pass (since AI responses aren't deterministic, Metabot may give a different response on another run).
## Analyze charts with Metabot
![Metabot analyzes a chart](./images/metabot-response.png)
When viewing a question, you can click the Metabot icon in the upper right to analyze a visualization. You can also open the command palette to tell Metabot to analyze the chart.
When viewing a table of results, Metabase won't display the Metabot button, but you can open the chat to ask Metabot to analyze the table, and it will produce an [X-ray](../exploration-and-organization/x-rays.md) of the results.
You can also ask Metabot to tell you about specific tables in your database.
## How Metabot uses the query builder
When you ask Metabot to create a chart from natural language, it first looks for existing questions that might answer your request. If it finds a relevant question, it'll point you to that instead of creating something new. Otherwise, Metabot will use the [query builder](../questions/query-builder/editor.md) to create a new chart for you.
Keep in mind that Metabot is still learning the query builder. Metabot can only handle basic query builder operations, and it lacks access to the library of [custom expressions](../questions/query-builder/expressions-list.md). Metabot is also limited to single-level aggregation and grouping, so if you need more complex analysis, you can take over and refine the query yourself, or switch to the SQL editor.
## Metabot in the native editor
![Metabot will generate SQL from a highlighted prompt in natural language](./images/generate-sql-from-natural-language-prompt.png)
To have Metabot generate SQL for you:
1. Open the [SQL editor](../questions/native-editor/writing-sql.md).
2. Select the database you want to query.
3. Type cmd+b on Mac, ctrl+b on Windows, to open up the [chat sidebar](#the-metabot-chat-sidebar).
4. Ask it to "Write a SQL query that..." and type your prompt.
Metabot will generate the SQL for you, but it won't run the query. This gives you a chance to inspect the code before running it. The native editor is designed to be read-only (so don't worry about Metabot dropping any tables), but you should still check the query to make sure it targets the data you want.
If you don't specify a specific table in a natural language question, Metabot will only check the first 100 tables in the currently selected database. If your question pertains to tables other than those first 100 tables, Metabot may hallucinate the tables it needs, and the query will fail.
## Have Metabot fix SQL queries
![Metabot can try and fix SQL query errors](./images/have-metabot-fix-it.png)
When you get an error in a SQL query, you can click the **Have Metabot fix it** button, and Metabot will try to correct the query. You can also ask Metabot to fix your SQL in the chat.
## Navigating after Metabot creates a chart
If Metabot creates a query or takes you to a new item but you want to return to the previous screen, you can navigate using your browser's back button.
You can also save any chart that Metabot creates to a dashboard or collection.

91
docs/ai/settings.md Normal file
View File

@@ -0,0 +1,91 @@
---
title: Metabot settings
summary: Configure Metabot settings, including which collections Metabot can access, and learn tips for improving Metabot's performance through data modeling and metadata.
---
# Metabot settings
{% include beta-blockquote.html
message="For now, <a href='https://www.metabase.com/features/metabot-ai'>Metabot</a> is only available as an add-on for Pro and Enterprise plans on Metabase Cloud."
%}
_Settings > Admin settings > AI_
This page covers admin settings for Metabase's AI assistant, [Metabot](./metabot.md).
## Configure Metabot
To help Metabot focus on the data you care about most, select the collection containing the models and metrics you'd like it to work with.
## Pick a collection for Metabot to have access to
![Admin settings for AI Metabot](./images/ai-settings.png)
To select a collection for Metabot:
1. Go to **Settings** > **Admin settings** > **AI**.
2. Click the **Collection** dropdown.
3. Select the collection that contains the models and metrics you want Metabot to use.
Metabot will use the models and metrics in that collection to help answer questions and generate queries. You can change this collection at any time.
## Tips for making the most of Metabot
The best thing you can do to improve Metabot's performance is to prep your data like you would for onboarding a new (human) hire to your data. In practice, this means you should:
- [Add models and metrics to your Metabot collection](#add-models-and-metrics-to-your-metabot-collection)
- [Add descriptions for your data and content](#add-descriptions-for-your-data-and-content)
- [Make sure the semantic types for each field are correct](#make-sure-the-semantic-types-for-each-field-are-correct)
- [Curate prompt suggestions](#curate-prompt-suggestions)
### Add models and metrics to your Metabot collection
Create models that make it easy for Metabot to find answers to the kinds of questions you expect people to ask about your data. Create metrics that capture key business calculations that people frequently need to reference. Add these models and metrics to the collection you've designated for Metabot to learn from.
For example, if people often ask questions about customer lifetime value (LTV), create a model that joins customer data with order history and calculates LTV. Or if people frequently need to know monthly active users (MAU), create a metric that defines exactly how MAU should be calculated.
### Add descriptions for your data and content
Add descriptions to your [models](../data-modeling/models.md#add-metadata-to-columns-in-a-model), [metrics](../data-modeling/metrics.md), [dashboards](../dashboards/introduction.md), and [questions](../questions/introduction.md). Write descriptions to provide context, define terms, and explain business logic.
Admins can also curate [table metadata](../data-modeling/metadata-editing.md) by adding descriptions for tables and their fields.
For example, here's a decent description for an ID field that provides additional context for the data:
```txt
This is a unique ID for the product. It is also called the “Invoice number” or “Confirmation number” in customer facing emails and screens.
```
You can even ask Metabot to write descriptions for you. But Metabot will only have access to the data in the database. It can't know things like "this ID is called the 'Invoice number' in the web app", which is the kind of contextual information worth documenting.
### Make sure the semantic types for each field are correct
Make sure the semantic types for each field accurately describe the field's "meaning". For example, if you have a field like `created_at`, you'd want the column type to be Creation date.
Metabase will try to set semantic types automatically, but you should confirm that each field has the relevant semantic type. See [Data types and semantic types](../data-modeling/semantic-types.md). You can also set semantic types for [models](../data-modeling/models.md#add-metadata-to-columns-in-a-model).
### Curate prompt suggestions
When you select a collection for Metabot to "learn", Metabot will suggest a series of prompts based on the content it finds in that collection. These give people a feel for the kinds of things people can ask Metabot to do.
Admins can run these generated prompts to test the answers, or trash the individual prompts if they're not useful or misleading. You can also regenerate all the prompts with a click.
## Metabot permissions are Metabase permissions
Metabot inherits the permissions of the current user, so you don't need to set permissions specifically for Metabot. Whenever someone uses Metabot, Metabot can only see what that person has permissions to see and do.
In other words, to restrict what data Metabot can see for each person, simply apply [data](../permissions/data.md) and [collection](../permissions/collections.md) permissions to their groups as you would normally, and those permissions will apply to their use of Metabot as well.
## Metabot is only available instance-wide, not per person
Currently, Metabot will be available to everyone who uses your Metabase.
## Metabot uses a variety of generative AI models to answer your questions
Under the hood, Metabase powers Metabot with a variety of generative models. For now, you can't change which generative AI models Metabot uses, as Metabase's AI service handles their selection.
To get the best results, we (the Metabase team) use internal benchmarks to determine which AI models Metabot should use for different tasks. And we are constantly iterating on performance, so Metabot will continue to improve over time.
## We don't collect or store the prompts you send to Metabot
Your questions and conversations remain private to your Metabase. We do collect some metadata to gauge and improve usage, but we can't see your prompt or any of your data.

17
docs/ai/start.md Normal file
View File

@@ -0,0 +1,17 @@
---
title: "AI in Metabase"
---
# AI in Metabase
{% include beta-blockquote.html %}
> For now, [Metabot](https://www.metabase.com/features/metabot-ai) is only available as an add-on for Pro and Enterprise plans on Metabase Cloud.
## [Metabot](./metabot.md)
Metabot is an AI assistant that helps you explore and analyze your data.
## [Setting up Metabot](./settings.md)
Admins can configure Metabot to focus on specific collections and manage example prompts.

View File

@@ -1829,7 +1829,8 @@ redirect_from:
},
"schema" : {
"anyOf" : [ {
"type" : "string"
"type" : "string",
"minLength" : 1
}, {
"type" : "null"
} ]
@@ -2199,15 +2200,19 @@ redirect_from:
"required" : [ "moved" ]
},
"metabase.legacy-mbql.schema.!=" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.*" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.+" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.-" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema..parameter.target" : {
@@ -2223,21 +2228,27 @@ redirect_from:
} ]
},
"metabase.legacy-mbql.schema./" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.<" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.<=" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.=" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.>" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.>=" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.Addable" : {
@@ -2376,6 +2387,13 @@ redirect_from:
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.today"
} ]
},
"metabase.legacy-mbql.schema.Emptyable" : {
"anyOf" : [ {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.StringExpressionArg"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.field-or-expression-ref"
} ]
},
"metabase.legacy-mbql.schema.EqualityComparable" : {
"anyOf" : [ {
"type" : "boolean"
@@ -2482,7 +2500,7 @@ redirect_from:
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case:if"
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.offset"
}, {
@@ -2703,7 +2721,7 @@ redirect_from:
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case:if"
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.datetime-diff"
}, {
@@ -2960,7 +2978,7 @@ redirect_from:
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case:if"
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.host"
}, {
@@ -3213,13 +3231,13 @@ redirect_from:
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.case:if"
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.if"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.median"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.percentile"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.ag:var"
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.var"
}, {
"$ref" : "#/components/schemas/metabase.legacy-mbql.schema.cum-count"
}, {
@@ -3255,43 +3273,48 @@ redirect_from:
"$ref" : "#/components/schemas/metabase.lib.schema.parameter.widget-type"
},
"metabase.legacy-mbql.schema.abs" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.absolute-datetime" : {
"oneOf" : [ { }, {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
}, {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
} ]
},
"metabase.legacy-mbql.schema.ag:var" : {
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.aggregation" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.aggregation-options" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.and" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.asc" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.avg" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.between" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.case" : {
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.case:if" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.ceil" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.check-keys-for-query-type" : {
@@ -3301,91 +3324,118 @@ redirect_from:
"description" : "`:source-metadata` is added to queries when `card__id` source queries are resolved. It contains info about the\n columns in the source query.\n\n Where this is added was changed in Metabase 0.33.0 -- previously, when `card__id` source queries were resolved, the\n middleware would add `:source-metadata` to the top-level; to support joins against source queries, this has been\n changed so it is always added at the same level the resolved `:source-query` is added.\n\n This should automatically be fixed by `normalize`; if we encounter it, it means some middleware is not functioning\n properly."
},
"metabase.legacy-mbql.schema.coalesce" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.concat" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.contains" : {
"anyOf" : [ {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
}, {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
} ]
},
"metabase.legacy-mbql.schema.convert-timezone" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.count" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.count-where" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.cum-count" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.cum-sum" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.date" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.datetime" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.datetime-add" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.datetime-diff" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.datetime-subtract" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.day-name" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.desc" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.dimension" : {
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.distinct" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.distinct-where" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.does-not-contain" : {
"anyOf" : [ {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
}, {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
} ]
},
"metabase.legacy-mbql.schema.domain" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.during" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.ends-with" : {
"anyOf" : [ {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
}, {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
} ]
},
"metabase.legacy-mbql.schema.exp" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.expression" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.field" : {
"allOf" : [ {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
}, {
"description" : "Fields using names rather than integer IDs are required to specify `:base-type`.",
@@ -3400,60 +3450,82 @@ redirect_from:
} ]
},
"metabase.legacy-mbql.schema.float" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.floor" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.get-day" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.get-day-of-week" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.get-hour" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.get-minute" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.get-month" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.get-quarter" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.get-second" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.get-week" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.get-year" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.helpers.distinct" : {
"description" : "values must be distinct"
},
"metabase.legacy-mbql.schema.host" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.if" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.in" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.inside" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.integer" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.interval" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.is-empty" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.is-null" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.legacy-column-metadata" : {
@@ -3500,148 +3572,199 @@ redirect_from:
"required" : [ "base_type", "display_name", "name" ]
},
"metabase.legacy-mbql.schema.length" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.log" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.lower" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.ltrim" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.max" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.median" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.metric" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.min" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.month-name" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.no-binning-options-at-top-level" : { },
"metabase.legacy-mbql.schema.not" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.not-empty" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.not-in" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.not-null" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.now" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.offset" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.or" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.path" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.percentile" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.power" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.quarter-name" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.regex-match-first" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.relative-datetime" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.relative-time-interval" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.replace" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.require-base-type-for-field-name" : { },
"metabase.legacy-mbql.schema.round" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.rtrim" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.segment" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.share" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.split-part" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.sqrt" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.starts-with" : {
"anyOf" : [ {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
}, {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
} ]
},
"metabase.legacy-mbql.schema.stddev" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.subdomain" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.substring" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.sum" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.sum-where" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.template-tag" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.temporal-extract" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.text" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.time" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.time-interval" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.today" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.trim" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.upper" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.validate-temporal-unit" : { },
"metabase.legacy-mbql.schema.value" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.var" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.legacy-mbql.schema.variable" : {
"description" : "schema for a valid legacy MBQL :tag clause",
"allOf" : [ ]
},
"metabase.lib.schema.actions.row" : {
@@ -4639,7 +4762,7 @@ redirect_from:
},
"metabase.lib.schema.temporal-bucketing.unit" : {
"type" : "string",
"enum" : [ "quarter", "day", "hour", "week", "second", "default", "day-of-week", "hour-of-day", "month", "month-of-year", "day-of-month", "year", "day-of-year", "millisecond", "year-of-era", "second-of-minute", "week-of-year", "quarter-of-year", "minute-of-hour", "minute" ]
"enum" : [ "day", "day-of-month", "day-of-week", "day-of-year", "default", "hour", "hour-of-day", "millisecond", "minute", "minute-of-hour", "month", "month-of-year", "quarter", "quarter-of-year", "second", "second-of-minute", "week", "week-of-year", "year", "year-of-era" ]
},
"metabase.logger.api.log-level" : {
"type" : "string",
@@ -5422,40 +5545,34 @@ redirect_from:
"metabase.warehouses.api.available-settings" : {
"type" : "object",
"additionalProperties" : {
"oneOf" : [ {
"type" : "object",
"properties" : {
"enabled" : {
"const" : true
}
"type" : "object",
"properties" : {
"enabled" : {
"type" : "boolean"
},
"required" : [ "enabled" ]
}, {
"type" : "object",
"properties" : {
"enabled" : {
"const" : false
},
"reasons" : {
"type" : "array",
"items" : {
"type" : "object",
"properties" : {
"key" : {
"type" : "string"
},
"message" : {
"anyOf" : [ {
"type" : "string"
}, { } ]
}
"reasons" : {
"type" : "array",
"items" : {
"type" : "object",
"properties" : {
"key" : {
"type" : "string"
},
"required" : [ "key", "message" ]
}
"message" : {
"anyOf" : [ {
"type" : "string"
}, { } ]
},
"type" : {
"type" : "string",
"enum" : [ "error", "warning" ]
}
},
"required" : [ "key", "type", "message" ]
}
},
"required" : [ "enabled", "reasons" ]
} ]
}
},
"required" : [ "enabled" ]
}
},
"metabot.reaction.redirect" : {
@@ -11395,7 +11512,7 @@ redirect_from:
} ],
"responses" : {
"2XX" : {
"description" : "map where {:settings -> <map from <keyword> to <one of <true = map where {:enabled -> <must equal true>} | false = map where {:enabled -> <must equal false>, :reasons -> <sequence of map where {:key -> <keyword>, :message -> <string, or function>}>}> dispatched by :enabled>>}",
"description" : "map where {:settings -> <map from <keyword> to <map where {:enabled -> <boolean>, :reasons (optional) -> <sequence of map where {:key -> <keyword>, :type -> <enum of :error, :warning>, :message -> <string, or function>}>}>>}",
"content" : {
"application/json" : {
"schema" : {
@@ -12487,6 +12604,48 @@ redirect_from:
"tags" : [ "/api/ee/billing" ]
}
},
"/api/ee/cloud-add-ons/{product-type}" : {
"post" : {
"summary" : "POST /api/ee/cloud-add-ons/{product-type}",
"description" : "Purchase an add-on.",
"parameters" : [ {
"in" : "path",
"name" : "product-type",
"required" : true,
"schema" : {
"type" : "string",
"enum" : [ "metabase-ai" ]
}
} ],
"responses" : {
"2XX" : {
"description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
},
"5XX" : {
"description" : "Server error response"
}
},
"requestBody" : {
"content" : {
"application/json" : {
"schema" : {
"type" : "object",
"properties" : {
"terms_of_service" : {
"type" : "boolean"
}
},
"required" : [ "terms_of_service" ]
}
}
}
},
"tags" : [ "/api/ee/cloud-add-ons" ]
}
},
"/api/ee/content-translation/csv" : {
"get" : {
"summary" : "GET /api/ee/content-translation/csv",
@@ -12598,6 +12757,30 @@ redirect_from:
"description" : "Server error response"
}
},
"requestBody" : {
"content" : {
"application/json" : {
"schema" : {
"type" : "object",
"properties" : {
"replicationSchemaFilters" : {
"type" : "object",
"properties" : {
"schema-filters-patterns" : {
"type" : "string"
},
"schema-filters-type" : {
"type" : "string",
"enum" : [ "inclusion", "exclusion", "all" ]
}
},
"required" : [ "schema-filters-type", "schema-filters-patterns" ]
}
}
}
}
}
},
"tags" : [ "/api/ee/database-replication" ]
},
"delete" : {
@@ -12627,6 +12810,58 @@ redirect_from:
"tags" : [ "/api/ee/database-replication" ]
}
},
"/api/ee/database-replication/connection/{database-id}/preview" : {
"post" : {
"summary" : "POST /api/ee/database-replication/connection/{database-id}/preview",
"description" : "Return info about pg-replication connection that is about to be created.",
"parameters" : [ {
"in" : "path",
"name" : "database-id",
"required" : true,
"schema" : {
"type" : "integer",
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
"description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
},
"5XX" : {
"description" : "Server error response"
}
},
"requestBody" : {
"content" : {
"application/json" : {
"schema" : {
"type" : "object",
"properties" : {
"replicationSchemaFilters" : {
"type" : "object",
"properties" : {
"schema-filters-patterns" : {
"type" : "string"
},
"schema-filters-type" : {
"type" : "string",
"enum" : [ "inclusion", "exclusion", "all" ]
}
},
"required" : [ "schema-filters-type", "schema-filters-patterns" ]
}
}
}
}
}
},
"tags" : [ "/api/ee/database-replication" ]
}
},
"/api/ee/database-routing/destination-database" : {
"post" : {
"summary" : "POST /api/ee/database-routing/destination-database",
@@ -14602,6 +14837,9 @@ redirect_from:
"metabot_id" : {
"type" : "string"
},
"profile_id" : {
"type" : "string"
},
"state" : {
"type" : "object",
"properties" : { }
@@ -14655,6 +14893,9 @@ redirect_from:
"metabot_id" : {
"type" : "string"
},
"profile_id" : {
"type" : "string"
},
"state" : {
"type" : "object",
"properties" : { }
@@ -15623,7 +15864,35 @@ redirect_from:
"get" : {
"summary" : "GET /api/ee/transform-job/",
"description" : "Get all transform jobs.",
"parameters" : [ ],
"parameters" : [ {
"in" : "query",
"name" : "last_run_start_time",
"required" : false,
"schema" : {
"type" : "string",
"minLength" : 1
}
}, {
"in" : "query",
"name" : "next_run_start_time",
"required" : false,
"schema" : {
"type" : "string",
"minLength" : 1
}
}, {
"in" : "query",
"name" : "transform_tag_ids",
"required" : false,
"schema" : {
"type" : "array",
"items" : {
"description" : "value must be an integer greater or equal to than zero.",
"type" : "integer",
"minimum" : 0
}
}
} ],
"responses" : {
"2XX" : {
"description" : "Successful response"
@@ -15777,6 +16046,34 @@ redirect_from:
"tags" : [ "/api/ee/transform-job" ]
}
},
"/api/ee/transform-job/{job-id}/transforms" : {
"get" : {
"summary" : "GET /api/ee/transform-job/{job-id}/transforms",
"description" : "Get the transforms of job specified by the job's ID.",
"parameters" : [ {
"in" : "path",
"name" : "job-id",
"required" : true,
"schema" : {
"type" : "integer",
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
"description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
},
"5XX" : {
"description" : "Server error response"
}
},
"tags" : [ "/api/ee/transform-job" ]
}
},
"/api/ee/transform-tag/" : {
"post" : {
"summary" : "POST /api/ee/transform-tag/",
@@ -16025,6 +16322,33 @@ redirect_from:
"minimum" : 0
}
}
}, {
"in" : "query",
"name" : "start_time",
"required" : false,
"schema" : {
"type" : "string",
"minLength" : 1
}
}, {
"in" : "query",
"name" : "end_time",
"required" : false,
"schema" : {
"type" : "string",
"minLength" : 1
}
}, {
"in" : "query",
"name" : "run_methods",
"required" : false,
"schema" : {
"type" : "array",
"items" : {
"type" : "string",
"enum" : [ "manual", "cron" ]
}
}
} ],
"responses" : {
"2XX" : {
@@ -16180,6 +16504,34 @@ redirect_from:
"tags" : [ "/api/ee/transform" ]
}
},
"/api/ee/transform/{id}/dependencies" : {
"get" : {
"summary" : "GET /api/ee/transform/{id}/dependencies",
"description" : "Get the dependencies of a specific transform.",
"parameters" : [ {
"in" : "path",
"name" : "id",
"required" : true,
"schema" : {
"type" : "integer",
"minimum" : 1
},
"description" : "value must be an integer greater than zero."
} ],
"responses" : {
"2XX" : {
"description" : "Successful response"
},
"4XX" : {
"description" : "Client error response"
},
"5XX" : {
"description" : "Server error response"
}
},
"tags" : [ "/api/ee/transform" ]
}
},
"/api/ee/transform/{id}/run" : {
"post" : {
"summary" : "POST /api/ee/transform/{id}/run",
@@ -22463,7 +22815,7 @@ redirect_from:
"/api/setup/" : {
"post" : {
"summary" : "POST /api/setup/",
"description" : "Special endpoint for creating the first user during setup. This endpoint both creates the user AND logs them in and\n returns a session ID. This endpoint can also be used to add a database, create and invite a second admin, and/or\n set specific settings from the setup flow.",
"description" : "Special endpoint for creating the first user during setup. This endpoint both creates the user AND logs them in and\n returns a session ID. This endpoint can also be used to set specific settings from the setup flow.",
"parameters" : [ ],
"responses" : {
"2XX" : {
@@ -22482,23 +22834,6 @@ redirect_from:
"schema" : {
"type" : "object",
"properties" : {
"invite" : {
"type" : "object",
"properties" : {
"email" : {
"description" : "value must be a valid email address.",
"type" : "string"
},
"first_name" : {
"type" : "string",
"minLength" : 1
},
"last_name" : {
"type" : "string",
"minLength" : 1
}
}
},
"prefs" : {
"type" : "object",
"properties" : {
@@ -24330,6 +24665,11 @@ redirect_from:
"type" : "object",
"additionalProperties" : { }
},
"source" : {
"type" : "string",
"minLength" : 1,
"default" : "admin"
},
"user_group_memberships" : {
"type" : "array",
"items" : {

View File

@@ -14,7 +14,7 @@ Managing billing and accounts in the Metabase Store.
## Try out a free 14-day trial of Pro
If you're on a [Starter](/product/starter) cloud plan, you can try out [all the features of Metabase Pro](/product/pro) for free for 14 days with no commitment.
If you're on a [Starter](https://www.metabase.com/product/starter) cloud plan, you can try out [all the features of Metabase Pro](https://www.metabase.com/product/pro) for free for 14 days with no commitment.
If you want to stick with Pro, you'll have the chance to upgrade. Otherwise, your plan will automatically switch back to Starter.
@@ -62,7 +62,7 @@ To cancel a Starter or Pro plan directly in the Metabase Store:
1. Log in to your Metabase [Store account](https://store.metabase.com).
2. Go to **Instances**.
3. Under the instance with the subscription that you want to cancel, click **Cancel subscription and delete instance**. If you're on an Enterprise plan, you'll need to [contact support](/help-premium).
3. Under the instance with the subscription that you want to cancel, click **Cancel subscription and delete instance**. If you're on an Enterprise plan, you'll need to [contact support](https://www.metabase.com/help-premium).
## Update payment information
@@ -93,7 +93,7 @@ Note that you cannot switch back to monthly billing until your annual cycle has
## W-9 form requests
See Metabase's updated [W9 form](/files/2024_W9_signed.pdf).
See Metabase's updated [W9 form](https://www.metabase.com/files/2024_W9_signed.pdf).
## Update your Tax ID
@@ -109,7 +109,7 @@ The primary account holder should request a name change by emailing [billing@met
## Reset your Admin password
If you need to reset your Admin password, [contact support](/help-premium).
If you need to reset your Admin password, [contact support](https://www.metabase.com/help-premium).
## Change your company name
@@ -142,7 +142,7 @@ If you need to change your primary account holder, for example if your primary a
## Move from Metabase Cloud to self-hosting Metabase
If you're on Metabase Cloud but need to switch to hosting Metabase yourself, [contact us](/help-premium) and we'll give you a backup of your application database that you can use to restore Metabase on your own infrastructure.
If you're on Metabase Cloud but need to switch to hosting Metabase yourself, [contact us](https://www.metabase.com/help-premium) and we'll give you a backup of your application database that you can use to restore Metabase on your own infrastructure.
## Further reading

View File

@@ -10,7 +10,7 @@ layout: new-docs
# Metabase Cloud versus self-hosting
We have a post that goes into more depth on [why Metabase Cloud might be right for you](/blog/why-metabase-cloud), but here's a (nonexhaustive) table listing some of the differences between Metabase Cloud and self-hosting Metabase.
We have a post that goes into more depth on [why Metabase Cloud might be right for you](https://www.metabase.com/blog/why-metabase-cloud), but here's a (nonexhaustive) table listing some of the differences between Metabase Cloud and self-hosting Metabase.
| | Self-hosted OSS | Metabase Cloud |
| ------------------------------ | ----------------------------------- | ------------------ |
@@ -38,7 +38,7 @@ There are some cases where you _should_ self-host.
- You have some regulations that stipulate how you run your software (like HIPAA).
- You want to run a custom build of Metabase. That is, you’re running a fork of Metabase (OSS or the Enterprise/Pro version) so you can add your own customizations to the software, and you have the engineering resources to tank that level of overhead.
- You want to use a community or custom driver. We only support [official databases](../databases/connecting.md#connecting-to-supported-databases) on Metabase Cloud, because we need to be able to vouch for their quality and help you with problems in a production context.
- You need an air-gapped environment, usually for regulatory compliance, or if you’re running your own three-letter-agency… If you’re not sure if you need an air-gapped environment, you don’t need an air-gapped environment. If you do need an air-gap, we have an [air-gap offering as well](/product/air-gapping) (just not for Cloud, obviously).
- You need an air-gapped environment, usually for regulatory compliance, or if you’re running your own three-letter-agency… If you’re not sure if you need an air-gapped environment, you don’t need an air-gapped environment. If you do need an air-gap, we have an [air-gap offering as well](https://www.metabase.com/product/air-gapping) (just not for Cloud, obviously).
Otherwise, you're better off having us handle all of the overhead so you can focus on your business. The official support alone is probably worth it.
@@ -46,7 +46,7 @@ Otherwise, you're better off having us handle all of the overhead so you can foc
Metabase also has a paid version that ships with all of the bells and whistles (SSO, row-level permissions, customization, and a lot more). Plans with this version include:
- [Metabase Pro](/product/pro)
- [Metabase Enterprise](/product/enterprise)
- [Metabase Pro](https://www.metabase.com/product/pro)
- [Metabase Enterprise](https://www.metabase.com/product/enterprise)
You can self-host this paid version, or have have us host it for you on Metabase Cloud for no additional cost. We don't charge more because we believe you'll have such a better experience that it'll be easier for us to support you.

View File

@@ -19,18 +19,18 @@ When you sign up for a paid Metabase plan on our website, you can elect to pay i
Both billing frequencies include a flat monthly or annual payment, and bill additional [user accounts](#what-counts-as-a-user-account) each month on a prorated basis (or quarterly, if you're [paying by invoice](#how-invoicing-works-for-pro-plans)).
Companies with large number of users can talk to sales about our [Enterprise plan](/sales/), which includes more options and discounts.
Companies with large number of users can talk to sales about our [Enterprise plan](https://www.metabase.com/sales/), which includes more options and discounts.
## How monthly billing works
Though we bill you monthly, we calculate how much you owe each day. So, say you're on the [Starter plan](/pricing/). Your monthly bill would include:
Though we bill you monthly, we calculate how much you owe each day. So, say you're on the [Starter plan](https://www.metabase.com/pricing/). Your monthly bill would include:
- $85 flat payment for the month. This payment additionally covers the first five people who use your Metabase that month. If you have fewer than five people using your Metabase, your bill will still be $85 that month.
- Each additional person costs \$5, prorated for how many days their [accounts were available](#what-counts-as-a-user-account) that month. So if an account only existed for the last 10 days of your 30 day billing period, you'd only be charged for those 10 days, not for the full 30 days. Same goes if you deactivated an account prior to the end of the billing period, you'll only be charged for the days when the account was available for use during that billing period. Basically, you only ever pay for all accounts in your Metabase that haven't been deactivated yet.
## How annual billing works
Paying up front for a year will save you 10%. So, again let's use the [Starter plan](/pricing/) as an example. With annual billing, you will:
Paying up front for a year will save you 10%. So, again let's use the [Starter plan](https://www.metabase.com/pricing/) as an example. With annual billing, you will:
- Have an annual payment of $918. That payment additionally covers five user accounts. This flat payment is made up front; it's not billed monthly. If you have fewer than five accounts, you still pay $918 for the year.
- For each additional user account above those first five user accounts, you'll be billed at $54, prorated for the year. So, for example, if you start out with just the first five accounts that are included in the initial $918 annual payment, then decide to add another user account six months into your annual billing cycle, you'll only be charged $27 dollars for that account, as you'll only need to pay for the remaining six months. When the annual billing cycle repeats, you'll be charged $918 for the first five users, plus \$54 for that additional user (and any other additional users you've added in the interim).

View File

@@ -12,7 +12,7 @@ redirect_from:
# Limitation of Metabase Cloud
There are some limitations that could impact your migration to Metabase Cloud. These limitations apply to all [Metabase Cloud plans](/pricing/).
There are some limitations that could impact your migration to Metabase Cloud. These limitations apply to all [Metabase Cloud plans](https://www.metabase.com/pricing/).
## Metabase Cloud only supports official databases

View File

@@ -15,7 +15,7 @@ section: Migrate
Migration from Metabase Cloud to self-hosted will keep all of your questions, dashboards, people, settings --- everything in your existing Metabase.
To migrate, you'll need to [contact our success team](/help-premium) to get a snapshot of your Metabase's [application database](../../installation-and-operation/migrating-from-h2.md#metabases-application-database). This application database contains information about all the settings, questions, dashboards, models, users, etc from your Metabase Cloud instance. The application database is distinct from any of the databases you have connected to your Metabase. You'll need to host your own PostgreSQL database and import your data by restoring from this snapshot of your application database.
To migrate, you'll need to [contact our success team](https://www.metabase.com/help-premium) to get a snapshot of your Metabase's [application database](../../installation-and-operation/migrating-from-h2.md#metabases-application-database). This application database contains information about all the settings, questions, dashboards, models, users, etc from your Metabase Cloud instance. The application database is distinct from any of the databases you have connected to your Metabase. You'll need to host your own PostgreSQL database and import your data by restoring from this snapshot of your application database.
## Preparing to migrate from cloud to self-hosted
@@ -31,7 +31,7 @@ A self-hosted Metabase comes with a built-in H2 application database (H2 is a fi
We recommend using PostgreSQL as your application database, but you can use MySQL or MariaDB as well. Before starting the migration from Metabase Cloud, [configure the application database](../../installation-and-operation/configuring-application-database.md) for your self-hosted instance.
For more on why you should use PostgreSQL as your application database, check out [How to run Metabase in production](/learn/metabase-basics/administration/administration-and-operation/metabase-in-production).
For more on why you should use PostgreSQL as your application database, check out [How to run Metabase in production](https://www.metabase.com/learn/metabase-basics/administration/administration-and-operation/metabase-in-production).
### If you're on a Pro plan, you'll need to switch to a self-hosted Pro plan
@@ -42,7 +42,7 @@ If you're migrating from a Metabase Cloud Pro plan to a self-hosted Pro plan, yo
## How to migrate from Metabase Cloud to a self-hosted instance
1. **Request a snapshot of your application database** for your Metabase Cloud instance by [contacting our Success Engineering team](/help-premium).
1. **Request a snapshot of your application database** for your Metabase Cloud instance by [contacting our Success Engineering team](https://www.metabase.com/help-premium).
Currently, you can't generate the snapshot yourself. A Metabase Success Engineer will generate a snapshot for you and email a link to download your snapshot from the Metabase Store.

View File

@@ -67,7 +67,7 @@ Before executing the migration script, you may need to set the environment varia
The script will upload your application data to your new Metabase Cloud instance. If all goes well, the script will print `Done!`.
If anything goes sideways, follow any prompts the script outputs. If you're still stuck, [send us an email](/help/) and we'll help you troubleshoot.
If anything goes sideways, follow any prompts the script outputs. If you're still stuck, [send us an email](https://www.metabase.com/help/) and we'll help you troubleshoot.
## After migrating to Metabase Cloud

View File

@@ -52,7 +52,7 @@ Once the snapshot upload completes:
While Metabase prepping the migration, click on the **Go to Metabase Store** button to sign in to or set up your account.
Choose your plan: [Starter](/product/starter) or [Pro](/product/pro). You can choose monthly or annual billing (annual will save you 10%).
Choose your plan: [Starter](https://www.metabase.com/product/starter) or [Pro](https://www.metabase.com/product/pro). You can choose monthly or annual billing (annual will save you 10%).
Choose your deployment: you can specify your DNS alias and select your hosting region.
@@ -93,4 +93,4 @@ If you were self-hosting via a third-party, be sure to clean up and cancel any s
## Need help?
If you run into any trouble, just [send us an email](/help/).
If you run into any trouble, just [send us an email](https://www.metabase.com/help/).

View File

@@ -50,7 +50,7 @@ Current customers can add storage through the Metabase Store:
## Metabase Cloud Storage pricing
Pricing depends on how much data you need to store. See the Storage section on our [pricing page](/pricing/).
Pricing depends on how much data you need to store. See the Storage section on our [pricing page](https://www.metabase.com/pricing/).
## Increasing Metabase Cloud Storage

View File

@@ -69,7 +69,6 @@ config:
settings:
admin-email: null
aggregated-query-row-limit: null
ai-service-base-url: http://localhost:8000
allowed-iframe-hosts: |-
youtube.com,
youtu.be,
@@ -118,20 +117,8 @@ config:
db-connection-timeout-ms: 10000
db-query-timeout-minutes: 20
default-maps-enabled: true
disable-cors-on-localhost: false
download-row-limit: null
ee-ai-features-enabled: false
ee-embedding-model: Snowflake/snowflake-arctic-embed-l-v2.0
ee-embedding-model-dimensions: 1024
ee-embedding-provider: ai-service
ee-openai-api-base-url: https://api.openai.com
ee-openai-api-key: null
ee-openai-model: gpt-4-turbo-preview
ee-search-gate-max-batch-size: 512
ee-search-gate-write-timeout: 5
ee-search-indexer-exit-early-cold-duration: 30
ee-search-indexer-lag-tolerance-multiplier: 2
ee-search-indexer-max-run-duration: 60
ee-search-indexer-poll-limit: 1000
email-from-address: notifications@metabase.com
email-from-address-override: notifications@metabase.com
email-from-name: null
@@ -148,7 +135,7 @@ config:
email-smtp-username: null
email-smtp-username-override: null
embedding-app-origins-interactive: null
embedding-app-origins-sdk: localhost:*
embedding-app-origins-sdk: ''
embedding-homepage: hidden
embedding-secret-key: null
enable-embedding-interactive: false
@@ -221,7 +208,6 @@ config:
notification-link-base-url: null
notification-system-event-thread-pool-size: 5
notification-thread-pool-size: 3
openai-max-tokens-per-batch: 4000
persisted-model-refresh-cron-schedule: 0 0 0/6 * * ? *
persisted-models-enabled: false
premium-embedding-token: null
@@ -256,9 +242,6 @@ config:
sdk-encryption-validation-key: null
search-language: null
search-typeahead-enabled: true
semantic-search-enabled: true
semantic-search-min-results-threshold: 100
semantic-search-results-limit: 1000
send-email-on-first-login-from-new-device: true
send-new-sso-user-admin-email: null
session-cookie-samesite: lax
@@ -271,7 +254,6 @@ config:
show-homepage-data: true
show-homepage-xrays: true
show-metabase-links: true
show-metabot: true
show-static-embed-terms: true
site-locale: en
site-name: Metabase
@@ -282,7 +264,6 @@ config:
source-address-header: X-Forwarded-For
sql-jdbc-fetch-size: 500
ssh-heartbeat-interval-sec: 180
stale-index-retention-hours: 24
start-of-week: sunday
subscription-allowed-domains: null
surveys-enabled: true

View File

@@ -71,13 +71,6 @@ Maximum number of rows to return for aggregated queries via the API.
Must be less than 1048575. See also MB_UNAGGREGATED_QUERY_ROW_LIMIT.
### `MB_AI_SERVICE_BASE_URL`
- Type: string
- Default: `http://localhost:8000`
URL for the a AI Service.
### `MB_ALLOWED_IFRAME_HOSTS`
- Type: string
@@ -400,6 +393,15 @@ Timeout in minutes for databases query execution, both Metabase application data
Whether or not the default GeoJSON maps are enabled.
### `MB_DISABLE_CORS_ON_LOCALHOST`
- Type: boolean
- Default: `false`
- [Exported as](../installation-and-operation/serialization.md): `disable-cors-on-localhost`.
- [Configuration file name](./config-file.md): `disable-cors-on-localhost`
Prevents the server from sending CORS headers for requests originating from localhost.
### `MB_DOWNLOAD_ROW_LIMIT`
- Type: positive-integer
@@ -408,118 +410,6 @@ Whether or not the default GeoJSON maps are enabled.
Row limit in file exports excluding the header. Enforces 1048575 excluding header as minimum. xlsx downloads are inherently limited to 1048575 rows even if this limit is higher.
### `MB_EE_AI_FEATURES_ENABLED`
- Type: boolean
- Default: `false`
- [Configuration file name](./config-file.md): `ee-ai-features-enabled`
Enable AI features.
This feature is experimental.
### `MB_EE_EMBEDDING_MODEL`
- Type: string
- Default: `Snowflake/snowflake-arctic-embed-l-v2.0`
- [Configuration file name](./config-file.md): `ee-embedding-model`
Set the embedding model for the selected provider.
This feature is experimental.
### `MB_EE_EMBEDDING_MODEL_DIMENSIONS`
- Type: positive-integer
- Default: `1024`
- [Configuration file name](./config-file.md): `ee-embedding-model-dimensions`
Set the dimension size for the selected embedding model.
This feature is experimental.
### `MB_EE_EMBEDDING_PROVIDER`
- Type: string
- Default: `ai-service`
- [Configuration file name](./config-file.md): `ee-embedding-provider`
The embedding provider to use (:openai, :ollama, or :ai-service).
This feature is experimental.
### `MB_EE_OPENAI_API_BASE_URL`
- Type: string
- Default: `https://api.openai.com`
- [Configuration file name](./config-file.md): `ee-openai-api-base-url`
The OpenAI embeddings base URL used in Metabase Enterprise.
This feature is experimental.
### `MB_EE_OPENAI_API_KEY`
- Type: string
- Default: `null`
- [Configuration file name](./config-file.md): `ee-openai-api-key`
The OpenAI API Key used in Metabase Enterprise.
This feature is experimental.
### `MB_EE_OPENAI_MODEL`
- Type: string
- Default: `gpt-4-turbo-preview`
- [Configuration file name](./config-file.md): `ee-openai-model`
The OpenAI Model (e.g. 'gpt-4', 'gpt-3.5-turbo').
This feature is experimental.
### `MB_EE_SEARCH_GATE_MAX_BATCH_SIZE`
- Type: integer
- Default: `512`
The maximum number of documents that can be sent to `gate-documents!` without causing an error.
### `MB_EE_SEARCH_GATE_WRITE_TIMEOUT`
- Type: integer
- Default: `5`
Timeout of gate write statements in seconds. Used to determine lag tolerance of the indexer (see the metabase-enterprise.semantic-search.gate/poll) in conjunction with `ee-search-indexer-lag-tolerance-multiplier`.
### `MB_EE_SEARCH_INDEXER_EXIT_EARLY_COLD_DURATION`
- Type: integer
- Default: `30`
Number of seconds indexer should wait to see new data before yielding back to quartz.
### `MB_EE_SEARCH_INDEXER_LAG_TOLERANCE_MULTIPLIER`
- Type: integer
- Default: `2`
Multiplier for computation of metabase-enterprise.semantic-search.indexer/lag-tolerance. The formula is `ee-search-gate-write-timeout * ee-search-indexer-lag-tolerance-multiplier`.
### `MB_EE_SEARCH_INDEXER_MAX_RUN_DURATION`
- Type: integer
- Default: `60`
Number of minutes we expect to run the indexer loop for before yielding to quartz.
### `MB_EE_SEARCH_INDEXER_POLL_LIMIT`
- Type: integer
- Default: `1000`
Indexer poll limit.
### `MB_EMAIL_FROM_ADDRESS`
- Type: string
@@ -681,7 +571,7 @@ Allow these space delimited origins to embed Metabase interactive.
> Only available on Metabase [Pro](https://www.metabase.com/product/pro) and [Enterprise](https://www.metabase.com/product/enterprise) plans.
- Type: string
- Default: `localhost:*`
- Default: ``
- [Configuration file name](./config-file.md): `embedding-app-origins-sdk`
Allow Metabase SDK access to these space delimited origins.
@@ -1359,15 +1249,6 @@ If Metabase stops sending notifications like alerts, it may be because long-runn
queries are clogging the notification queue. You may be able to unclog the queue by
increasing the size of the thread pool dedicated to notifications.
### `MB_OPENAI_MAX_TOKENS_PER_BATCH`
- Type: integer
- Default: `4000`
The maximum number of tokens sent in a single embedding API call.
The maximum number of tokens sent in a single embedding API call.
### `MB_PERSISTED_MODEL_REFRESH_CRON_SCHEDULE`
- Type: string
@@ -1680,31 +1561,6 @@ When using the appdb engine against postgresql, override the language used for s
Enable typeahead search in the Metabase navbar?
### `MB_SEMANTIC_SEARCH_ENABLED`
- Type: boolean
- Default: `true`
Enable the semantic search engine? Intended as a kill switch for the semantic search feature while dogfooding.
### `MB_SEMANTIC_SEARCH_MIN_RESULTS_THRESHOLD`
- Type: integer
- Default: `100`
Minimum number of semantic search results required before falling back to other engines.
Minimum number of semantic search results required before falling back to other engines.
### `MB_SEMANTIC_SEARCH_RESULTS_LIMIT`
- Type: integer
- Default: `1000`
Maximum number of results to return from a single semantic search query.
Maximum number of results to return from a single semantic search query.
### `MB_SEND_EMAIL_ON_FIRST_LOGIN_FROM_NEW_DEVICE`
- Type: boolean
@@ -1823,17 +1679,6 @@ Whether or not to display x-ray suggestions on the homepage. They will also be h
Whether or not to display Metabase links outside admin settings.
### `MB_SHOW_METABOT`
> Only available on Metabase [Pro](https://www.metabase.com/product/pro) and [Enterprise](https://www.metabase.com/product/enterprise) plans.
- Type: boolean
- Default: `true`
- [Exported as](../installation-and-operation/serialization.md): `show-metabot`.
- [Configuration file name](./config-file.md): `show-metabot`
Enables Metabot character on the home page.
### `MB_SHOW_STATIC_EMBED_TERMS`
- Type: boolean
@@ -1934,15 +1779,6 @@ Fetch size for result sets. We want to ensure that the jdbc ResultSet objects ar
Controls how often the heartbeats are sent when an SSH tunnel is established (in seconds).
### `MB_STALE_INDEX_RETENTION_HOURS`
- Type: integer
- Default: `24`
Number of hours to retain stale semantic search indexes before cleanup.
Number of hours to retain stale semantic search indexes before cleanup.
### `MB_START_OF_WEEK`
- Type: keyword

View File

@@ -11,7 +11,7 @@ Metabase logs quite a bit of information by default. Metabase uses [Log4j 2](htt
## View and download Metabase logs
You can find Metabase logs in **Admin settings** > **Troubleshooting** > **Logs**. You can filter the logs by keywords (for example, "sync") and download them as a text file.
You can find Metabase logs in **Admin settings** > **Tools** > **Logs**. You can filter the logs by keywords (for example, "sync") and download them as a text file.
If you're running self-hosted Metabase, you'll also be able see the logs in the terminal.
@@ -25,7 +25,7 @@ Metabase uses [log4j](https://logging.apache.org/log4j/2.x/)for logging configur
### Temporary override logging configuration
To temporarily adjust the logging configuration, go to **Admin settings** > **Troubleshooting** > **Logs** and click on **Customize log levels**.
To temporarily adjust the logging configuration, go to **Admin settings** > **Tools** > **Logs** and click on **Customize log levels**.
You can select from log level presets for common troubleshooting tasks (for example, troubleshooting sync issues), or provide your own configuration as a JSON. For example, here's an override configuration that increases logging for troubleshooting linked filters:

View File

@@ -311,7 +311,7 @@ If your Metabase administrator has enabled [public sharing](../embedding/public-
![Share icon](./images/share-icon.png)
Public links can be viewed by anyone, even if they don't have access to Metabase. You can also use the public embedding code to embed your question or dashboard in a simple web page or blog post. Check out examples of simple apps with embedded dashboards in our [embedding-reference-apps repository](https://github.com/metabase/embedding-reference-apps). To learn more about [embedding](../embedding/introduction.md), check out our article on [How to use Metabase to deliver analytics to your customers](/learn/metabase-basics/embedding/overview), as well as an article on how to combine branding, Single Sign-On, full app embedding, and row and column security to deliver [multi-tenant, self-service analytics](https://www.metabase.com/learn/metabase-basics/embedding/multi-tenant-self-service-analytics).
Public links can be viewed by anyone, even if they don't have access to Metabase. You can also use the public embedding code to embed your question or dashboard in a simple web page or blog post. Check out examples of simple apps with embedded dashboards in our [embedding-reference-apps repository](https://github.com/metabase/embedding-reference-apps). To learn more about [embedding](../embedding/introduction.md), check out our article on [How to use Metabase to deliver analytics to your customers](https://www.metabase.com/learn/metabase-basics/embedding/overview), as well as an article on how to combine branding, Single Sign-On, full app embedding, and row and column security to deliver [multi-tenant, self-service analytics](https://www.metabase.com/learn/metabase-basics/embedding/multi-tenant-self-service-analytics).
## Exporting results from a dashboard

View File

@@ -16,6 +16,10 @@ Here you can [sync the database schema and rescan field values](../sync-scan.md)
You can edit these settings at any time (and remember to save your changes).
### Connection string
Paste a connection string here to pre-fill the remaining fields below.
### Display name
The display name for the database in the Metabase interface.

View File

@@ -44,6 +44,10 @@ Here you can [sync the database schema and rescan field values](../sync-scan.md)
You can edit these settings at any time. Just remember to save your changes.
### Connection string
Paste a connection string here to pre-fill the remaining fields below.
### Display name
The display name for the database in the Metabase interface.

View File

@@ -19,6 +19,10 @@ Here you can [sync the database schema and rescan field values](../sync-scan.md)
To access or modify your database connection settings, click the **Edit connection details** button.
### Connection string
Paste a connection string here to pre-fill the remaining fields below.
### Display name
The display name for the database in the Metabase interface.

View File

@@ -10,6 +10,10 @@ You can edit these settings at any time. Just remember to save your changes.
## Edit connection details
### Connection string
Paste a connection string here to pre-fill the remaining fields below.
### Display name
The display name for the database in the Metabase interface.

View File

@@ -12,6 +12,10 @@ To add a database connection, click on the **gear** icon in the top right, and n
Fill out the fields for that database, and click **Save changes** at the bottom. You can edit these settings at any time. Just remember to save your changes.
### Connection string
Paste a connection string here to pre-fill the remaining fields below.
### Display name
The display name for the database in the Metabase interface.

View File

@@ -18,6 +18,10 @@ Metabase supports the oldest supported version of Maria DB through the latest st
You can edit these settings at any time. Just remember to save your changes.
### Connection string
Paste a connection string here to pre-fill the remaining fields below.
### Display name
The display name for the database in the Metabase interface.

View File

@@ -18,6 +18,10 @@ Metabase supports the oldest supported version through the latest stable version
You can edit these settings at any time. Just remember to save your changes.
### Connection string
Paste a connection string here to pre-fill the remaining fields below.
### Display name
The display name for the database in the Metabase interface.

View File

@@ -16,6 +16,10 @@ Metabase supports the oldest supported version through the latest stable version
You can edit these settings at any time. Just remember to save your changes.
### Connection string
Paste a connection string here to pre-fill the remaining fields below.
### Display name
The display name for the database in the Metabase interface.

View File

@@ -30,6 +30,10 @@ Here you can [sync the database schema and rescan field values](../sync-scan.md)
You can edit these settings at any time. Just remember to save your changes.
### Connection string
Paste a connection string here to pre-fill the remaining fields below.
### Display name
The display name for the database in the Metabase interface.

View File

@@ -12,6 +12,10 @@ Fill out the fields for that database, and click **Save changes** at the bottom.
You can edit these settings at any time. Just remember to save your changes.
### Connection string
Paste a connection string here to pre-fill the remaining fields below.
### Display name
The display name for the database in the Metabase interface.

Some files were not shown because too many files have changed in this diff Show More