Two days ago I posted a topic here with some questions I had when including another database in my project. The issue was solved, and later I decided to upgrade the project to V8 since I wanted to take advantage of some features released on load hook and change hook. However, all smart actions give me a 500 error when executed.
Observed behavior
All smart actions show an error like below when executed.
I’d like to point out that the hooks execute as expected given that I successfully load some data (coming from the database) to a dropdown field in the smart action form. On the other hand, the route associated with the smart action does not execute, which makes me think the problem happens in-between, maybe?
Expected behavior
Expected all smart actions to be working properly.
Thanks, I’ve received the file.
Could you also check your agent logs to see if any issue appear there?
And finally, could you send the HTTP request and response that trigger the HTTP 500 ?
It does. I would suggest to wrap your smart action code (The one located in /routes) in a try/catch block so you should be able to get more informations of what going on - and why your server is throwing this error 500.
I tried doing that, but the problem seems to be that the code in /routes is not even triggered. I tested a console.log() at the beginning of the function and that was not even printed
Any furthers logs in your chrome browser?
Any specific CORS configuration that could make this fail?
Could you also try the same action without the permissionMiddleware call, just to check if everything works fine without it ?
Ok, I’m able to reproduce the issue. It seems like there is an issue with `permissionMiddlewareCreator.smartAction(). I’m opening a ticket on our end, so be sure you’ll be pinged once fixed.
Hi @nivea unfortunately my team mate speak a little fast.
We can’t reproduce. Please can you check if you install the latest version of forest-express-sequelize?
npm ls forest-express-sequelize
// or
yarn list forest-express-sequelize
I have not installed this package. After executing the command you suggested, it returns -- (empty).
I just have forest-express-mongoose in my dependencies: