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(admin): if were in EE mode wait for the EE routes to be loaded before rendering #20238

Merged
merged 1 commit into from May 1, 2024

Conversation

joshuaellis
Copy link
Member

@joshuaellis joshuaellis commented May 1, 2024

What does it do?

  • if we're in EE the routes variable will be an array not null, if that's the case we wait for the routes to be loaded (which is not feature specific) before trying to re-render the app after being redirected from admin/connect/PROVIDER to admin/login/success because the component would not be ready to handle it & therefore the redirect will never complete

Why is it needed?

  • You can't login with SSO at the moment

How to test it?

Experimental: 0.0.0-experimental.ccba4ea6043b6bab83888f85cc9a3f07f61dc262

Related issue(s)/PR(s)

@joshuaellis joshuaellis added source: core:admin Source is core/admin package pr: fix This PR is fixing a bug labels May 1, 2024
@joshuaellis joshuaellis self-assigned this May 1, 2024
Copy link

vercel bot commented May 1, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
contributor-docs ❌ Failed (Inspect) May 1, 2024 9:09am

@joshuaellis joshuaellis changed the base branch from develop to releases/4.24.1 May 1, 2024 09:15
@joshuaellis joshuaellis added this to the 4.24.1 milestone May 1, 2024
Copy link
Contributor

@jhoward1994 jhoward1994 left a comment

Choose a reason for hiding this comment

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

Works for me with GH 🚀

Copy link
Member

@derrickmehaffy derrickmehaffy left a comment

Choose a reason for hiding this comment

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

Tested locally and it works for both the error screen and the normal login. It won't redirect to a specific page if it was opened but that has been that way for a while since we use session tokens

