This repository was archived by the owner on Jan 18, 2025. It is now read-only.
Deferring OpenSSL import until usage.#159
Merged
craigcitro merged 1 commit intogoogleapis:masterfrom Apr 15, 2015
Merged
Conversation
Contributor
Author
|
/cc @craigcitro |
Contributor
Author
|
Is there anyone to review this? |
|
I took a look, but I don't think I know this part of the code or the language subtleties well enough to be the sole approver. I would suggest @nathanielmanistaatgoogle, but possibly also @craigcitro or @jcgregorio. |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
Contributor
|
one little thing, otherwise LGTM |
This is to speed up import times. In OpenSSL 0.14 the import takes 0.5 seconds due to cffi on-demand build of extensions in the cryptography library. For classes and functions which are conditionally defined based on the existence of OpenSSL.crypto, we check that the module exists (but don't import it) using imp.find_module.
9dc6ba2 to
613ab46
Compare
Contributor
Author
|
@craigcitro I Feel free to take a second look. I don't have merge privileges so someone will need to use your LGTM for me. |
Contributor
|
@dhermes yeah, i don't think we have an easy way to give non-googlers push rights on this repo. merging now. |
craigcitro
added a commit
that referenced
this pull request
Apr 15, 2015
Deferring OpenSSL import until usage.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is to speed up import times. In OpenSSL 0.14 the import takes
0.5 seconds due to cffi on-demand build of extensions in the
cryptography library.
For classes and functions which are conditionally defined based on
the existence of OpenSSL.crypto, we check that the module
exists (but don't import it) using imp.find_module.
See pyca/pyopenssl#137 for context (originally discovered by me because of google/apitools#14).