I'm using the latest rollbar version (2.0.0). Rollbar has started throwing this exception recently. I could not find the relevant method from the stack trace.
Looks like Rollbar is trying the serialize the Query object involved in the exception (to include in the payload) and fails.
2020-05-31 20:30:03 Error: [Cake\Error\FatalErrorException] Uncaught RuntimeException: You cannot call all() on a non-select query. Use execute() instead. in /var/www/src/vendor/cakephp/cakephp/src/ORM/Query.php:1041
Stack trace:
#0 /var/www/src/vendor/cakephp/cakephp/src/Datasource/QueryTrait.php(141): Cake\ORM\Query->all()
#1 /var/www/src/vendor/rollbar/rollbar/src/Utilities.php(102): Cake\ORM\Query->getIterator()
#2 /var/www/src/vendor/rollbar/rollbar/src/Utilities.php(159): Rollbar\Utilities::serializeForRollbar(Object(Cake\ORM\Query), NULL, Array, -1, 2)
#3 /var/www/src/vendor/rollbar/rollbar/src/Utilities.php(105): Rollbar\Utilities::serializeObject(Object(Cake\ORM\Query), NULL, Array, -1, 1)
#4 /var/www/src/vendor/rollbar/rollbar/src/Utilities.php(117): Rollbar\Utilities::serializeForRollbar(Array, NULL, Array, -1, 1)
#5 /var/www/src/vendor/rollbar/rollbar/src/Payload/Frame.php(111): Rollbar\Utilities::serializeForRollbar(Array, NULL, Array)
#6 in /var/www/src/vendor/cakephp/cakephp/src/ORM/Query.php on line 1041
Stack Trace:
- /var/www/dev/src/Error/RollbarErrorHandlerTrait.php:50
- /var/www/dev/vendor/cakephp/cakephp/src/Error/BaseErrorHandler.php:122
- [main] - [internal], line ??