This is the suggested setup in the New Application Quickstart Guide:
pwd_context = CryptContext( # ... # Automatically mark all but first hasher in list as deprecated. # (this will be the default in Passlib 2.0) deprecated="auto", # ... )
but the code uses this check:
if 'auto' in value:
suggesting that the docs should actually say to use
Interestingly, I've been passing
deprecated="auto", which hasn't caused any errors but presumably also doesn't do the right thing – I only ran into this when starting to do some type-checking, and trying to work out what types the CryptContext's arguments are.