• Resolved lazandsue

    (@lazandsue)


    Im having issues with both AI engine and code engine. Code engine wont let me save a callable function. i get the below errors when navigating tabs on code engine. If i create a simple global function that echos to the test window, the test screen seem to work and prints it. However if i create a simple callable function that just echos todays date the test screen doesnt output anything.

    i get the below errors in the dev console and im also un able to save the snippet due to “The reply sent by the server is broken.” As a result the function menu never shows up in AI engine menu for me to select it. This is the same result if i manually add my own php functions and define it as per the docs for declaring functions.

    I have no PHP debug logs related to this issue.
    I have uninstalled all other plugins and themes which didnt help.
    i have the API enabled, i have set up a bearer token successfully.
    I do have a callable function stored in the database for code engine (on the rare occassion it does actually save functions) but still, AI engine doesnt have a functions menu for me to select it.
    AI Engine is 2.7.4
    Code Engine is 0.2.9
    Not sure why run/lint is producing a 403 error as per above screenshot either

    i’m also 4 days into trying to diagnose it myself before posting this so im now at the point i need so assistance please 🙂

    On a side note : for Jordy….. in the addons screen of AI engine the link to deepseek addon goes to a invalid url as well 🙂

Viewing 1 replies (of 1 total)
  • Plugin Support Val Meow

    (@valwa)

    Hey @lazandsue! 👋

    Unfortunately, a 403 error isn’t something we can fix on the plugin side. It means that authorization isn’t granted to the current user, so the route is forbidden.

    Both of these routes check for the manage_options capability. Make sure your user has this right.

    If not, you can use the mwcode_allow_usage filter to always return true so that every user can query this route, which should fix the issue:

    add_filter( 'mwcode_allow_usage', function() {
        return true;
    });

    If the issue persists or happens only from time to time, it could be due to a cache, security, or optimization plugininterfering with the requests. Try disabling those temporarily to see if that helps.

    Thanks! 😊

Viewing 1 replies (of 1 total)

The topic ‘Code engine and AI engine issues’ is closed to new replies.