I updated to Riru 23 aand edxposed to 5.1.4_4655 -master. I used the alpha version.Seems like latest Magisk has issues with stable edxposed. I suppose the solution at the moment is update to Riru 23 and EdXposed canary or revert to Magisk 20.4
Now Gravity box is running fine. Thanks!
I was scared about canary as they are known to be quite unstable.