This project is mirrored from https://github.com/metabase/metabase.
Pull mirroring updated .
- Jun 20, 2022
-
-
Alexander Polyankin authored
-
metamben authored
Fix compilation of temporal arithmetic for BigQuery and Mongo 5+ * Mongo 4 doesn't support $dateAdd so the generated filters result in an exception. * Support adding field to interval too (time intervals were not allowed in the first place of an addition) * Support temporal arithmetic with more than two operands for Mongo
-
adam-james authored
* Audit Queries fall back to email when first/last names are nil The audit page displays user information, and one column is "Name". Since we now allow nil first/last names, this value can return as a single space character. Instead, I've changed `common/user-full-name` to fall back to returning the user's email address if they have no first/last name values. Additionally: - since names can be nil, I've added sort by email to some of the queries for the audit page - display names have been changed from "Name" to "Member" in several queries to better fit the fallback to email * Add a test to check that audit pages have proper name fallback * Try to get test passing in CI * Make query work in MySQL by coalescing 'null' to empty string
-
Alexander Polyankin authored
-
Alexander Polyankin authored
-
Nemanja Glumac authored
* Fix flake in repro for 16386 * Fix flake in repro for 22730
-
Dalton authored
-
Dalton authored
-
Nemanja Glumac authored
* Fix flakes in repro for 22227 * Remove redundant intercepts * Use `cy.button` selector * Remove ALL redundant intercepts
-
Nemanja Glumac authored
-
Nemanja Glumac authored
-
Nemanja Glumac authored
This reverts commit 8bf35e53.
-
Nemanja Glumac authored
* Do not run backend tests on unrelated changes * Set explicit frontend test paths Co-authored-by:
flamber <1447303+flamber@users.noreply.github.com> Co-authored-by:
flamber <1447303+flamber@users.noreply.github.com>
-
Nemanja Glumac authored
-
- Jun 18, 2022
-
-
Cam Saul authored
* Disallow `(str ...)` forms for `defsetting` description * Fix a handful of `(str (deferred-tru ...))` forms * Fix some cases of `(ex-info (deferred-tr* ...))` * Appease clj-kondo * Remove unused reference
-
- Jun 17, 2022
-
-
Natalie authored
-
Aleksandr Lesnenko authored
* override product voice * review
-
Ariya Hidayat authored
-
Natalie authored
-
Natalie authored
-
Aleksandr Lesnenko authored
-
Nemanja Glumac authored
-
Mahatthana (Kelvin) Nomsawadi authored
* Remove unused file * Fix user name not showing in admin audit * Fix receiving wrong prop name * Fix collection UI broken when showing editor's long email
-
Ariya Hidayat authored
-
- Jun 16, 2022
-
-
Cal Herries authored
* Remove extra whitespace in defendpoint * [ci nocache] Co-authored-by:
Luis Paolini <paoliniluis@gmail.com>
-
dpsutton authored
MBQL goes through a different path. This is only for native queries. Also the diff is huge. Ignoring whitespace shows a very modest diff: ```diff "month" {:unit-range month-range :to-period t/months} + "quarter" {:unit-range relative-quarter-range + :to-period (comp t/months (partial * 3))} "year" {:unit-range year-range :to-period t/years}}) ... "past2months~" {:end "2016-06-30", :start "2016-04-01"} "past13months" {:end "2016-05-31", :start "2015-05-01"} + "past2quarters" {:end "2016-03-31", :start "2015-10-01"} + "past2quarters~" {:end "2016-06-30", :start "2015-10-01"} "past1years" {:end "2015-12-31", :start "2015-01-01"} "past1years~" {:end "2016-12-31", :start "2015-01-01"} ``` Helpful Testing Strategies -------------------------- Sample DB ========= `select id, created_at from orders where {{created_at}}` and set a field filter of type "Date Filter" Custom Table ============ Create a table that has entries in the middle of each quarter. ```sql esting=# create table quarters (id serial primary key not null, description text, t timestamptz); CREATE TABLE testing=# insert into quarters (description, t) values ('Q1 2022', '2022-02-01'), ('Q2 2022', '2022-05-01'), ('Q3 2022', '2022-08-01'), ('Q4 2022', '2022-11-01'); INSERT 0 4 testing=# select * from quarters; id | description | t ----+-------------+------------------------ 1 | Q1 2022 | 2022-02-01 00:00:00-06 2 | Q2 2022 | 2022-05-01 00:00:00-05 3 | Q3 2022 | 2022-08-01 00:00:00-05 4 | Q4 2022 | 2022-11-01 00:00:00-05 (4 rows) ``` Before this change ------------------ > Cannot invoke "clojure.lang.IFn.invoke(Object)" because "to_period" is null (note, if you cannot reproduce this its because you haven't gotten https://github.com/metabase/metabase/pull/23346 in your local version which ensured errors always appear as errors on the frontend. java 11 has no message for NPE so the Frontend missed it was an error and displayed no results as if the query had succeeded) This was the case for the following scenarios: - "last1quarters" - "last1quarters~" - "thisquarter" - "next1quarters" - "next1quarters~" where the ~ means to include the current quarter. After this change ----------------- Running the queries against the custom table I made (current time is Jun 15, Q2) - "last1quarters": "Q1 2022" "February 1, 2022, 6:00 AM" - "last1quarters~": "Q1 2022" "February 1, 2022, 6:00 AM" | "Q2 2022" "May 1, 2022, 5:00 AM" - "thisquarter": "Q2 2022" "May 1, 2022, 5:00 AM" - "next1quarters" "Q3 2022" "August 1, 2022, 5:00 AM" - "next1quarters~": "Q2 2022" "May 1, 2022, 5:00 AM" | "Q3 2022" "August 1, 2022, 5:00 AM" And of course added tests into the matrix for the date parsing.
-
jkeys089 authored
* improved support for Google Cloud SQL * upgrade `postgres-socket-factory` and add license overrides * fix license check Co-authored-by:
Cam Saul <1455846+camsaul@users.noreply.github.com>
-
Braden Shepherdson authored
-
Dalton authored
* First pass at NumberWidget * Share styled components * Remove TokenField prop for now * Second pass * Add to ParameterValueWidget * Add placeholder text * Rename to NumberInputWidget * Only use new widget for field filter parameters for now * Fix placeholder * Fix button text * Fix placeholder text * Add unit tests * Fix type
-
Dalton authored
Fix unit tests Update name to match dashboard util fn name
-
Dalton authored
* refactor dashboard utils Fix e2e test * rmv unused arg
-
dpsutton authored
Want to return non-zero on unrecognized forms so that CI can indicate when forms are added that cannot be parsed. And example of a completely valid form of `trs` that we cannot identify with this code is ```clojure ;; from driver/util.clj (-> "Cycle detected resolving dependent visible-if properties for driver {0}: {1}" (trs driver cyclic-props) (ex-info {:type qp.error-type/driver :driver driver :cyclic-visible-ifs cyclic-props}) throw) ``` The string literal is threaded into the `trs` macro, so it validates correctly but we cannot identify the literal in tooling while making the pot file. Now output of bin/i18n/update-translation-template would be the following: ```shell ❯ ./update-translation-template [BABEL] Note: The code generator has deoptimised the styling of /Users/dan/projects/work/metabase/frontend/src/cljs/cljs.pprint.js as it exceeds the max of 500KB. [BABEL] Note: The code generator has deoptimised the styling of /Users/dan/projects/work/metabase/frontend/src/cljs/cljs-runtime/cljs.core.js as it exceeds the max of 500KB. [BABEL] Note: The code generator has deoptimised the styling of /Users/dan/projects/work/metabase/frontend/src/cljs/cljs.core.js as it exceeds the max of 500KB. ~/projects/work/metabase/bin/i18n ~/projects/work/metabase Warning: environ value /Users/dan/.sdkman/candidates/java/current for key :java-home has been overwritten with /Users/dan/.sdkman/candidates/java/17.0.1-zulu/zulu-17.jdk/Contents/Home SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder". SLF4J: Defaulting to no-operation (NOP) logger implementation SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details. Created pot file at ../../locales/metabase-backend.pot Found 1396 forms for translations Grouped into 1313 distinct pot entries Found 1 forms that could not be analyzed {:file "metabase/driver/util.clj", :line 362, :original (trs driver cyclic-props), :message nil} ❯ echo $? 1 ``` and we have an exit code of 1 so that https://github.com/metabase/metabase/blob/master/.github/workflows/i18n.yml will fail in CI.
-
Mahatthana (Kelvin) Nomsawadi authored
-
Ryan Laurie authored
* allow chevron click
-
Alexander Polyankin authored
-
Benoit Vinay authored
-
Howon Lee authored
Pursuant to #22967. Previously the notion of the identifier in json-query in postgres assumed a singular identifier at the top-level of the Identifier record. This is not always the case in complicated binning scenarios - the identifier could also just comprise an entire tree of Identifier record maps with the actual Identifier we're looking to turn into the JSON query in some leaf somewhere. Therefore, the json-query's determination of what the identifier is now walks that identifier record tree and replaces the identifiers that have JSON field semantics with the reification of ToSql from json-query. Previous attempt at solution hacked together something at the json-query level, changing the reification, but that only worked for one level down, instead of just walking the Identifier tree and therefore getting stuff at arbitrary tree depth. And we do get nontrivial tree depth in the bucketing in #22967.
-
Benoit Vinay authored
* Convert Action to TypeScript * Delete possible unused ActionClick * Misc in Action * Misc * Delete Action files
-
- Jun 15, 2022
-
-
adam-james authored
* JWT shared key can now be any string. Message to suggest 64char key * Remove util require * We can now pass nice, readable multiline strings to tru/trs macros So let's do that here :)
-
Nemanja Glumac authored
-