This project is mirrored from https://github.com/metabase/metabase.
Pull mirroring updated .
- Feb 11, 2021
-
-
Cam Saul authored
* "regex-match-first" and "replace" operators aren't safe against SQL injection DRIVER SPECIFIC CHANGES: Updating Redshift driver code to use parameterized search/replace patterns for :replace, and the result of running the QUOTE_LITERAL function on the raw string for :regex-match-first Updating Redshift driver version to latest Parameterizing pattern in Postgres version of :regex-match-first implementation TESTS: Adding new tests to string_extracts_test.clj for ensuring :replace and :regex-match-first work with single quotes in expressions, across all DB drivers supporting those features Adding ability to pass filter into test-string-extract helper, using that from new tests Fixing typo in name of test-replace * Fixing import order in namespace declaration Adding explicit group number param of 0 for Hive-like driver (since the default is 1), when calling regexp_extract * Remove trace logging in the new test Co-authored-by: Jeff Evans <jeff.evans@metabase.com>
-
- Jan 21, 2021
- Jan 20, 2021
-
-
Cam Saul authored
Co-authored-by: Tim Macdonald <tsmacdonald@gmail.com>
-
- Oct 26, 2020
-
-
Robert Roland authored
You must specify the location on any getQueryResults calls to BigQuery. It's supposed to be optional for anything but EU and US regions, but useast1 seems to require it. Fixes #13582 [ci bigquery]
- Oct 23, 2020
-
-
Cam Saul authored
Wait for initial query to be ready before paginating
-
Robert Roland authored
When pagination was added, we were requesting the first page before it was ready. This adds a job completion wait on the initial query before we start retrieving pages. Resolves #13582 [ci bigquery]
- Oct 22, 2020
-
-
Cam Saul authored
-
Cam Saul authored
-
Cam Saul authored
Merge new release script and 0.36.7 tag back into release-0.36.x
-
Cam Saul authored
-
Cam Saul authored
-
Cam Saul authored
-
Robert Roland authored
This changes *only* the CSV/JSON/XLSX downloads to use a HTTP 200 response code instead of a HTTP 202. Resolves #11974
-
Simon Belak authored
-
Paul Rosenzweig authored
-
dpsutton authored
-
- Oct 21, 2020
-
-
dpsutton authored
with assistance from https://github.com/plumatic/schema/issues/120 (the only particularly interesting bit beyond the obvious walk is to remove any "open" matchers and use the s/Any)
-
Robert Roland authored
* Add pagination within the BigQuery driver The BigQuery API has a specific method of pagination using a "page token" in a query result. Use this to retrieve the entire result set in a lazy fashion. Resolves #6960 [ci bigquery] * Fixed tests to work with new interface Added ability to use a service account json for BigQuery testing in development Still need to add a test specifically for pagination [ci bigquery] * Testing that pagination occurs Due to lack of metrics on calls made, a dynamic callback was added so that call counts can be tracked to indicate that pagination had occurred. Also, introduces a maximum row count to each BigQuery call. Leaving at an arbitrarily high number - 20,000. BigQuery will automatically stop at a max of 10 MB per page, regardless of this number, but the setting is used in tests to ensure what pagination is doing. [ci bigquery] * Clarify max-results as being per page indentation and other small review feedback [ci bigquery]
-
Simon Belak authored
-
Simon Belak authored
-
- Oct 19, 2020
-
-
Cam Saul authored
-
dpsutton authored
* Mark state fields by fingerprint fixes #2735 [ci drivers] * fix tests for pg, ns sort, and docstring lint * Expectations -> clojure.test * minor alignment in test * Allow fingerprint classifiers to override prev classifier special_type if another classifier threw on a special type due to name or the number of items in the collection, this should override it as it is introspecting values. States previously were marked ":type/State" based on the column name. Now use a fingerprinter looking for state names. Owing to the fact that there might be more things in the state column (US territory, canadian states, Washington DC, etc) lowered the threshold for recognizing a state column from 95% of values down to 70% of values. * Cleanup [ci drivers] - remark about original field in metadata - docstring on `can-edit-special-field?` - cleanup and check for string in `state?` - add tests that nils and other types don't break `state?` * Include test file
-
Robert Roland authored
Reduce maxWorkers count for jest, which should reduce how often we get ENOMEM errors in the frontend tests
-
Robert Roland authored
When your app db is H2, this test will fail with a NumberFormatException trying to parse the "not-an-integer" but the MySQL JDBC driver does not behave the same. It is sufficient to test exception conditions return a {} query description only under the H2 app-db, since it's a catch-all handler.
-
- Oct 16, 2020
-
-
Paul Rosenzweig authored
* catch query description errors and improve client error message * add test
-
Robert Roland authored
Update jetty version due to https://nvd.nist.gov/vuln/detail/CVE-2019-17638
-
Robert Roland authored
* Handle LocalDate values in Excel export Adds an additional handler for LocalDate objects and a graceful degradation of any other errors converting date/time objects to Java Instants. Resolves #13271 Resolves #10803 Resolves #13298 * adding a test case for the exceptional case We don't handle JapaneseDate objects internally, but they make a good example for what happens in an exceptional case in generating Excel files. * More updates for #10803 Making sure formatting to strings isn't enabled on CSV and XLSX exports on cards and datasets. Update formatting of the Excel document to handle the difference between dates and date-times. * card exports should not convert integers to strings * not working, but the general approach to reusing cell styles * Use a dynamic in the right place to hold CellStyles * appease the linter bots * refactor set-cell! duplication set the time on a LocalDate to midnight UTC, which truncates the decimal portion of a date-only object to 0 in Excel * replace reset! with swap! * appease the bikeshedder
-
Paul Rosenzweig authored
-
Cam Saul authored
* Convert metabase.query-processor-test.explicit-joins-test to new style * Backport test from #13317 * Enable test * Use "table - field" style for join aliases * Wow! Don't use table - field alias if they're basically the same thing! * Lint fixes
-
- Oct 15, 2020
-
-
Robert Roland authored
* Obfuscate database details in the APIs This will stop us from sending sensitive info (passwords, keys) via the API for authenticated administrators. Note that non-administrator users were never privvy to these fields. * Use cleaner form suggested by Cam * make sensitive field list a const
-
Kyle Doherty authored
* Fix tooltip sizing + document component (#555) * document Tooltip component * move styling to css, drop conditional based on w/c * set noSnapShotTest true since tooltips use popovers * remove max-width to fix issue with chart popover scrolling * add constrained prop to tooltip, turn off for charts * clearer prop name * only use smaller font on constrainedWidth tooltips
-
dpsutton authored
following template too closely with the `(parent-thunk)` call and forgot it was wrapped in its own thunk so i was calling it before we were using the result set.
-
- Oct 14, 2020
- Oct 13, 2020
-
-
Cam Saul authored
* Feature/postgres cypress tests (#13311) Add Postgress tests to Cypress test suite This commit is introducing a new feature by adding a possibility to test Postgress related issues. It adds an updated CI configuration that plays nice with [Docker QA database](https://github.com/metabase/metabase-qa ) (postgress-12). It also adds a few repros, listed below: * Add repro for #12762 * Add repro for #13263 (#13303) --- * Add an example for how to run metabase-qa postgres in CI * Add e2e test for adding/connecting PostgreSQL database (#13296) Co-authored-by: @dacort * Enable test for #13263 * Better error handling for API database list endpoint for invalid drivers * Backport auto-parse-filter-values middleware [ci all] * Parse integers to Longs [ci postgres] Co-authored-by: Nemanja Glumac <31325167+nemanjaglumac@users.noreply.github.com>
-
dpsutton authored
* Handle mysql YEAR column types (Fixes #13203) [ci drivers] - year columns are very small in the db. The tricky part is how the driver hands them back: either as shorts or as java.sql.Dates. Our standard trick of reading them right into the java.time.LocalDate doesn't work and we instead get the java.sql.Date (which the driver converts from the short internal representation) or the short if `yearIsDateType` is configured to false. It seems to be an open question if Metabase should always consume this as a Date. That seems most likely but I have no idea how often this comes up in practice. * Add typehints [ci drivers] * Consume metadata immediately when checking for YEAR mysql column don't want to access the metadata outside of a `jdbc/with-db-metadata` * Clean up logic for YEAR column types [ci drivers] the `:else` is actually bad syntax. And handle explicitly the nil case and the two types it can be from getObject * Mark YEAR as :type/Date, make tests more reliable column ordering was messing up testing, so ignore the PK and just select the YEAR column * Use `when-let` when checking YEAR column [ci drivers] * Add tests for `table-rows-sample` really just to appease the Book of Cam® for test coverage
-