@joshuaellis joshuaellis merged commit bb93c4e into releases/4.24.1 May 1, 2024
36 of 37 checks passed
@joshuaellis joshuaellis deleted the fix/sso-redirects branch May 1, 2024 14:39
* has been complete otherwise the SSO repsonse URL will not be
* caught by the component and you won't be able to login with it.
*/
if (initQuery.isLoading || (Array.isArray(routes) && routes.length === 0)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

(Nevermind my previous comment...) But wondering if there's a more certain way to know for sure than checking the array?

Copy link
Member Author

Choose a reason for hiding this comment

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

We could make useEnterprise better for sure e.g. adding "state" like isLoading etc.

I think if we wanted to do that we should revisit the hook entirely, the types aren't great etc. So it'd be another ticket 🤔

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 also isn't an issue in V5 because of how the router works there.

Marc-Roig added a commit that referenced this pull request May 2, 2024
* fix(admin): if were in EE mode wait for the EE routes to be loaded before rendering (#20238)

* fix: issue 20138 (#20240)

* v4.24.1

---------

Co-authored-by: Josh <[email protected]>
Co-authored-by: Alexandre BODIN <[email protected]>
Marc-Roig added a commit that referenced this pull request May 2, 2024
* fix(content-manager): bulk publish would only ever show first entry to be published (#20234)

* fix(content-manager): Fix bulk publish selection

* chore: refactor & simplify bulk publish

---------

Co-authored-by: Josh <[email protected]>

* fix(admin): if were in EE mode wait for the EE routes to be loaded before rendering (#20238)

* fix: issue 20138 (#20240)

* v4.24.1

---------

Co-authored-by: Fernando Chávez <[email protected]>
Co-authored-by: Josh <[email protected]>
Co-authored-by: Alexandre BODIN <[email protected]>
stanislavpodolia added a commit to entireframework/strapi that referenced this pull request May 9, 2024
commit c413ad9
Author: Marc Roig <[email protected]>
Date:   Wed May 8 17:07:53 2024 +0200

    release: v4.24.2 to develop (strapi#20280)

commit 53507a6
Author: Jundee Mark Gerona Molina <[email protected]>
Date:   Wed May 8 20:33:47 2024 +0800

    fix(cm): back button on ListSettingsView doesn't work (strapi#20263)

commit 9c79921
Merge: ca6c7c8 1c8a790
Author: Alexandre BODIN <[email protected]>
Date:   Fri May 3 08:57:52 2024 +0200

    Merge pull request from GHSA-wrvh-rcmr-9qfc

    Add validation for custom U&P OAuth callbacks

commit 1c8a790
Merge: 59a1c00 ca6c7c8
Author: DMehaffy <[email protected]>
Date:   Thu May 2 10:16:35 2024 -0700

    Merge branch 'develop' into enhancement/up-custom-callback-validation

commit ca6c7c8
Author: Marc Roig <[email protected]>
Date:   Thu May 2 17:14:54 2024 +0200

    release: 4.24.1 to develop (strapi#20248)

    * fix(admin): if were in EE mode wait for the EE routes to be loaded before rendering (strapi#20238)

    * fix: issue 20138 (strapi#20240)

    * v4.24.1

    ---------

    Co-authored-by: Josh <[email protected]>
    Co-authored-by: Alexandre BODIN <[email protected]>

commit de77e23
Author: Fernando Chávez <[email protected]>
Date:   Wed May 1 10:34:34 2024 +0200

    fix(content-manager): bulk publish would only ever show first entry to be published (strapi#20234)

    * fix(content-manager): Fix bulk publish selection

    * chore: refactor & simplify bulk publish

    ---------

    Co-authored-by: Josh <[email protected]>

commit a76a2ee
Merge: f7fb988 bfa5109
Author: markkaylor <[email protected]>
Date:   Wed Apr 24 14:57:04 2024 +0200

    Merge pull request strapi#20196 from strapi/releases/4.24.0

    chore(develop): release v4.24.0

commit bfa5109
Author: Mark Kaylor <[email protected]>
Date:   Wed Apr 24 14:48:42 2024 +0200

    v4.24.0

commit f7fb988
Merge: bbb5d9c 515e540
Author: Alexandre BODIN <[email protected]>
Date:   Wed Apr 24 08:48:02 2024 +0200

    Merge pull request strapi#20190 from strapi/chore/updateSecurityPolicy

    Update SECURITY.md with changes related to Strapi 5 Beta

commit 515e540
Author: DMehaffy <[email protected]>
Date:   Tue Apr 23 15:37:06 2024 -0700

    Update SECURITY.md with changes related to Strapi 5 Beta

commit 6ad256c
Merge: 0e2e3db e8698b6
Author: Alexandre BODIN <[email protected]>
Date:   Tue Apr 23 16:00:18 2024 +0200

    Merge pull request strapi#20180 from strapi/fix/issue-19660

    fix: content could be undefined

commit e8698b6
Author: Alexandre Bodin <[email protected]>
Date:   Tue Apr 23 14:40:14 2024 +0200

    fix: content could be undefined

commit bbb5d9c
Merge: 0e2e3db ab53783
Author: Alexandre BODIN <[email protected]>
Date:   Tue Apr 23 13:16:52 2024 +0200

    Merge pull request strapi#20171 from strapi/fix/ee-not-extending-metrics

    fix: ee not being extended because no default export

commit ab53783
Author: Alexandre Bodin <[email protected]>
Date:   Tue Apr 23 10:30:13 2024 +0200

    chore: remove use of entity service

commit 3b831b1
Author: Alexandre Bodin <[email protected]>
Date:   Mon Apr 22 14:56:57 2024 +0200

    fix: ee not being extended because no default export

commit 0e2e3db
Merge: 0742c57 8515737
Author: Alexandre BODIN <[email protected]>
Date:   Thu Apr 18 10:39:32 2024 +0200

    Merge pull request strapi#20044 from strapi/fix/cors-5

    Make cors middleware compliant with the intended spec

commit 8515737
Merge: 469f8c0 0742c57
Author: Jean-Sébastien Herbaux <[email protected]>
Date:   Wed Apr 17 16:40:04 2024 +0200

    Merge branch 'develop' into fix/cors-5

commit 0742c57
Author: Alexandre BODIN <[email protected]>
Date:   Wed Apr 17 16:27:48 2024 +0200

    enhancement: use file path in place of streams to optimize sharp fragmentation & libvips caching (strapi#20080)

    Co-authored-by: DMehaffy <[email protected]>

commit 59a1c00
Author: Convly <[email protected]>
Date:   Wed Apr 17 16:24:18 2024 +0200

    enhancement: improve callback URL validation

commit 469f8c0
Merge: dd46ee6 896ff28
Author: DMehaffy <[email protected]>
Date:   Wed Apr 17 06:51:18 2024 -0700

    Merge branch 'develop' into fix/cors-5

commit 896ff28
Merge: 7237fd8 655449a
Author: Convly <[email protected]>
Date:   Wed Apr 17 15:23:02 2024 +0200

    Merge branch 'releases/4.23.1' into develop

commit 7237fd8
Author: Ben Irvin <[email protected]>
Date:   Wed Apr 17 15:14:37 2024 +0200

    fix(database): add prefixed alias to avoid join column name conflicts

commit 655449a
Author: Convly <[email protected]>
Date:   Wed Apr 17 15:08:57 2024 +0200

    v4.23.1

commit 9f8bd63
Author: DMehaffy <[email protected]>
Date:   Tue Apr 16 06:51:20 2024 -0700

    chore: upgrade mysql2 from 3.6.0 to 3.9.4

commit de4c825
Author: Fernando Chávez <[email protected]>
Date:   Tue Apr 16 15:34:21 2024 +0200

    tests(content-releases): add API tests for Content Releases (strapi#20048)

    * tests(content-releases): add API tests for Content Releases

    * apply marc comments

    * test

    * make each test case independent from each other

    * test

commit dd46ee6
Merge: 24613c1 6f96608
Author: DMehaffy <[email protected]>
Date:   Mon Apr 15 14:07:38 2024 -0700

    Merge branch 'develop' into fix/cors-5

commit 6f96608
Author: markkaylor <[email protected]>
Date:   Mon Apr 15 12:05:46 2024 +0200

    chore(deps): bump @strapi/design-system from 1.16.0 to 1.18.0 (strapi#20115)

commit 0ddbe58
Author: Josh <[email protected]>
Date:   Fri Apr 12 09:45:14 2024 +0100

    chore(pack-up): remove from monorepo (strapi#20082)

    * chore(pack-up): remove from monorepo

    * chore: declare util dep of helper-plugin

commit 463b44b
Author: Simone <[email protected]>
Date:   Thu Apr 11 17:10:52 2024 +0200

    fix(content-releases): fix e2e test (strapi#20094)

commit 4de25b8
Author: Convly <[email protected]>
Date:   Thu Apr 11 14:39:28 2024 +0200

    fix: remove actual values from the validate callback errors

commit 24613c1
Author: Alexandre Bodin <[email protected]>
Date:   Wed Apr 10 20:06:23 2024 +0200

    chore: support arrays

commit 1ae222a
Author: Alexandre Bodin <[email protected]>
Date:   Fri Apr 5 10:09:09 2024 +0200

    fix: cors v5

commit 40e16fb
Author: Alexandre Bodin <[email protected]>
Date:   Thu Apr 11 09:34:14 2024 +0200

    chore: fix prettier

commit cfecf3a
Merge: 450055e 39dfc65
Author: DMehaffy <[email protected]>
Date:   Wed Apr 10 10:11:58 2024 -0700

    Merge pull request strapi#20036 from strapi/docusaurus-local-search

commit 450055e
Author: Marc Roig <[email protected]>
Date:   Wed Apr 10 17:08:53 2024 +0200

    release: 4.23.0 to develop (strapi#20078)

    * feat(releases): add release column to CM list view (strapi#19926)

    * draft: bulk release injection zone added

    * chore: implement cm-api to strapi-app & description component renderer

    * feat: bulk delete action

    * Revert "draft: bulk release injection zone added"

    This reverts commit 2d9e887.

    * feat: bulk unpublish action added

    * feat: default bulk publish action

    * fix: variable renaming

    * fix: on close of modal updated and refetched list on publish action completion

    * fix: removed IZ publish and unpublish modals, e2e tests added for default bulk actions

    * tests: e2e updated for publish button disabled state

    * fix: bug fixed on publishing with already published entries

    * fix: e2e tests

    * fix: reverted IZ components

    * feat: bulk release action added

    * update: check right permissions to show add to release button

    * update: bulk actions modal updated to accept content(modalbody+modalfooter), publish action and release actions updated accordingly

    * fix: types

    * test: bulk release e2e test added

    * fix: e2e test

    * fix: test case timeout added, notification component updated to not saved message

    * feat: inject release column in LV

    * fix: minor changes

    * fix: remove commented code

    * fix: upgraded styled components to fix the error: defaultProps circularly references

    * feat(content-releases): add to be released in column in list view

    * fix: types and 0 releases entry

    * fix: invalidate entries in release after bulk release or on deleting a release action

    * tests: e2e tests added for release column

    * tests: e2e updated to create new release and then add bulk release

    * fix: minor changes, test fixed

    * fix: delete release action invalite tag added back

    * fix: e2e test

    * apply josh feedback|

    ---------

    Co-authored-by: Josh <[email protected]>
    Co-authored-by: Fernando Chavez <[email protected]>

    * chore(deps): revert sharp to 0.32.6 (strapi#20066)

    * fix: fix boot issue when removing i18n from an app

    * chore: get i18n service outside the for loop

    * chore: remove empty spaces

    * v4.23.0

    ---------

    Co-authored-by: Madhuri Sandbhor <[email protected]>
    Co-authored-by: Josh <[email protected]>
    Co-authored-by: Fernando Chavez <[email protected]>
    Co-authored-by: markkaylor <[email protected]>
    Co-authored-by: Alexandre BODIN <[email protected]>

commit 6a87b37
Author: Simone <[email protected]>
Date:   Wed Apr 10 11:15:52 2024 +0200

    fix(i18n): Add some space to show the Locale values in the CM (strapi#20059)

    * fix(i18n): add some width to the locale column

    * fix(i18n): remove useless width

commit cb00a17
Author: Ben Irvin <[email protected]>
Date:   Tue Apr 9 14:34:28 2024 +0200

    chore: add watch script for all projects (strapi#20068)

commit 4dbfc9c
Author: Simone <[email protected]>
Date:   Mon Apr 8 21:43:09 2024 +0200

    Hide Locale column and grouping option when i18n plugin is not installed (strapi#19358)

    * fix(content-releases): create an hook to check if the i18n plugin is installed

    * fix(content-releases): refactor code to use StrapiApp getPlugin

    * fix(content-releases): hide locale if i18n is not installed

    * fix(content-releases): move the createHook in the content-release plugin

commit b2690ca
Author: Convly <[email protected]>
Date:   Mon Apr 8 14:58:51 2024 +0200

    fix: update validation for custom U&P OAuth callbacks

commit feeeef6
Author: Convly <[email protected]>
Date:   Mon Apr 8 14:48:42 2024 +0200

    fix: make the default callback validation stricter

commit e762295
Author: Convly <[email protected]>
Date:   Fri Apr 5 09:12:04 2024 +0200

    enhancement: add validation for custom U&P OAuth callbacks

commit 68c52dc
Author: DMehaffy <[email protected]>
Date:   Fri Apr 5 00:10:26 2024 -0700

    Chore: Update vite and webpack-dev-middleware (strapi#20037)

commit 2fe3160
Merge: 5ab818b 009bd52
Author: Alexandre Bodin <[email protected]>
Date:   Fri Apr 5 08:31:44 2024 +0200

    Merge branch 'releases/4.22.1' into develop

commit 5ab818b
Author: Ben Irvin <[email protected]>
Date:   Thu Apr 4 18:55:24 2024 +0200

    test: add e2e tests for CTB restarts from file changes

commit 39dfc65
Author: Pierre Wizla <[email protected]>
Date:   Thu Apr 4 18:07:26 2024 +0200

    Add Local Search plugin

commit 79f8c92
Merge: 689d28d 54c5072
Author: Alexandre BODIN <[email protected]>
Date:   Thu Apr 4 11:57:30 2024 +0200

    Merge pull request strapi#19971 from strapi/fix/issue-12225

    feat: support media deep filtering & relation shortcut filters

commit 54c5072
Author: Alexandre BODIN <[email protected]>
Date:   Thu Apr 4 11:57:23 2024 +0200

    Update packages/core/database/src/query/helpers/where.ts

    Co-authored-by: Jean-Sébastien Herbaux <[email protected]>

commit 689d28d
Merge: 117cb87 faf860c
Author: Alexandre BODIN <[email protected]>
Date:   Thu Apr 4 10:29:14 2024 +0200

    Merge pull request strapi#20023 from strapi/chore/ignore-nx-cache

    chore: ignore nx cache

commit faf860c
Author: Ben Irvin <[email protected]>
Date:   Thu Apr 4 09:47:28 2024 +0200

    chore: ignore nx cache

commit 117cb87
Author: Simone <[email protected]>
Date:   Thu Apr 4 09:29:34 2024 +0200

    fix(content-manager): populate media and nested components on cloning (strapi#19958)

    * fix(content-manager): populate media and nested components on cloning

    Co-authored-by: Marc Roig <[email protected]>

    * fix(content-manager): small changes based on review comments

    ---------

    Co-authored-by: Marc Roig <[email protected]>

commit 488120b
Merge: 752a6ed 2106229
Author: DMehaffy <[email protected]>
Date:   Wed Apr 3 10:06:16 2024 -0700

    Merge pull request strapi#20012 from strapi/chore/labelAction

commit 2106229
Merge: 1ce4160 752a6ed
Author: DMehaffy <[email protected]>
Date:   Wed Apr 3 08:44:35 2024 -0700

    Merge branch 'develop' into chore/labelAction

commit 1ce4160
Author: Derrick Mehaffy <[email protected]>
Date:   Wed Apr 3 08:43:59 2024 -0700

    Remove commented action and rename squad

commit 18f20ff
Author: Derrick Mehaffy <[email protected]>
Date:   Wed Apr 3 08:41:40 2024 -0700

    remove enhancement

commit 24323ae
Author: Derrick Mehaffy <[email protected]>
Date:   Wed Apr 3 07:45:07 2024 -0700

    Fix squad name

commit e3a9fc6
Author: Derrick Mehaffy <[email protected]>
Date:   Wed Apr 3 07:44:37 2024 -0700

    change project for content

commit 752a6ed
Merge: fe2c29f 83da60f
Author: markkaylor <[email protected]>
Date:   Wed Apr 3 10:41:41 2024 -0400

    Merge pull request strapi#19311 from mariansimecek/update-sharp-dep

    Update sharp package to version v0.33.3

commit be6aa51
Author: Derrick Mehaffy <[email protected]>
Date:   Wed Apr 3 07:38:45 2024 -0700

    chore: update github issue label workflow

    - Add Dennis + Nick to round-robin
    - Add Enhancement label action
    - Fix project assignment with new domain ownership

commit fe2c29f
Merge: a36def2 45fb7bc
Author: markkaylor <[email protected]>
Date:   Wed Apr 3 09:24:31 2024 -0400

    Merge pull request strapi#20007 from strapi/releases/4.22.0

    v4.22.0 - develop

commit 9dfe475
Author: Alexandre Bodin <[email protected]>
Date:   Wed Apr 3 13:12:36 2024 +0200

    chore: add tests

commit 2bcdab4
Author: Alexandre Bodin <[email protected]>
Date:   Fri Mar 29 23:29:35 2024 +0100

    feat: support media deept filtering & relation shortcut filters

commit a36def2
Merge: 1fac05e e510c18
Author: Christian <[email protected]>
Date:   Wed Apr 3 11:21:35 2024 +0200

    Merge pull request strapi#19989 from strapi/fix/create-webhook-button

    fix: create webhooks on an empty list page

commit e510c18
Author: Christian Capeans <[email protected]>
Date:   Wed Apr 3 10:20:05 2024 +0200

    fix: remove unnecessary condition

commit 1fac05e
Author: Josh <[email protected]>
Date:   Tue Apr 2 16:55:14 2024 +0100

    fix(admin): force an absolute URL if the BACKEND_URL is relative (strapi#19950)

    * fix(admin): force an absolute URL if the BACKEND_URL is relative

    resolves strapi#18175

    * chore: add test for protocol relative url

commit 80a93a6
Author: Christian Capeans <[email protected]>
Date:   Tue Apr 2 17:33:48 2024 +0200

    fix: mocking less and lint

commit bfe081a
Merge: cf82c83 48671c2
Author: Alexandre BODIN <[email protected]>
Date:   Tue Apr 2 16:15:39 2024 +0200

    Merge pull request strapi#19970 from strapi/fix/issue-19532

    fix issue strapi#19532

commit 5007d86
Author: Christian Capeans <[email protected]>
Date:   Tue Apr 2 15:31:03 2024 +0200

    fix: create webhooks on an empty list page

commit 48671c2
Author: Alexandre Bodin <[email protected]>
Date:   Fri Mar 29 17:45:16 2024 +0100

    fix: fix issue strapi#19532

commit 83da60f
Author: Marian Šimeček <[email protected]>
Date:   Wed Jan 24 13:00:44 2024 +0100

    update sharp package
Marc-Roig added a commit that referenced this pull request May 13, 2024
* enhancement: add validation for custom U&P OAuth callbacks

* fix: make the default callback validation stricter

* fix: update validation for custom U&P OAuth callbacks

* fix: remove actual values from the validate callback errors

* enhancement: improve callback URL validation

* fix(content-manager): bulk publish would only ever show first entry to be published (#20234)

* fix(content-manager): Fix bulk publish selection

* chore: refactor & simplify bulk publish

---------

Co-authored-by: Josh <[email protected]>

* release: 4.24.1 to develop (#20248)

* fix(admin): if were in EE mode wait for the EE routes to be loaded before rendering (#20238)

* fix: issue 20138 (#20240)

* v4.24.1

---------

Co-authored-by: Josh <[email protected]>
Co-authored-by: Alexandre BODIN <[email protected]>

* v4.24.2

* fix: prettier

---------

Co-authored-by: Convly <[email protected]>
Co-authored-by: Fernando Chávez <[email protected]>
Co-authored-by: Josh <[email protected]>
Co-authored-by: Alexandre BODIN <[email protected]>
Co-authored-by: DMehaffy <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr: fix This PR is fixing a bug source: core:admin Source is core/admin package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enterprise SSO will not redirect properly and allow users to login
4 participants