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

[feature request] werkzeug.contrib.profiler.ProfilerMiddleware custom file name formatting #1283

Closed
ChrisCarini opened this issue Apr 21, 2018 · 1 comment

Comments

Projects
None yet
2 participants
@ChrisCarini
Copy link
Contributor

commented Apr 21, 2018

It would be nice to allow users to customize the output file name format when using the ProfilerMiddleware.

Currently, the file name format is '%(method)s.%(path)s.%(elapsed)06dms.%(time)d', which when multiple invocations have occurred leads to the profile files being ordered by their respective elapsed times. Having the ability to customize this format allows profiling users to make use of the resultant profile files in additional ways.

I propose the profiler.ProfilerMiddleware is changed to allow users to customize the format of the profile filenames for their specific needs.

@ChrisCarini ChrisCarini changed the title werkzeug.contrib.profiler.ProfilerMiddleware custom file name formatting [feature request] werkzeug.contrib.profiler.ProfilerMiddleware custom file name formatting Apr 21, 2018

@ChrisCarini

This comment has been minimized.

Copy link
Contributor Author

commented Apr 21, 2018

Hey @lepture,

Thank you for labeling with beginner friendly; this is actually my first feature request in werkzeug! I just opened a PR ( #1284 ) with my initial implementation of the change.

Thank you,
Chris

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.