Common Problems

Here you can find information on problems and issues raised on Grav forum and in the Slack Chat room that occur frequently enough that we thought we would save time and list the problem and the relevant solution in one easy to find location.

  1. Call to a member function set() on null
  2. Cannot connect to the GPM
  3. Invalid Security Token

Call to a member function set() on null

Problem: We removed some code to optimize GPM in Grav 1.0.0-rc.6, however this code was causing invalid plugins to be skipped. However, certain people had extra folders that were not valid plugins in their user/plugins/ folder. This tripped up GPM causing the error message: Call to a member function set() on null to be returned for all GPM methods and also in the details of some of the Ajax calls made by the admin plugin.

Solution: The easiest fix is simply to remove those extraneous folders. The full solution that automatically skips these invalid plugins will be available in 1.0.0-rc.7.

Cannot connect to the GPM

Problem: The GPM cannot be reached, and you get this error in the Admin panel


First, make sure PHP has cURL and OpenSSL installed. You can check this in the Admin panel, in Configuration -> Info. You should see a "OpenSSL" section with OpenSSL support: enabled. Same for cURL, a section with cURL support: enabled.

If this is ok, make sure you're not behind a proxy. If so, configure it in the Grav System configuration and make sure there are no issues with the connection.

Then, check your permissions.

If after all the above you are still getting issues connecting with GPM, we have noticed that on some servers (mostly local machines running Windows), there are issues verifying the SSL certificate of, even though it is A Rating. To work around this problem, we have added a new system config system.gpm.verify_peer that is enabled by default. Set it to false and try again.

If at this point it's still not working, get in touch, or report back if you were pointed here via chat/forum.

Also, check the CLI command is working, by opening a SSH connection to the server and running bin/gpm index and check if it's just inside Admin that you get this error, or in the command line too.

"Invalid security token"

Problem: You get this error in the Admin panel


There are a few possible causes of the problem, all linked to the Session.

  • Try clearing your browser cookies, that's the easiest way and clears a possible cause of the problem.
  • Check that PHP has the correct tmp path set up. This can be set in PHP directly, or by setting Grav's system.yaml session.path setting (it can be also set via Admin, in the System Configuration) Reported issue
  • Make sure your web server config is right and includes the query string Reported issue