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

Queries with runtime over 1s are not summed up. #876

Closed
janolivermr opened this issue Apr 19, 2020 · 3 comments
Closed

Queries with runtime over 1s are not summed up. #876

janolivermr opened this issue Apr 19, 2020 · 3 comments

Comments

@janolivermr
Copy link
Contributor

  • Telescope Version: 2.1.7
  • Laravel Version: 6.18.8
  • PHP Version: 7.4.4
  • Database Driver & Version: Mysql

Description:

Queries that run longer than 1 second are not summed in the request queries list.
This is likely due to the use of the number_format function, which adds thousands separators.
In the vue frontend, the reduce function uses a parse_float which can't handle the thousands separator.

Steps To Reproduce:

Make a DB query that takes longer than 1 second inside a request.
View the request in Telescope and check the queries list. The long running query time will not be taken into account for the query time total.

janolivermr added a commit to janolivermr/telescope that referenced this issue Apr 19, 2020
@driesvints
Copy link
Member

Hey there,

Unfortunately we don't support this version anymore. Please check out our support policy on which versions we are currently supporting. Can you please try to upgrade to the latest version and see if your problem persists? We'll help you out and re-open this issue if so.

Thanks!

@janolivermr
Copy link
Contributor Author

Hi,

The code hasn't changed in the 3.x branch, it still uses the same number_format code in PHP and parseFloat in the JS front end function.
In my merge request ( #877 ) you mentioned the locale issue, however parseFloat understands only decimal points if I'm not mistaken.

@driesvints
Copy link
Member

@janolivermr let's see how the pr goes

taylorotwell added a commit that referenced this issue Apr 20, 2020
[3.x] Remove thousands separator in time records (#876)
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

No branches or pull requests

2 participants