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 saved question picker with 2+ dbs #28496

Merged
merged 1 commit into from
Feb 21, 2023
Merged

Fix saved question picker with 2+ dbs #28496

merged 1 commit into from
Feb 21, 2023

Conversation

ranquild
Copy link
Contributor

@ranquild ranquild commented Feb 21, 2023

How to test:

  • Open http://localhost:3000/question/notebook#eyJjcmVhdGlvblR5cGUiOiJjdXN0b21fcXVlc3Rpb24iLCJkYXRhc2V0X3F1ZXJ5Ijp7ImRhdGFiYXNlIjpudWxsLCJxdWVyeSI6eyJzb3VyY2UtdGFibGUiOm51bGx9LCJ0eXBlIjoicXVlcnkifSwiZGlzcGxheSI6InRhYmxlIiwidmlzdWFsaXphdGlvbl9zZXR0aW5ncyI6e319
  • Click Saved Questions
  • It should show the saved question picker (currently it opens raw tables instead)

This change is Reviewable

@ranquild ranquild self-assigned this Feb 21, 2023
@ranquild ranquild requested a review from a team February 21, 2023 18:17
@ranquild ranquild merged commit b4f9b94 into master Feb 21, 2023
@ranquild ranquild deleted the saved-question-2-db branch February 21, 2023 18:31
@deploysentinel
Copy link

deploysentinel bot commented Feb 21, 2023

Current Cypress Test Results Summary

✅ 1494 Passing - ❌ 6 Failing - ⚠️ 9 Flaky

Run may still be in progress, this comment will be updated as current testing workflow or job completes...

(Last updated on 02/21/2023 07:25:47pm UTC)

Run Details

Running Workflow E2E Tests on Github Actions

Commit: 73a427933d056d6f4aad02957ab845f4e430c5d2

Started: 02/21/2023 06:57:23pm UTC

❌ Failures

📄   frontend/test/metabase/scenarios/visualizations/line-bar-tooltips.cy.spec.js • 3 Failures

Top 1 Common Error Messages

Timed out retrying after 4000ms: Expected to find element: `.popover[data-state~='visible']`, but never found it.

