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
_enforceNoReturnValue.js
does not allow for async lifecycle hooks
#4014
Comments
_enforceNoReturnValue.js
does not allow for async controller lifecycle hooks_enforceNoReturnValue.js
does not allow for async lifecycle hooks
Hi @dfenerski, We recently allowed developers to use the Please see the updated ECMAScript Support page. Also please have a look at the updated API Reference: sap.ui.core.mvc.Controller#onInit. Best regards, |
Thanks for the info! I missed the docs - sorry for that |
@devtomtom it seems |
@dfenerski Good point, thanks! Yes, it definitely should be mentioned there too. |
Hi all, I came across this problem by chance because we are getting a similar error in our Build Workzone, standard edition Launchpad and maybe it is related. We integrate various specially developed cloud apps and on-premise apps into the WorkZone. We are using view mode "Spaces and Pages - New Experience". For a few days now, various errors have been occurring again and again, making it almost impossible to use the Launchpad. The Launchpad uses SAPUI5 version 1.123.1 (built at 2024-04-18T13:07). Maybe the problem is really related and my input is somehow helpful. I also raised an issue on me.sap.com: 377725/2024. Kind regards, |
Hi @thisisevanfox, |
Hi @devtomtom, see here:
Kind regards, |
Closing this issue here. Further updates will be done in the SAP support incident. |
OpenUI5 version: latest,
1.120 LTS
URL (minimal example if possible):
https://github.com/dfenerski/ui5-async-controller-lifecycle-issue
Steps to reproduce the problem:
The addition of the
_enforceNoReturnValue
module here 6f52e51 now logs a "future fatal" whenever a lifecycle hook with return value different thanundefined
is detected. Butasync
functions always return aPromise
. Therefore this change disables the possibility to useasync
lifecycle hooks.What is the expected result?
Async lifecycle hooks are OK
What happens instead?
Screenshot:
The text was updated successfully, but these errors were encountered: