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

JavaScript Errror: TypeError: f.filter is not a function #18

Closed
Kilo59 opened this issue Apr 26, 2021 · 2 comments
Closed

JavaScript Errror: TypeError: f.filter is not a function #18

Kilo59 opened this issue Apr 26, 2021 · 2 comments

Comments

@Kilo59
Copy link

Kilo59 commented Apr 26, 2021

Hello, this looks like a cool project.
I've been looking for a FastAPI compatible memory profiler for a while.

I'm not sure if this project is still maintained but I ran into this JavaScript error.
I see the UI appear for a fraction of a second and then it goes away.

image

Tried to follow the examples in the readme.
https://github.com/Kilo59/coronavirus-tracker-api/blob/pyloot/app/profiling.py
https://github.com/Kilo59/coronavirus-tracker-api/blob/pyloot/app/main.py#L49-L50

I'm running it locally with uvicorn.
https://github.com/Kilo59/coronavirus-tracker-api/blob/pyloot/Pipfile#L44

@reallistic
Copy link
Owner

@Kilo59 Hello thanks for checking out the project!
I've downloaded your project and found that the issue is from having gzip encoding enabled explicitly.
pyloot also does its own gzip encoding. Thus encoding was happening twice and malformed data was returned.
I've added an option to pyloot to disable gzip encoding. I've also made the error handling a bit more graceful so that a nice error message is displayed instead of a white screen.
README is updated with instructions. The new version should publish automatically soon. Give it a try and add a comment if it does not solve your issue.

@reallistic
Copy link
Owner

Version 0.0.6 is published

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