{"id":20966,"library":"authres","title":"authres","description":"A Python library for parsing and generating email Authentication-Results headers as defined in RFC 8601. Current version 1.2.0, stable release cadence is low (last update 2021).","status":"active","version":"1.2.0","language":"python","source_language":"en","source_url":"https://github.com/ValiMail/authentication-results-python","tags":["email","authentication-results","dmarc","spf","dkim"],"install":[{"cmd":"pip install authres","lang":"bash","label":"Install via pip"}],"dependencies":[],"imports":[{"note":"Always use this import; no common wrong alternative.","symbol":"AuthenticationResultsHeader","correct":"from authres import AuthenticationResultsHeader"}],"quickstart":{"code":"from authres import AuthenticationResultsHeader\n\n# Parse an Authentication-Results header\nheader = 'dmarc=pass header.from=example.com; spf=pass smtp.mailfrom=email@example.com'\nparsed = AuthenticationResultsHeader.parse(header)\nprint(parsed.results)\n\n# Generate a new header\nfrom authres import AuthenticationResultsHeader, AuthResult\nresult = AuthResult('dmarc', 'pass', {'header.from': 'example.com'})\nheader_obj = AuthenticationResultsHeader('mail.example.com', [result])\nprint(str(header_obj))","lang":"python","description":"Parse and generate Authentication-Results headers."},"warnings":[{"fix":"Ensure your header strings use RFC 8601 format exactly.","message":"The library only supports RFC 8601, not earlier drafts. Headers using 'smtp.mailfrom' (with dot) vs 'smtp.mailfrom' (underscore) may cause parsing issues.","severity":"gotcha","affected_versions":"1.0.0 - 1.2.0"},{"fix":"Supply the entire header value as a single string, with newlines separating lines if multi-line.","message":"Parsing multiple header lines requires concatenating them with newlines; passing them as separate arguments is not supported.","severity":"gotcha","affected_versions":"all"},{"fix":"Consider alternatives or pin Python version (tested up to 3.10).","message":"The library is no longer actively maintained; no updates since 2021. It may not work with future Python versions.","severity":"deprecated","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-04-27T00:00:00.000Z","next_check":"2026-07-26T00:00:00.000Z","problems":[{"fix":"Run 'pip install --upgrade authres' to ensure version 1.2.0 installed.","cause":"The import path is correct but some installations may have a different version or package name collision.","error":"AttributeError: module 'authres' has no attribute 'AuthenticationResultsHeader'"},{"fix":"Use AuthenticationResultsHeader.parse(header_string) without extra arguments.","cause":"Trying to pass additional parameters like instance method incorrectly.","error":"TypeError: AuthenticationResultsHeader.parse() takes 1 positional argument but 2 were given"},{"fix":"Ensure header format: 'method=result key=value' with spaces separating key-value pairs.","cause":"Header string does not conform to RFC 8601 syntax, e.g., missing '=' in key-value pairs.","error":"ValueError: Invalid header format"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}