Skip to content
Snippets Groups Projects
Unverified Commit bf3b25a6 authored by Simon Belak's avatar Simon Belak Committed by GitHub
Browse files

(re)Merge release 0.33.x into master (#10835)

* Don't fingerprint sensitive fields (#10776)
* Druid: fix day bucketing (#10782)
parent 392ceddf
No related branches found
No related tags found
No related merge requests found
......@@ -745,7 +745,7 @@
:minute-of-hour (extract:timeFormat "mm")
:hour (extract:timeFormat "yyyy-MM-dd'T'HH:00:00ZZ")
:hour-of-day (extract:timeFormat "HH")
:day (extract:timeFormat "yyyy-MM-ddZZ")
:day (extract:timeFormat "yyyy-MM-dd'T'00:00:00ZZ")
:day-of-week (extract:js "function (timestamp) {"
" var date = new Date(timestamp);"
" return date.getDay() + 1;"
......
......@@ -134,7 +134,7 @@
[:or
[:not (mdb/isa :special_type :type/PK)]
[:= :special_type nil]]
[:not= :visibility_type "retired"]
[:not-in :visibility_type ["retired" "sensitive"]]
(cons :or (versions-clauses))]})
([table :- i/TableInstance]
......
......@@ -39,7 +39,7 @@
[:or
[:not (mdb/isa :special_type :type/PK)]
[:= :special_type nil]]
[:not= :visibility_type "retired"]
[:not-in :visibility_type ["retired" "sensitive"]]
[:or
[:and
[:< :fingerprint_version 1]
......@@ -54,7 +54,7 @@
[:or
[:not (mdb/isa :special_type :type/PK)]
[:= :special_type nil]]
[:not= :visibility_type "retired"]
[:not-in :visibility_type ["retired" "sensitive"]]
[:or
[:and
[:< :fingerprint_version 2]
......@@ -76,7 +76,7 @@
[:or
[:not (mdb/isa :special_type :type/PK)]
[:= :special_type nil]]
[:not= :visibility_type "retired"]
[:not-in :visibility_type ["retired" "sensitive"]]
[:or
[:and
[:< :fingerprint_version 2]
......@@ -98,7 +98,7 @@
[:or
[:not (mdb/isa :special_type :type/PK)]
[:= :special_type nil]]
[:not= :visibility_type "retired"]
[:not-in :visibility_type ["retired" "sensitive"]]
[:or
[:and
[:< :fingerprint_version 4]
......@@ -200,6 +200,13 @@
3 #{:type/Float}}
{:base_type :type/Decimal, :fingerprint_version 1}))
;; field is sensitive
(expect
[default-stat-map false]
(field-was-fingerprinted?
{1 #{:type/Text}}
{:base_type :type/Text, :fingerprint_version 1, :visibility_type :sensitive}))
;; Make sure the `fingerprint!` function is correctly updating the correct columns of Field
(expect
......
......@@ -500,11 +500,11 @@
;;; date bucketing - default (day)
(tqp.test/expect-with-timeseries-dbs
{:columns ["timestamp" "count"]
:rows [["2013-01-03+00:00" 1]
["2013-01-10+00:00" 1]
["2013-01-19+00:00" 1]
["2013-01-22+00:00" 1]
["2013-01-23+00:00" 1]]}
:rows [["2013-01-03T00:00:00+00:00" 1]
["2013-01-10T00:00:00+00:00" 1]
["2013-01-19T00:00:00+00:00" 1]
["2013-01-22T00:00:00+00:00" 1]
["2013-01-23T00:00:00+00:00" 1]]}
(qp.test/rows+column-names
(data/run-mbql-query checkins
{:aggregation [[:count]]
......@@ -577,11 +577,11 @@
;;; date bucketing - day
(tqp.test/expect-with-timeseries-dbs
{:columns ["timestamp" "count"]
:rows [["2013-01-03+00:00" 1]
["2013-01-10+00:00" 1]
["2013-01-19+00:00" 1]
["2013-01-22+00:00" 1]
["2013-01-23+00:00" 1]]}
:rows [["2013-01-03T00:00:00+00:00" 1]
["2013-01-10T00:00:00+00:00" 1]
["2013-01-19T00:00:00+00:00" 1]
["2013-01-22T00:00:00+00:00" 1]
["2013-01-23T00:00:00+00:00" 1]]}
(qp.test/rows+column-names
(data/run-mbql-query checkins
{:aggregation [[:count]]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment