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: Use Home page in SPA #21006

Merged
merged 4 commits into from
Aug 18, 2022
Merged

fix: Use Home page in SPA #21006

merged 4 commits into from
Aug 18, 2022

Conversation

EugeneTorap
Copy link
Contributor

@EugeneTorap EugeneTorap commented Aug 7, 2022

SUMMARY

Move Welcome (Home) page into SPA. Use GenericLink for Welcome page.
If LOGO_TARGET_PATH is None we use React Link for it otherwise we html <a>

BEFORE

Screen.Recording.2022-08-07.at.17.32.47.mov

AFTER

Screen.Recording.2022-08-07.at.17.50.26.mov

TESTING 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 Aug 7, 2022

Codecov Report

Merging #21006 (a271843) into master (76d6a9a) will increase coverage by 0.82%.
The diff coverage is n/a.

❗ Current head a271843 differs from pull request most recent head c2703b3. Consider uploading reports for the commit c2703b3 to get more accurate results

@@            Coverage Diff             @@
##           master   #21006      +/-   ##
==========================================
+ Coverage   65.45%   66.27%   +0.82%     
==========================================
  Files        1770     1770              
  Lines       67539    67539              
  Branches     7185     7185              
==========================================
+ Hits        44207    44764     +557     
+ Misses      21493    20936     -557     
  Partials     1839     1839              
Flag Coverage Δ
hive 53.17% <ø> (?)
mysql 80.96% <ø> (?)
postgres 81.02% <ø> (?)
presto 53.07% <ø> (ø)
python 81.50% <ø> (+1.70%) ⬆️
sqlite 79.62% <ø> (ø)
unit 50.74% <ø> (ø)

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

Impacted Files Coverage Δ
superset-frontend/src/views/components/Menu.tsx 50.00% <ø> (ø)
superset/views/base.py 75.53% <ø> (ø)
superset/utils/core.py 90.23% <0.00%> (+0.11%) ⬆️
superset/security/manager.py 95.39% <0.00%> (+0.16%) ⬆️
superset/reports/commands/execute.py 91.41% <0.00%> (+0.37%) ⬆️
superset/views/core.py 75.60% <0.00%> (+0.45%) ⬆️
superset/db_engine_specs/base.py 88.43% <0.00%> (+0.48%) ⬆️
superset/common/query_object.py 94.38% <0.00%> (+0.51%) ⬆️
superset/connectors/sqla/models.py 90.32% <0.00%> (+0.52%) ⬆️
... and 32 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@EugeneTorap
Copy link
Contributor Author

Can we simplify Home page's path and use /home instead of /superset/welcome?
What do you think @michael-s-molina @kgabryje @stephenLYZ?

@EugeneTorap
Copy link
Contributor Author

Who knows how to fix such error in Menu.test.tsx:
Error: Uncaught [Error: Invariant failed: You should not use <Link> outside a <Router>]

@kgabryje
Copy link
Member

Can we simplify Home page's path and use /home instead of /superset/welcome? What do you think @michael-s-molina @kgabryje @stephenLYZ?

I'd rather not do it now to be honest... Last time we did that it turned out to be more problematic than we anticipated

@kgabryje
Copy link
Member

Who knows how to fix such error in Menu.test.tsx: Error: Uncaught [Error: Invariant failed: You should not use <Link> outside a <Router>]

Just add useRouter to render options, like

render(<Menu {...mockedProps} />, {
    useRouter: true,
});

Copy link
Member

@kgabryje kgabryje left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link
Member

@kgabryje kgabryje left a comment

Choose a reason for hiding this comment

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

image

Menu is missing from sql lab

@EugeneTorap EugeneTorap changed the title fix: Use Welcome page in SPA fix: Use Home page in SPA Aug 18, 2022
@kgabryje
Copy link
Member

/testenv up

@github-actions
Copy link
Contributor

@kgabryje Ephemeral environment spinning up at http://54.187.60.237:8080. Credentials are admin/admin. Please allow several minutes for bootstrapping and startup.

Copy link
Member

@kgabryje kgabryje left a comment

Choose a reason for hiding this comment

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

LGTM

@kgabryje kgabryje merged commit dcab326 into apache:master Aug 18, 2022
@github-actions
Copy link
Contributor

Ephemeral environment shutdown and build artifacts deleted.

@EugeneTorap EugeneTorap deleted the fix/use-welcome-page-in-spa branch August 18, 2022 18:01
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 2.1.0 and removed 🚢 2.1.3 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/L 🚢 2.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants