This project is mirrored from https://github.com/metabase/metabase.
Pull mirroring updated .
- Apr 27, 2022
-
-
Noah Moss authored
* scaffolding, docstring & arg parsing * tweaks * registry and basic oss->ee dispatch * stubbed defenterprise-ee * full defenterprise-ee impl * fix build and tweak docstring * remove debug code * basic tests * use defonce * support for :any feature * schema support * fix schema test * switch to using format * support for schema on return val * tweak macro * move schema validation to submacros * do ee fn resolution at runtime * do conditionals at macro-expansion time * adjust semantics & refactor * fix test * add memoization for ee resolution * fix tests * emit register-mapping! call to avoid eval * call starts-with on symbol * remove schema support * use spec for arg parsing, generate fns, and remove :error fallback option * clean ns * change schema alias to schema * add :arglists meta and small refactor * refactor * move EE logic to fn * validate that the correct args are passed in EE/OSS namespaces, and make :feature required * remove logic for handling nil :feature * fix lint errors * fix ee macros * defenterprise-schema macro & tests * clean ns * propogate metadata * don't memoize ee resolution in dev to make debugging easier * dont do ee fn resolution during macroexpansion * migrate LDAP functions to defenterprise * lint * require ee ns separately so that EE settings are available * revert change to function mocked in tests * add back code lost in merge * clean ns * clean ns again * minor refactor and cleanup * major refactor * fix defenterprise-schema syntax * fix import * major refactor * update docstrings * more docstring tweaks * try to fix lint error on ldap PR * add lint-as mappings for defenterprise and defenterprise-schema to clj-kondo config * clj-kondo/ignore use of spec alias * use destructuring in arg lists since it's now supported * add docstring to def emitted by macro, and some formatting tweaks
-
Case Nelson authored
* Validate datasets are found when checking bigquery Fixes #19709 * Address PR feedback Made a general mechanism to pass expected messages to users in api/database via ex-info. This allows us to suppress logging for "unexceptional" exceptions that one can expect to hit while setting up drivers. * Only validate when filters are set Also removed the dataset list from the exception as it's not surfaced to users.
-
Noah Moss authored
* scaffolding, docstring & arg parsing * tweaks * registry and basic oss->ee dispatch * stubbed defenterprise-ee * full defenterprise-ee impl * fix build and tweak docstring * remove debug code * basic tests * use defonce * support for :any feature * schema support * fix schema test * switch to using format * support for schema on return val * tweak macro * move schema validation to submacros * do ee fn resolution at runtime * do conditionals at macro-expansion time * adjust semantics & refactor * fix test * add memoization for ee resolution * fix tests * emit register-mapping! call to avoid eval * call starts-with on symbol * remove schema support * use spec for arg parsing, generate fns, and remove :error fallback option * clean ns * change schema alias to schema * add :arglists meta and small refactor * refactor * move EE logic to fn * validate that the correct args are passed in EE/OSS namespaces, and make :feature required * remove logic for handling nil :feature * fix lint errors * fix ee macros * defenterprise-schema macro & tests * clean ns * propogate metadata * don't memoize ee resolution in dev to make debugging easier * dont do ee fn resolution during macroexpansion * minor refactor and cleanup * major refactor * update docstrings * more docstring tweaks * try to fix lint error on ldap PR * use dan's suggestion
-
Bryan Maass authored
-
Case Nelson authored
-
- Apr 26, 2022
-
-
Nick Fitzpatrick authored
* Remove right click option when unable to write to collections * Permissions for snippets root requires :namespace key on the collection * pr feedback Co-authored-by:
Case Nelson <case@metabase.com>
-
dpsutton authored
``` ❯ clj-kondo --lint src:shared/src src/metabase/api/common/validation.clj:2:33: warning: Inconsistent alias. Expected str instead of string. src/metabase/api/database.clj:664:5: warning: Redundant let expression. src/metabase/api/table.clj:18:45: warning: Inconsistent alias. Expected field-values instead of sync.field-values. src/metabase/cmd.clj:123:5: warning: unused binding docs src/metabase/db/data_migrations.clj:15:52: warning: Inconsistent alias. Expected perms-group instead of group. src/metabase/db/data_migrations.clj:55:15: warning: #'metabase.db.data-migrations/data-migrations is deprecated src/metabase/db/data_migrations.clj:62:24: warning: #'metabase.db.data-migrations/data-migrations is deprecated src/metabase/db/data_migrations.clj:63:7: warning: #'metabase.db.data-migrations/run-migration-if-needed! is deprecated src/metabase/db/data_migrations.clj:154:1: warning: #'metabase.db.data-migrations/defmigration is deprecated src/metabase/db/data_migrations.clj:201:1: warning: #'metabase.db.data-migrations/defmigration is deprecated src/metabase/db/setup.clj:59:5: warning: Missing catch or finally in try src/metabase/driver/postgres.clj:18:63: warning: Inconsistent alias. Expected sql-jdbc.describe-table instead of sql-jdbc.sync.describe-table. src/metabase/driver/postgres.clj:304:9: warning: unused binding nfc-path src/metabase/driver/postgres.clj:323:60: warning: unused binding fields-fields src/metabase/driver/sql_jdbc/sync/describe_table.clj:253:39: error: Expected: set or nil, received: seq. src/metabase/driver/sql_jdbc/sync/describe_table.clj:254:39: error: Expected: set or nil, received: seq. src/metabase/driver/sql_jdbc/sync/describe_table.clj:333:11: warning: unused binding map-inner src/metabase/models/secret.clj:248:23: warning: use :else as the catch-all test expression in cond src/metabase/pulse/render/body.clj:216:64: warning: unused binding cols src/metabase/task/refresh_slack_channel_user_cache.clj:52:25: error: clojurewerkz.quartzite.schedule.simple/with-interval-in-seconds is called with 1 arg but expects 2 linting took 5988ms, errors: 3, warnings: 17 ``` ``` ❯ clj-kondo --lint src:shared/src src/metabase/task/refresh_slack_channel_user_cache.clj:52:25: error: clojurewerkz.quartzite.schedule.simple/with-interval-in-seconds is called with 1 arg but expects 2 linting took 5270ms, errors: 1, warnings: 0 ``` Want to call out a few things: The following all related to the new paths into json feature. Wanted howon to verify that nothing got dropped with these unused bindings. ``` src/metabase/driver/postgres.clj:304:9: warning: unused binding nfc-path src/metabase/driver/postgres.clj:323:60: warning: unused binding fields-fields src/metabase/driver/sql_jdbc/sync/describe_table.clj:253:39: error: Expected: set or nil, received: seq. src/metabase/driver/sql_jdbc/sync/describe_table.clj:254:39: error: Expected: set or nil, received: seq. src/metabase/driver/sql_jdbc/sync/describe_table.clj:333:11: warning: unused binding map-inner ```
-
Bryan Maass authored
* explain what is going on during encryption key rotation * better argument error handling for commands
-
metamben authored
Deserialize dashboard Starting From/Exclude datetime filters
-
- Apr 25, 2022
-
-
Howon Lee authored
Parsed JSON columns should turn into detail-view only if (and only if) they are initially synced for table: already visible JSON columns shouldn't magically go away because people don't like already visible stuff just magically going away.
-
Bryan Maass authored
- if a keyword has namespace, send json encoded string: "ns/key" otherwise "key"
-
Ariya Hidayat authored
-
- Apr 23, 2022
-
-
Ngoc Khuat authored
* Fall back to Card's description if it's not exists when send subscription email * fix ns * use card from arg instead of fetching from DB * Update src/metabase/pulse/render.clj Co-authored-by:
Noah Moss <32746338+noahmoss@users.noreply.github.com> Co-authored-by:
Noah Moss <32746338+noahmoss@users.noreply.github.com>
-
- Apr 22, 2022
-
-
Cam Saul authored
* Handle March 31st + 3 months for Oracle (#10072) * Optimize out some casting in Oracle * rx util support varargs inside `opt` * hx/ math operators like + and - should propagate type information * Some dox tweaks * Fix SQLite busted behavior * Avoid unneeded casting in Vertica when adding temporal intervals * Lint error fixes * BigQuery fix for #21969 * Add testing context for tests for #21968 and #21971
-
Bryan Maass authored
* add implementations of write-body-to-stream for numbers / booleans * add tests for getting non-string settings over the api * remove blank line from end of api/segment.clj
-
Ngoc Khuat authored
* Make /api/user works with Group manager * add tests * fix linting * hope clj-kondo is happpy now * update docs * nit * GET /api/user/:id returns user_group_memberships and allow group manager * return additional fields if caller is Group Manager * fix ns * use set instead of list in tests * POST /api/user/:id takes user_group_memberships too * address Noah's comments * typo * sort by superuser -> group managers -> normal user when filter by group-id * FE: Group managers (#21111) * group managers ui * update specs * review * review * fix merge Co-authored-by:
Alexander Lesnenko <alxnddr@users.noreply.github.com> Co-authored-by:
Aleksandr Lesnenko <alxnddr@gmail.com>
-
Bryan Maass authored
- search qp will search for a substring - prefix qp works as it used to (searches for a prefix) - if both are included, prefer search.
-
Noah Moss authored
* refactor markdown->slack code to use a multimethod * solve nested bold & italic issue * fix docstring position * fix tests * restore a couple of comments * replace mrkdwn with slack in tests
-
dpsutton authored
* Allow strings to be empty in metadata not sure why it originally required a nil or a non-blank string. But when you want to override a description and clear it out, the front-end text boxes will send over an empty string "". This value is useful on its own though. Particularly in mbql queries or in native models where you've identified an underlying field, it will merge the metadata of the underlying field with the metadata of the model. So if we keep a nil there the underlying can show up. Especially for mbql queries, where you have the underlying description to begin with, you clear it out and then it appears to remain. Because of this merging. Using an affirmative "" empty string value prevents the merge and we all are happy * Lets also fix #11097 while we're near not identical, but same problem enforced at the route rather than some schema though * Unneeded thread macro
-
Cam Saul authored
-
Bryan Maass authored
* make sure we pass :port when creating ssh tunnels - if it is not there, use the default port * pass a default :port every time we incorporate-ssh-tunnel-details * Update src/metabase/driver/sql_jdbc/connection.clj remove unused port destructuring Co-authored-by:
Braden Shepherdson <Braden.Shepherdson@gmail.com> Co-authored-by:
Braden Shepherdson <Braden.Shepherdson@gmail.com>
-
Howon Lee authored
Group-bys didn't work because you need two instances of the field and you couldn't have two instances of the field be considered by the postgres backend as the same. Ported over the BigQuery fix to this to apply to JSON columns as well.
-
Howon Lee authored
Top-level array doesn't behave well, so get the transducer to ignore it until we come back around to it
-
- Apr 21, 2022
-
-
Noah Moss authored
Allow users with block perms to still use the `rescan_values` APIs if they have DB details or data model perms (#21808)
-
Braden Shepherdson authored
The frontend doesn't currently use this value.
-
- Apr 20, 2022
-
-
Cam Saul authored
-
Ryan Laurie authored
-
- Apr 19, 2022
-
-
Braden Shepherdson authored
* Make namespace aliasing consistent everywhere; enforce with clj-kondo See the table of aliases in .clj-kondo/config.edn Notable patterns: - `[metabase.api.foo :as api.foo]` - `[metabase.models.foo :as foo]` - `[metabase.query-processor.foo :as qp.foo]` - `[metabase.server.middleware.foo :as mw.foo]` - `[metabase.util.foo :as u.foo]` - `[clj-http.client :as http]` and `[metabase.http-client :as client]` Fixes #19930.
-
Case Nelson authored
-
- Apr 18, 2022
-
-
Noah Moss authored
* fix DB perm enforcement for users without data perms * update table perm checks * fix output of helper fn * revise approach * fix table read path * remove blank line * refactor and cleanup * syntax fix * add tests * fix test * another test * typo * fix more tests * make perm test helper more robust to fix final test failures * clean ns * grant read perms for a DB if a user has only data model perms, using a special :data-model perms object set * Revert "grant read perms for a DB if a user has only data model perms, using a special :data-model perms object set" This reverts commit f6cb724e513f6be5a26bc7252ffea30c192dfc8b. * change exclude-uneditable-data-model? to include-editable-data-model? * also adjust behavior & flag on /api/database/:id/metadata * update FE data model flags * one more datamodel fe query param * also add include_editable_data_model flag to /api/database/:id * a couple of more places for new query params * add include_editable_data_model query parameter to data model page requests * fix variable name * docstring fixes * fix test helper * fix perm check in /api/database/:id * try to fix cypress test Co-authored-by:
Aleksandr Lesnenko <alxnddr@gmail.com>
-
Bryan Maass authored
* fixes (#20938) by limiting embed previews to 2000 - (so they load faster) * adds test for (#20938) * add comment to the test for (#20938) * Update test/metabase/api/preview_embed_test.clj Co-authored-by:
Cam Saul <1455846+camsaul@users.noreply.github.com> * respond to code review - yoda condition get rid of by using = and not= - use mt/rows ! - don't hardcode table ids - remove magic 2000 number (this helped with the test) * include metabase.api.preview-embed ns in test * fix ns ordering in test Co-authored-by:
Cam Saul <1455846+camsaul@users.noreply.github.com>
-
Case Nelson authored
-
metamben authored
Fixes https://github.com/metabase/metabase/issues/17495.
-
Ngoc Khuat authored
-
Maz Ameli authored
* change the General permissions to Application * rename general permissions to application permissions * BE: Rename General Perms to Application Perms (#21709) * BE: Change General Perms to Application Perms * lint migration file * add migration to update seq name * update application perms graph endpoint in fe Co-authored-by:
Aleksandr Lesnenko <alxnddr@gmail.com> Co-authored-by:
Ngoc Khuat <qn.khuat@gmail.com>
-
- Apr 15, 2022
-
-
metamben authored
-
Ngoc Khuat authored
* add is_group_manager and hydrate it * update test title * fix namespaces and 1 test * update docstring and make sure the is-group-manager? is converted to boolean in any db * even more docstring * fix ns * Fix a test appeared when merge with master * add tests and more api enforcement * appease linter and make sure the test can run in ee * update by membership id * one dot * update docs * make is_group_manager optional * hydrate is_group_manager when get single group * - Split the `check-group-manager` into 2 functions - Address Noah's comments * Update enterprise/backend/test/metabase_enterprise/advanced_permissions/api/group_manager_test.clj Co-authored-by:
Noah Moss <32746338+noahmoss@users.noreply.github.com> * change is_group_manager in to bool instead of boolstring * remove debug code Co-authored-by:
Noah Moss <32746338+noahmoss@users.noreply.github.com>
-
- Apr 14, 2022
-
-
Braden Shepherdson authored
Fix test failure caused by floating point variance between devices Cause is unclear - M1 Macs, different JVM versions? Rounding to 6 significant figures sidesteps the issue.
-
Ngoc Khuat authored
-
Ngoc Khuat authored
* disallow adding recipients by non-admins with monitoring permission * enforce sharing and embedding apis * enforce update monitoring perms for alert, pulse and tasks API * add minor test cases * remove debug code * linting * fix not able to remove users from pulse and make sure our tests cover that case * address Noah's comments * one space
-