Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix propel datacollector #46

Open
wants to merge 3 commits into
base: 7.0
Choose a base branch
from

Conversation

ldaspt
Copy link

@ldaspt ldaspt commented Dec 6, 2024

Fix error in profiler on the Propel panel

An exception has been thrown during the rendering of a template ("Propel\Bundle\PropelBundle\DataCollector\PropelDataCollector::getQueries(): Return value must be of type array, Symfony\Component\VarDumper\Cloner\Data returned").

Fix error in profiler on the Propel panel

```
An exception has been thrown during the rendering of a template ("Propel\Bundle\PropelBundle\DataCollector\PropelDataCollector::getQueries(): Return value must be of type array, Symfony\Component\VarDumper\Cloner\Data returned").
```
@ldaspt
Copy link
Author

ldaspt commented Dec 20, 2024

@SkyFoxvn Friendly ping

@SkyFoxvn
Copy link
Owner

sorry about the delay
i just checked that but im not sure thats the solution sure maybe it will work depending of few thinks for example if we are working with single tone PropelDataCollector but if we are making new instance of this class you will get printed only the instance queries not all queries as in the previous case ussing logger->getQueries

also another think is if you check the logger class PropelLogger -> getQueries you will easy see that function cant return anything else then array so the problem is somewere else please provide me with more information so i can reproduce the problem and find what happens

NOTE: i will look it after the new year but still i will need more info to reproduce it

LDA added 2 commits December 26, 2024 21:16
Fix error in profiler on the Propel panel

```
An exception has been thrown during the rendering of a template
("Propel\Bundle\PropelBundle\DataCollector\PropelDataCollector::getQueries(): Return value
must be of type array, Symfony\Component\VarDumper\Cloner\Data returned").
```

Related to adding hint type to the medthod in the commit
SkyFoxvn@58fa12e#diff-53d4d12dd850e3a771f9af985f2fea723cbbaee3f0d3509da76ab67404a0c05b
@ldaspt
Copy link
Author

ldaspt commented Dec 26, 2024

@SkyFoxvn Sorry, I edited the wrong line, You're right. I updated the PR.

I believe the regression comes from adding the hint type to the "getQueries" method in the commit 58fa12e#diff-53d4d12dd850e3a771f9af985f2fea723cbbaee3f0d3509da76ab67404a0c05b

You can reproduce it by going to the profiler panel, you should have the error An exception has been thrown during the rendering of a template ("Propel\Bundle\PropelBundle\DataCollector\PropelDataCollector::getQueries(): Return value must be of type array, Symfony\Component\VarDumper\Cloner\Data returned").

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants