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
Slightly sketchy speed-up for /rotation/ #6773
Conversation
Hey @tsutton, TravisBuddy Request Identifier: c7b83080-02b3-11ea-bbb5-2bfb3cbbfe32 |
Codecov Report
@@ Coverage Diff @@
## master #6773 +/- ##
=========================================
+ Coverage 41.88% 41.9% +0.02%
=========================================
Files 257 257
Lines 13314 13329 +15
Branches 2020 2023 +3
=========================================
+ Hits 5577 5586 +9
- Misses 7491 7492 +1
- Partials 246 251 +5
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the total speedup late in full rotation week? About 1s?
What do you think about moving this to shared_web.base_view.BaseView.url_for or (probably more appropriate) decksite.view.View.url_for and doing a little bit of magic based on the input params. Then we could change literally every url_for to use the new function and do this for anything we see more than a few dozen times in a request?
We could even have it store counts of (template + '|' + len(args)) occurrences and flag anything over 50 or something. |
Seen on LOGS (created by @tsutton and merged by @vorpal-buildbot 47 seconds ago) Please check your changes! |
Seen on PROD (created by @tsutton and merged by @vorpal-buildbot 1 minute and 1 second ago) Please check your changes! |
Context: #5471.
Changes: call Flask's builtin
url_for
once to retrieve a template url and then just use string formatting to build the url for each card.