• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

jwag956 / flask-security / 359 / 3
97%
master: 97%

Build:
DEFAULT BRANCH: master
Ran 24 Aug 2019 12:55AM UTC
Files 24
Run time 3s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

24 Aug 2019 12:50AM UTC coverage: 94.03% (-0.04%) from 94.066%
REQUIREMENTS=lowest

push

travis-ci

web-flow
fix - improve performance for auth tokens. (#168)

Turns out the flask-login will call request_loader if there is no session. That in turn
validates the token, does a DB query for the user, and verifies the contents of the token
(this is the expensive hash check).
Then - if an endpoint is decorated with either @auth_token_required or @auth_required,
it will again call request_loader and do it all over again.

This PR add a request-local flag to note that if the token has been verified and the user
looked up - and simply returns the existing user.

Also - after reading more about request and app contexts - decided that this AND the CSRF
flags (which was added a couple PRs ago) should be in the request context, not the app context.

2142 of 2278 relevant lines covered (94.03%)

0.94 hits per line

Source Files on job 359.3 (REQUIREMENTS=lowest)
  • Tree
  • List 0
  • Changed 4
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 329
  • Travis Job 359.3
  • 44ba1d94 on github
  • Prev Job for REQUIREMENTS=lowest on master (#356.1)
  • Next Job for REQUIREMENTS=lowest on master (#362.1)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc