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

Clean up (usage of) onResult, makeResult, and onNext #1257

Closed
drikusroor opened this issue Sep 9, 2024 · 0 comments · Fixed by #1262
Closed

Clean up (usage of) onResult, makeResult, and onNext #1257

drikusroor opened this issue Sep 9, 2024 · 0 comments · Fixed by #1262

Comments

@drikusroor
Copy link
Contributor

drikusroor commented Sep 9, 2024

1. Remove onNext calls from the onResult callback function

We can probably just wait for onResult to finish and call onNext manually (in makeResult)

2. Remove result_id from the backend Trial constructor and the if (result_id) condition in Trial.tsx.

if (result_id) {
onResult({
result,
result_id
});
} else {
onNext();
}

This bit is in here for "historical reasons" - the Trial has a result_id at top level, but this is not necessary anymore. (Before a refactor, the "breaking round" mechanism was handled through this top level result id.) I checked, and indeed, no Trial in the current rules files contains a result_id. We should remove result_id from the backend Trial constructor and this condition here. (Can be left for later though.)

Originally posted by @BeritJanssen in #1254 (comment)

UPDATE

Some work in progress can be found in #1258

@drikusroor drikusroor changed the title Remove result_id from the backend Trial constructor and the if (result_id) condition in Trial.tsx. Clean up (usage of) onResult, makeResult, and onNext Sep 10, 2024
@drikusroor drikusroor linked a pull request Sep 11, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants