Fixing build
This commit is contained in:
parent
dd399cb4be
commit
93e0a3ddc7
|
@ -24,10 +24,9 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
pip install .
|
pip install .
|
||||||
pip install mypy pytest
|
pip install mypy pytest
|
||||||
mypy --install-types --non-interactive
|
|
||||||
- name: Check types
|
- name: Check types
|
||||||
run: |
|
run: |
|
||||||
mypy --ignore-missing-imports jetforce/
|
mypy --ignore-missing-imports --install-types --non-interactive jetforce/
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: |
|
run: |
|
||||||
pytest -v tests/
|
pytest -v tests/
|
||||||
|
|
|
@ -4,7 +4,8 @@ import os
|
||||||
import tempfile
|
import tempfile
|
||||||
import typing
|
import typing
|
||||||
|
|
||||||
import OpenSSL
|
import OpenSSL.crypto
|
||||||
|
import OpenSSL.SSL
|
||||||
from cryptography import x509
|
from cryptography import x509
|
||||||
from cryptography.hazmat.backends import default_backend
|
from cryptography.hazmat.backends import default_backend
|
||||||
from cryptography.hazmat.primitives import hashes, serialization
|
from cryptography.hazmat.primitives import hashes, serialization
|
||||||
|
@ -120,9 +121,9 @@ class GeminiCertificateOptions(CertificateOptions):
|
||||||
mark the certificate as not trusted.
|
mark the certificate as not trusted.
|
||||||
"""
|
"""
|
||||||
if not hasattr(conn, "authorised"):
|
if not hasattr(conn, "authorised"):
|
||||||
conn.authorised = preverify_ok
|
conn.authorised = preverify_ok # type: ignore
|
||||||
else:
|
else:
|
||||||
conn.authorised *= preverify_ok
|
conn.authorised *= preverify_ok # type: ignore
|
||||||
|
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue