def get_authenticity_token(self, url=_SIGNIN_URL):
    ' Returns an authenticity_token, mandatory for signing in '
    res = self.client._get(url=url, expected_status_code=200)
    soup = BeautifulSoup(res.text, _DEFAULT_BEAUTIFULSOUP_PARSER)
    selection = soup.select(_AUTHENTICITY_TOKEN_SELECTOR)
    try:
        authenticity_token = selection[0].get('content')
    except:
        raise ValueError('authenticity_token not found in {} with {}\n{}'.format(_SIGNIN_URL, _AUTHENTICITY_TOKEN_SELECTOR, res.text))
    return authenticity_token
Returns an authenticity_token, mandatory for signing in
def get_authenticity_token(self, url=_SIGNIN_URL):
    '  '
    res = self.client._get(url=url, expected_status_code=200)
    soup = BeautifulSoup(res.text, _DEFAULT_BEAUTIFULSOUP_PARSER)
    selection = soup.select(_AUTHENTICITY_TOKEN_SELECTOR)
    try:
        authenticity_token = selection[0].get('content')
    except:
        raise ValueError('authenticity_token not found in {} with {}\n{}'.format(_SIGNIN_URL, _AUTHENTICITY_TOKEN_SELECTOR, res.text))
    return authenticity_token