-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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: Class Level Permissions dialog throws error TypeError: ce.current is null
for newly created class
#2549
Conversation
Thanks for opening this pull request! |
I will reformat the title to use the proper commit message syntax. |
TypeError: ce.current is null
@mathieulb would you like to test this out, whether it fixes your reported issue? |
This is the first time I try installing it from Github, I think. I did But apparently it runs anyway, so I logged into dashboard and created a new class and some columns and no data, and then pressed Security -> Class Level Permissions, and I still didn't get any dialog box, but this time without any error in the javascript console. Then I pressed on some other class name on the left and then the CLP dialog suddenly appeared, but it doesn't say for which class this CLP dialog is for. I tried again a few times, same thing. Then I cleared the cache & site data, and logged in again, and this time it worked correctly. But I think that it's the first time I ever tried parse dashboard on port 4040 of 127.0.0.1... every other time, I was using another port number, due to loading it as a npm dep in my parse server. So I don't know how it managed to fail at first, but now I can't get it to fail anymore. (Is that good news ?) |
Thanks for testing. The preview environment should work again now, so it will be easier to try this out. Let's see if it appears here in a few minutes... |
Uffizzi Ephemeral Environment
|
I tested in the preview env:
The result for me is as @mathieulb described: no error log in the JS console, but also no CLP dialog appears. Click on Refresh button in the data browser does not help, but reloading the entire page by clicking on the page reload button of the browser helps, then the dialog appears when clicking on Security > CLP. If the class is created server-side, and the default ACL is also set server side, and the permissions need to be fetched from the server after creating the class, then maybe fetching that right after class creation would solve the issue, if both are async operations? |
Actually, on creating and dropping a class, the value of New changes were pushed. |
Uffizzi Ephemeral Environment
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Tested with steps mentioned in #2549 (comment) and now works.
TypeError: ce.current is null
TypeError: ce.current is null
for newly created class
# [6.0.0-alpha.2](6.0.0-alpha.1...6.0.0-alpha.2) (2024-04-30) ### Bug Fixes * Class Level Permissions dialog throws error `TypeError: ce.current is null` for newly created class ([#2549](#2549)) ([27ed692](27ed692))
🎉 This change has been released in version 6.0.0-alpha.2 |
# [6.0.0-beta.1](5.4.0...6.0.0-beta.1) (2024-05-16) ### Bug Fixes * App metrics for user and installation counts show dash ([#2528](#2528)) ([850d7b3](850d7b3)) * Class Level Permissions dialog throws error `TypeError: ce.current is null` for newly created class ([#2549](#2549)) ([27ed692](27ed692)) * Config page fails to load ([#2531](#2531)) ([d721b7c](d721b7c)) * Dashboard crashes if Parse Server Cloud Function script returns object ([#2516](#2516)) ([5de08f8](5de08f8)) * Dashboard scrolls when selecting row in data browser ([#2559](#2559)) ([2aa54a5](2aa54a5)) * Data browser redirects to wrong class when changing app ([#2526](#2526)) ([7713f54](7713f54)) * Deleting all code in the JS Console editor fills in the default code ([#2558](#2558)) ([4b830ba](4b830ba)) * Open pointer in new tab in data browser not working when mount path is not root ([#2527](#2527)) ([2f4081f](2f4081f)) ### Features * Add descriptive statistics for number cells in data browser ([#2529](#2529)) ([ead9ec4](ead9ec4)) * Add filter `starts with` in data browser for fields of type Pointer ([#2553](#2553)) ([0b94ab6](0b94ab6)) * Add Node 20 support; remove Node 14, 16 support ([#2532](#2532)) ([578a339](578a339)) * Add Node 20 support; remove Node 14, 16 support ([#2535](#2535)) ([5c90f2d](5c90f2d)) * Execute script for selected rows ([#2508](#2508)) ([5d9901e](5d9901e)) * Select rows in data browser by clicking and dragging mouse cursor over checkboxes ([#2548](#2548)) ([792ba9e](792ba9e)) ### BREAKING CHANGES * Removes support for Node 14 and 16 ([5c90f2d](5c90f2d))
🎉 This change has been released in version 6.0.0-beta.1 |
# [6.0.0](5.4.0...6.0.0) (2024-10-07) ### Bug Fixes * App metrics for user and installation counts show dash ([#2528](#2528)) ([850d7b3](850d7b3)) * Class Level Permissions dialog throws error `TypeError: ce.current is null` for newly created class ([#2549](#2549)) ([27ed692](27ed692)) * Config page fails to load ([#2531](#2531)) ([d721b7c](d721b7c)) * Crash after setting filter using context menu and opening filters panel ([#2579](#2579)) ([5a690eb](5a690eb)) * Dashboard crashes if Parse Server Cloud Function script returns object ([#2516](#2516)) ([5de08f8](5de08f8)) * Dashboard not building for Docker platform arm64/v8 ([#2534](#2534)) ([8c4a862](8c4a862)) * Dashboard scrolls when selecting row in data browser ([#2559](#2559)) ([2aa54a5](2aa54a5)) * Data browser redirects to wrong class when changing app ([#2526](#2526)) ([7713f54](7713f54)) * Deleting all code in the JS Console editor fills in the default code ([#2558](#2558)) ([4b830ba](4b830ba)) * Descriptive statistics for number cells in data browser not showing ([#2581](#2581)) ([e146b6f](e146b6f)) * Filter string is erased when changing filter condition ([#2586](#2586)) ([6fa2c8c](6fa2c8c)) * Internal classes `_User`, `_Role`, `_Installation` referenced with pointer don't appear in data browser filter dialog ([#2599](#2599)) ([8239cc8](8239cc8)) * Open pointer in new tab in data browser not working when mount path is not root ([#2527](#2527)) ([2f4081f](2f4081f)) ### Features * Add Cloud Config change history to roll back to previous values ([#2554](#2554)) ([a784129](a784129)) * Add data panel to display object related data fetched via Cloud Function ([#2584](#2584)) ([914cc71](914cc71)) * Add descriptive statistics for number cells in data browser ([#2529](#2529)) ([ead9ec4](ead9ec4)) * Add filter `starts with` in data browser for fields of type Pointer ([#2553](#2553)) ([0b94ab6](0b94ab6)) * Add Node 20 support; remove Node 14, 16 support ([#2532](#2532)) ([578a339](578a339)) * Add Node 20 support; remove Node 14, 16 support ([#2535](#2535)) ([5c90f2d](5c90f2d)) * Add optional restriction of script execution to certain object fields and values ([#2488](#2488)) ([8feac9b](8feac9b)) * Add relational filter conditions in data browser ([#2576](#2576)) ([aa5c68d](aa5c68d)) * Add support for Node 22 ([#2603](#2603)) ([3689106](3689106)) * Execute script for selected rows ([#2508](#2508)) ([5d9901e](5d9901e)) * Select rows in data browser by clicking and dragging mouse cursor over checkboxes ([#2548](#2548)) ([792ba9e](792ba9e)) ### BREAKING CHANGES * Removes support for Node 14 and 16 ([5c90f2d](5c90f2d))
🎉 This change has been released in version 6.0.0 |
New Pull Request Checklist
Issue Description
Closes: #2547
Approach
The SecurityDialog component is rendered based on the existence of the "perms" value, which is subject to a delay as it is fetched. In this scenario, if the user clicks on the menu item and the "perms" value isn't ready, the value of "clpDialogRef" will be null.
TODOs before merging