Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Inclusive sign in time range display #16906

Merged
merged 2 commits into from
Sep 30, 2021

Conversation

michael-s-molina
Copy link
Member

SUMMARY

Fixes #16882

@junlincc @jinghua-qa

AFTER SCREENSHOTS OR ANIMATED GIF

Screen.Recording.2021-09-29.at.3.30.16.PM.mov

TESTING INSTRUCTIONS

Check the original issue for instructions.

ADDITIONAL INFORMATION

  • Has associated issue:
  • Required feature flags:
  • Changes UI
  • Includes DB Migration (follow approval process in SIP-59)
    • Migration is atomic, supports rollback & is backwards-compatible
    • Confirm DB migration upgrade and downgrade tested
    • Runtime estimates and downtime expectations provided
  • Introduces new feature or API
  • Removes existing feature or API

@codecov
Copy link

codecov bot commented Sep 29, 2021

Codecov Report

Merging #16906 (dbb4a14) into master (4da4fe4) will decrease coverage by 0.01%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #16906      +/-   ##
==========================================
- Coverage   77.02%   77.01%   -0.02%     
==========================================
  Files        1022     1021       -1     
  Lines       54857    54849       -8     
  Branches     7482     7481       -1     
==========================================
- Hits        42256    42241      -15     
- Misses      12354    12361       +7     
  Partials      247      247              
Flag Coverage Δ
javascript 71.10% <ø> (-0.04%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...onfigModal/FiltersConfigForm/FiltersConfigForm.tsx 73.83% <ø> (ø)
...d/src/filters/components/Time/TimeFilterPlugin.tsx 86.66% <ø> (ø)
...ersConfigModal/FiltersConfigForm/DatasetSelect.tsx 48.48% <0.00%> (-36.37%) ⬇️
...erset-frontend/src/SqlLab/components/ResultSet.tsx 61.94% <0.00%> (-1.42%) ⬇️
superset-frontend/src/api/dataset.ts
...eFilters/FiltersConfigModal/FiltersConfigModal.tsx 89.42% <0.00%> (+0.96%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4da4fe4...dbb4a14. Read the comment docs.

@@ -321,7 +321,8 @@ test('validates the pre-filter value', async () => {
).toBeInTheDocument();
});

test("doesn't render time range pre-filter if there are no temporal columns in datasource", async () => {
// eslint-disable-next-line jest/no-disabled-tests
test.skip("doesn't render time range pre-filter if there are no temporal columns in datasource", async () => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @michael-s-molina just out of curiosity, what's the reason for skipping this test?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For a time now I have noticed that this test is failing every now and then. So I'm disabling it until we fix it.

Copy link
Member

@villebro villebro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - one small proposal to ensure uniformity going forward

@@ -1035,6 +1035,7 @@ const FiltersConfigForm = (
>
<DateFilterControl
name="time_range"
endpoints={['inclusive', 'exclusive']}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you think it would make sense placing DEFAULT_TIME_RANGE_ENDPOINTS = ['inclusive', 'exclusive'] under src/constants.ts and then using that here and on the other place?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems more like the default value of endpoints in DateFilterControl than a global thing.

@michael-s-molina michael-s-molina merged commit 3d520f2 into apache:master Sep 30, 2021
@michael-s-molina michael-s-molina added this to In progress in Native dashboard filters via automation Sep 30, 2021
@michael-s-molina michael-s-molina moved this from In progress to Done in Native dashboard filters Sep 30, 2021
opus-42 pushed a commit to opus-42/incubator-superset that referenced this pull request Nov 14, 2021
* fix: Time range display to show inclusive range

* Skips flakky test
QAlexBall pushed a commit to QAlexBall/superset that referenced this pull request Dec 28, 2021
* fix: Time range display to show inclusive range

* Skips flakky test
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.4.0 labels Mar 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels size/XS 🚢 1.4.0
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

[Native_filter]actual time range display inclusive vs. exclusive
4 participants