Figured it out.
I was running Spark::scriptVariables() more than once in my app.blade.php leading to duplicate queries.
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I have a fairly customised spark app.
I have debugbar installed, and generally keep it minimised.
However, today, I opened up debugbar and realised that I suddenly was generating a lot of duplicate queries on every page of my application.
Do any other spark users have any ideas what the origin of all of these repeated queries could be
They seem to be coming from the Team and User repositories at /spark/src/Repositories, mostly the same 4 or so queries repeated many times. Are these generated anytime you use a Spark variable in a blade file (my only idea at the moment)?
Of course I am kicking myself for not keeping Debugbar opened all the time so I could track when this started happening!
Figured it out.
I was running Spark::scriptVariables() more than once in my app.blade.php leading to duplicate queries.
Please or to participate in this conversation.