3 Test Cases Affected

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
scenarios > visualizations > line/bar chart > tooltips > single series question on dashboard with added series should show updated column titles in tooltips after editing them via Visualization Options
Retry 2Retry 1Initial Attempt
Error: Timed out retrying after 4000ms: Expected to find element: `.popover[data-state~...
Timed out retrying after 4000ms: Expected to find element: `.popover[data-state~='visible']`, but never found it.
10.28% (58) 58 / 564 runs
failed over last 7 days
0% (0) 0 / 564 runs
flaked over last 7 days
scenarios > visualizations > line/bar chart > tooltips > multi series question on dashboard with added question should show updated column titles in tooltips after editing them via Visualization Options
Retry 2Retry 1Initial Attempt
Error: Timed out retrying after 4000ms: Expected to find element: `.popover[data-state~...
Timed out retrying after 4000ms: Expected to find element: `.popover[data-state~='visible']`, but never found it.
10.28% (58) 58 / 564 runs
failed over last 7 days
0% (0) 0 / 564 runs
flaked over last 7 days
scenarios > visualizations > line/bar chart > tooltips > bar chart question on dashboard with added series should show updated column titles in tooltips after editing them via Visualization Options
Retry 2Retry 1Initial Attempt
Error: Timed out retrying after 4000ms: Expected to find element: `.popover[data-state~...
Timed out retrying after 4000ms: Expected to find element: `.popover[data-state~='visible']`, but never found it.
10.11% (57) 57 / 564 runs
failed over last 7 days
0% (0) 0 / 564 runs
flaked over last 7 days

📄   frontend/test/metabase/scenarios/question/reproductions/25144-saved-questions-first-question.cy.spec.js • 2 Failures

Top 1 Common Error Messages

Timed out retrying after 4000ms: Unable to find an element with the text: Orders. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

2 Test Cases Affected

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
issue 25144 should show Saved Questions section after creating the first question (#25144)
Retry 2Retry 1Initial Attempt
Error: Timed out retrying after 4000ms: Unable to find an element with the text: Orders...
Timed out retrying after 4000ms: Unable to find an element with the text: Orders. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, <script />, <style />
<span
  class="PopoverContainer PopoverContainer--open popover tether-element tether-abutted tether-abutted-left tether-element-attached-top tether-element-attached-left tether-target-attached-bottom tether-target-attached-left tether-enabled"
  data-state="visible"
  style="top: 0px; left: 0px; position: absolute; transform: translateX(48px) translateY(207px) translateZ(0px);"
>
  <span
    style="z-index: 3;"
  >
    <div
      class="PopoverBody PopoverBody--withBackground PopoverBody--autoWidth"
      id="DataPopover"
    >
      <div
        class="css-m1a2da e1g1denn0"
      >
        <div
          class="css-17sifsc edcfyzd6"
        >
          <input
            class="css-1mc41fo edcfyzd5"
            data-testid="list-search-field"
            placeholder="Search for a table…"
            value=""
          />
          <button
            class="css-j8wedt edcfyzd3"
            data-testid="input-left-icon-button"
            disabled=""
            type="button"
          >
            <svg
              aria-label="search icon"
              class="Icon Icon-search e621b520 css-1osrv6t e621b521"
              fill="currentcolor"
              height="16"
              role="img"
              viewBox="0 0 32 32"
              width="16"
            >
              <path
                d="M22.805 25.734c-5.582 4.178-13.543 3.718-18.632-1.37-5.58-5.581-5.595-14.615-.031-20.179 5.563-5.563 14.597-5.55 20.178.031 5.068 5.068 5.545 12.985 1.422 18.563l5.661 5.661a2.08 2.08 0 0 1 .003 2.949 2.085 2.085 0 0 1-2.95-.003l-5.651-5.652zm-1.486-4.371c3.895-3.895 3.885-10.218-.021-14.125-3.906-3.906-10.23-3.916-14.125-.021-3.894 3.894-3.885 10.218.022 14.124 3.906 3.907 10.23 3.916 14.124.022z"
              />
            </svg>
          </button>
        </div>
      </div>
      <div
        aria-label="grid"
        aria-readonly="true"
        class="ReactVirtualized__Grid ReactVirtualized__List text-brand"
        id="DatabaseSchemaPicker"
        role="grid"
        style="box-sizing: border-box; direction: ltr; height: 55px; position: relative; width: 300px; will-change: transform; overflow: hidden auto; outline: none;"
        tabindex="0"
      >
        <div
          class="ReactVirtualized__Grid__innerScrollContainer"
          role="rowgroup"
          style="width: auto; height: 55px; max-width: 300px; max-height: 55px; overflow: hidden; pointer-events: auto; position: relative;"
        >
          <div
            class="List-section List-section--expanded List-section--togglable"
            style="height: 55px; left: 0px; position: absolute; top: 0px; width: 100%;"
          >
            <div
              class="List-section-header px2 py2 flex align-center hover-parent hover--opacity cursor-pointer text-brand"
            >
              <span
                class="List-section-icon mr1 flex align-center"
              >
                <svg
                  aria-label="database icon"
                  class="Icon Icon-database Icon text-default e621b520 css-1osrv6t e621b521"
                  fill="currentcolor"
                  height="18"
                  role="img"
                  viewBox="0 0 32 32"
                  width="18"
                >
                  <path
                    d="M0 9.32V4.054S1.584 0 15.657 0C29.731 0 31.89 3.669 31.89 4.054v5.24s-1.445 4.125-15.424 4.125S0 10.138 0 9.32zm.305 12.93s2.044 3.692 15.727 3.692 15.63-3.72 15.63-3.72.338.099.338.632v5S30.463 32 15.964 32C1.465 32 .041 27.817.041 27.817V22.9c0-.582.264-.65.264-.65zm0-9.368s2.044 3.692 15.727 3.692 15.63-3.72 15.63-3.72.338.099.338.632v5.001s-1.537 4.145-16.036 4.145C1.465 22.632.041 18.45.041 18.45v-4.918c0-.583.264-.65.264-.65z"
                  />
                </svg>
              </span>
              <h3
                class="List-section-title text-wrap"
              >
                Sample Database
              </h3>
            </div>
          </div>
        </div>
      </div>
    </div>
  </span>
</span>
1.12% (6) 6 / 538 runs
failed over last 7 days
0% (0) 0 / 538 runs
flaked over last 7 days
issue 25144 should show Models section after creation the first model (#24878)
Retry 2Retry 1Initial Attempt
Error: Timed out retrying after 4000ms: Unable to find an element with the text: Orders...
Timed out retrying after 4000ms: Unable to find an element with the text: Orders. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, <script />, <style />
<span
  class="PopoverContainer PopoverContainer--open popover tether-element tether-abutted tether-abutted-left tether-element-attached-top tether-element-attached-left tether-target-attached-bottom tether-target-attached-left tether-enabled"
  data-state="visible"
  style="top: 0px; left: 0px; position: absolute; transform: translateX(48px) translateY(207px) translateZ(0px);"
>
  <span
    style="z-index: 3;"
  >
    <div
      class="PopoverBody PopoverBody--withBackground PopoverBody--autoWidth"
      id="DataPopover"
    >
      <div
        class="css-m1a2da e1g1denn0"
      >
        <div
          class="css-17sifsc edcfyzd6"
        >
          <input
            class="css-1mc41fo edcfyzd5"
            data-testid="list-search-field"
            placeholder="Search for a table…"
            value=""
          />
          <button
            class="css-j8wedt edcfyzd3"
            data-testid="input-left-icon-button"
            disabled=""
            type="button"
          >
            <svg
              aria-label="search icon"
              class="Icon Icon-search e621b520 css-1osrv6t e621b521"
              fill="currentcolor"
              height="16"
              role="img"
              viewBox="0 0 32 32"
              width="16"
            >
              <path
                d="M22.805 25.734c-5.582 4.178-13.543 3.718-18.632-1.37-5.58-5.581-5.595-14.615-.031-20.179 5.563-5.563 14.597-5.55 20.178.031 5.068 5.068 5.545 12.985 1.422 18.563l5.661 5.661a2.08 2.08 0 0 1 .003 2.949 2.085 2.085 0 0 1-2.95-.003l-5.651-5.652zm-1.486-4.371c3.895-3.895 3.885-10.218-.021-14.125-3.906-3.906-10.23-3.916-14.125-.021-3.894 3.894-3.885 10.218.022 14.124 3.906 3.907 10.23 3.916 14.124.022z"
              />
            </svg>
          </button>
        </div>
      </div>
      <div
        aria-label="grid"
        aria-readonly="true"
        class="ReactVirtualized__Grid ReactVirtualized__List text-brand"
        id="DatabaseSchemaPicker"
        role="grid"
        style="box-sizing: border-box; direction: ltr; height: 55px; position: relative; width: 300px; will-change: transform; overflow: hidden auto; outline: none;"
        tabindex="0"
      >
        <div
          class="ReactVirtualized__Grid__innerScrollContainer"
          role="rowgroup"
          style="width: auto; height: 55px; max-width: 300px; max-height: 55px; overflow: hidden; pointer-events: auto; position: relative;"
        >
          <div
            class="List-section List-section--expanded List-section--togglable"
            style="height: 55px; left: 0px; position: absolute; top: 0px; width: 100%;"
          >
            <div
              class="List-section-header px2 py2 flex align-center hover-parent hover--opacity cursor-pointer text-brand"
            >
              <span
                class="List-section-icon mr1 flex align-center"
              >
                <svg
                  aria-label="database icon"
                  class="Icon Icon-database Icon text-default e621b520 css-1osrv6t e621b521"
                  fill="currentcolor"
                  height="18"
                  role="img"
                  viewBox="0 0 32 32"
                  width="18"
                >
                  <path
                    d="M0 9.32V4.054S1.584 0 15.657 0C29.731 0 31.89 3.669 31.89 4.054v5.24s-1.445 4.125-15.424 4.125S0 10.138 0 9.32zm.305 12.93s2.044 3.692 15.727 3.692 15.63-3.72 15.63-3.72.338.099.338.632v5S30.463 32 15.964 32C1.465 32 .041 27.817.041 27.817V22.9c0-.582.264-.65.264-.65zm0-9.368s2.044 3.692 15.727 3.692 15.63-3.72 15.63-3.72.338.099.338.632v5.001s-1.537 4.145-16.036 4.145C1.465 22.632.041 18.45.041 18.45v-4.918c0-.583.264-.65.264-.65z"
                  />
                </svg>
              </span>
              <h3
                class="List-section-title text-wrap"
              >
                Sample Database
              </h3>
            </div>
          </div>
        </div>
      </div>
    </div>
  </span>
</span>
0.37% (2) 2 / 538 runs
failed over last 7 days
0% (0) 0 / 538 runs
flaked over last 7 days

📄   frontend/test/metabase/scenarios/question/reproductions/19341-disabled-nested-queries.cy.spec.js • 1 Failure

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
issue 19341 should correctly disable nested queries (#19341)
Retry 2Retry 1Initial Attempt
Error: Timed out retrying after 4000ms: Unable to find an element with the text: Orders...
Timed out retrying after 4000ms: Unable to find an element with the text: Orders. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible.

Ignored nodes: comments, <script />, <style />
<span
  class="PopoverContainer PopoverContainer--open popover tether-element tether-abutted tether-abutted-left tether-element-attached-top tether-element-attached-left tether-target-attached-bottom tether-target-attached-left tether-enabled"
  data-state="visible"
  style="top: 0px; left: 0px; position: absolute; transform: translateX(48px) translateY(207px) translateZ(0px);"
>
  <span
    style="z-index: 3;"
  >
    <div
      class="PopoverBody PopoverBody--withBackground PopoverBody--autoWidth"
      id="DataPopover"
    >
      <div
        class="css-m1a2da e1g1denn0"
      >
        <div
          class="css-17sifsc edcfyzd6"
        >
          <input
            class="css-1mc41fo edcfyzd5"
            data-testid="list-search-field"
            placeholder="Search for a table…"
            value=""
          />
          <button
            class="css-j8wedt edcfyzd3"
            data-testid="input-left-icon-button"
            disabled=""
            type="button"
          >
            <svg
              aria-label="search icon"
              class="Icon Icon-search e621b520 css-1osrv6t e621b521"
              fill="currentcolor"
              height="16"
              role="img"
              viewBox="0 0 32 32"
              width="16"
            >
              <path
                d="M22.805 25.734c-5.582 4.178-13.543 3.718-18.632-1.37-5.58-5.581-5.595-14.615-.031-20.179 5.563-5.563 14.597-5.55 20.178.031 5.068 5.068 5.545 12.985 1.422 18.563l5.661 5.661a2.08 2.08 0 0 1 .003 2.949 2.085 2.085 0 0 1-2.95-.003l-5.651-5.652zm-1.486-4.371c3.895-3.895 3.885-10.218-.021-14.125-3.906-3.906-10.23-3.916-14.125-.021-3.894 3.894-3.885 10.218.022 14.124 3.906 3.907 10.23 3.916 14.124.022z"
              />
            </svg>
          </button>
        </div>
      </div>
      <div
        aria-label="grid"
        aria-readonly="true"
        class="ReactVirtualized__Grid ReactVirtualized__List text-brand"
        id="DatabaseSchemaPicker"
        role="grid"
        style="box-sizing: border-box; direction: ltr; height: 55px; position: relative; width: 300px; will-change: transform; overflow: hidden auto; outline: none;"
        tabindex="0"
      >
        <div
          class="ReactVirtualized__Grid__innerScrollContainer"
          role="rowgroup"
          style="width: auto; height: 55px; max-width: 300px; max-height: 55px; overflow: hidden; pointer-events: auto; position: relative;"
        >
          <div
            class="List-section List-section--expanded List-section--togglable"
            style="height: 55px; left: 0px; position: absolute; top: 0px; width: 100%;"
          >
            <div
              class="List-section-header px2 py2 flex align-center hover-parent hover--opacity cursor-pointer text-brand"
            >
              <span
                class="List-section-icon mr1 flex align-center"
              >
                <svg
                  aria-label="database icon"
                  class="Icon Icon-database Icon text-default e621b520 css-1osrv6t e621b521"
                  fill="currentcolor"
                  height="18"
                  role="img"
                  viewBox="0 0 32 32"
                  width="18"
                >
                  <path
                    d="M0 9.32V4.054S1.584 0 15.657 0C29.731 0 31.89 3.669 31.89 4.054v5.24s-1.445 4.125-15.424 4.125S0 10.138 0 9.32zm.305 12.93s2.044 3.692 15.727 3.692 15.63-3.72 15.63-3.72.338.099.338.632v5S30.463 32 15.964 32C1.465 32 .041 27.817.041 27.817V22.9c0-.582.264-.65.264-.65zm0-9.368s2.044 3.692 15.727 3.692 15.63-3.72 15.63-3.72.338.099.338.632v5.001s-1.537 4.145-16.036 4.145C1.465 22.632.041 18.45.041 18.45v-4.918c0-.583.264-.65.264-.65z"
                  />
                </svg>
              </span>
              <h3
                class="List-section-title text-wrap"
              >
                Sample Database
              </h3>
            </div>
          </div>
        </div>
      </div>
    </div>
  </span>
</span>
0.37% (2) 2 / 539 runs
failed over last 7 days
0% (0) 0 / 539 runs
flaked over last 7 days

⚠️ Flakes

📄   frontend/test/metabase/scenarios/admin/settings/sso/saml.cy.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
scenarios > admin > settings > SSO > SAML should allow to reset saml settings
Retry 1Initial Attempt
0% (0) 0 / 540 runs
failed over last 7 days
0.56% (3) 3 / 540 runs
flaked over last 7 days

📄   frontend/test/metabase/scenarios/admin/troubleshooting/tasks.cy.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
scenarios > admin > troubleshooting > tasks pagination should work (#14636)
Retry 1Initial Attempt
0.55% (3) 3 / 541 runs
failed over last 7 days
67.47% (365) 365 / 541 runs
flaked over last 7 days

📄   frontend/test/metabase/scenarios/sharing/reproductions/20393-public-dashboard-nested-card-with-parameters.cy.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
issue 20393 should show public dashboards with nested cards mapped to parameters (#20393)
Retry 1Initial Attempt
0.19% (1) 1 / 538 run
failed over last 7 days
6.51% (35) 35 / 538 runs
flaked over last 7 days

📄   frontend/test/metabase/scenarios/visualizations/line-bar-tooltips.cy.spec.js • 2 Flakes

Top 1 Common Error Messages

null

2 Test Cases Affected

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
scenarios > visualizations > line/bar chart > tooltips > multi series question on dashboard should show updated column titles in tooltips after editing them via Visualization Options
Retry 1Initial Attempt
0% (0) 0 / 564 runs
failed over last 7 days
1.77% (10) 10 / 564 runs
flaked over last 7 days
scenarios > visualizations > line/bar chart > tooltips > bar chart question on dashboard should show updated column titles in tooltips after editing them via Visualization Options
Retry 1Initial Attempt
0.35% (2) 2 / 564 runs
failed over last 7 days
6.56% (37) 37 / 564 runs
flaked over last 7 days

📄   frontend/test/metabase/scenarios/dashboard/dashboard-management.cy.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
managing dashboard from the dashboard's edit menu curate access admin user should be able to change title and description
Retry 1Initial Attempt
1.39% (8) 8 / 574 runs
failed over last 7 days
3.66% (21) 21 / 574 runs
flaked over last 7 days

📄   frontend/test/metabase/scenarios/organization/moderation-collection.cy.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
collections types should display a badge next to official questions in regular dashboards
Retry 1Initial Attempt
0% (0) 0 / 539 runs
failed over last 7 days
0.37% (2) 2 / 539 runs
flaked over last 7 days

📄   frontend/test/metabase/scenarios/visualizations/bar_chart.cy.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
scenarios > visualizations > bar chart with x-axis series should gracefully handle removing filtered items, and adding new items to the end of the list
Retry 1Initial Attempt
0% (0) 0 / 563 runs
failed over last 7 days
0.36% (2) 2 / 563 runs
flaked over last 7 days

📄   frontend/test/metabase/scenarios/dashboard-filters/dashboard-filters-explicit-join.cy.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
scenarios > dashboard > filters should work properly when connected to the explicitly joined field
Retry 1Initial Attempt
3.67% (20) 20 / 545 runs
failed over last 7 days
6.42% (35) 35 / 545 runs
flaked over last 7 days

View Detailed Build Results


ranquild added a commit that referenced this pull request Feb 21, 2023
ranquild added a commit that referenced this pull request Feb 21, 2023
@ranquild ranquild mentioned this pull request Feb 21, 2023
EmmadUsmani pushed a commit that referenced this pull request Feb 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants