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 recursion in effect when fetching series acls #835

Merged
merged 2 commits into from
Jul 23, 2024

Conversation

dennis531
Copy link
Contributor

@dennis531 dennis531 commented Jul 12, 2024

Fixes the mentionied bug in #829.

Due to the React.stric mode, the ACLs are loaded twice and the notification is displayed twice, see https://react.dev/reference/react/StrictMode:

image

This problem could not be solved by simply putting dispatch(removeNotificationWizardForm()); at the beginning of the effect because the fetch is asynchronous. Is this a problem and should we fix it?

Close #829

@dennis531 dennis531 added the type:bug Something isn't working label Jul 12, 2024
Copy link
Contributor

Use docker or podman to test this pull request locally.

Run test server using develop.opencast.org as backend:

podman run --rm -it -p 127.0.0.1:3000:3000 ghcr.io/opencast/opencast-admin-interface:pr-835

Specify a different backend like stable.opencast.org:

podman run --rm -it -p 127.0.0.1:3000:3000 -e PROXY_TARGET=https://stable.opencast.org ghcr.io/opencast/opencast-admin-interface:pr-835

It may take a few seconds for the interface to spin up.
It will then be available at http://127.0.0.1:3000.
For more options you can pass on to the proxy, take a look at the README.md.

Copy link
Contributor

github-actions bot commented Jul 12, 2024

This pull request is deployed at test.admin-interface.opencast.org/835/2024-07-15_14-55-28/ .
It might take a few minutes for it to become available.

Copy link
Member

@Arnei Arnei left a comment

Choose a reason for hiding this comment

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

Reasonable change and works.

While you are at it, could you remove the eslint disabling comment? Looks like it really should not be there.

@dennis531
Copy link
Contributor Author

While you are at it, could you remove the eslint disabling comment? Looks like it really should not be there.

Done. I needed to add dispatch to the list of dependencies, otherwise the warning would be triggered.

@gregorydlogan gregorydlogan self-assigned this Jul 23, 2024
@gregorydlogan gregorydlogan merged commit cb3bed5 into opencast:main Jul 23, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[OC 16.1] Infinite loop of printing warning message when trying to add recording
3 participants