Skip to content

SSL Certificate identification not working on MacOS #528

@sysid

Description

@sysid

The following lines are failing on MacOS:

try:
    os.path.isfile('/etc/ssl/certs/ca-certificates.crt')
    CA_CERTS = '/etc/ssl/certs/ca-certificates.crt'
except Exception:
    import certifi
    CA_CERTS = certifi.where()

the expression os.path.isfile returns a bool and therefore the try/except clause is ineffective. On MacOS this results in the following error:

[ERROR] network_handler(): HTTPSConnectionPool(host='www.alexblackie.com', port=443): Max retries exceeded with url: /articles/email-authenticity-dkim-spf-dmarc/?utm_source=hackernewsletter&utm_medium=email&utm_term=fav (Caused by SSLError(FileNotFoundError(2, 'No such file or directory')))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions