Skip to content

fix #664#665

Merged
alex merged 4 commits into
masterfrom
reaperhulk-patch-1
Jul 19, 2017
Merged

fix #664#665
alex merged 4 commits into
masterfrom
reaperhulk-patch-1

Conversation

@reaperhulk

Copy link
Copy Markdown
Member

No description provided.

bytes and strings are different things.
@alex

alex commented Jul 19, 2017

Copy link
Copy Markdown
Member

a) Why don't the tests catch this?
b) If these values are going to be unicode, please make _CRYPTOGRAPHY_MANYLINUX1_CA_DIR unicode.

@alex alex added this to the 17.2.0 milestone Jul 19, 2017
@reaperhulk

reaperhulk commented Jul 19, 2017

Copy link
Copy Markdown
Member Author

Tests didn't catch this because to have it take the fallback path we fetched the values from cffi and then monkeypatched our constants (https://github.com/pyca/pyopenssl/blob/master/tests/test_ssl.py#L1114-L1142). So the comparison succeed since they were both bytes.

I think a better fix here is just to declare these as byte strings and not unicode. They're not really paths to us, just sentinel values.

@alex

alex commented Jul 19, 2017

Copy link
Copy Markdown
Member

That's also fine with me.

@codecov

codecov Bot commented Jul 19, 2017

Copy link
Copy Markdown

Codecov Report

Merging #665 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #665   +/-   ##
=======================================
  Coverage   96.94%   96.94%           
=======================================
  Files          18       18           
  Lines        5737     5737           
  Branches      401      401           
=======================================
  Hits         5562     5562           
  Misses        117      117           
  Partials       58       58
Impacted Files Coverage Δ
src/OpenSSL/SSL.py 94.88% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7f5610c...4041f61. Read the comment docs.

@alex

alex commented Jul 19, 2017

Copy link
Copy Markdown
Member

trailing whitespace makes the flake8 fail

@reaperhulk

Copy link
Copy Markdown
Member Author

Why can't GitHub's editor strip trailing whitespace like my vim config does.

@alex

alex commented Jul 19, 2017

Copy link
Copy Markdown
Member

Send a feature request!

@alex alex merged commit a92a1a7 into master Jul 19, 2017
@alex alex deleted the reaperhulk-patch-1 branch July 19, 2017 13:53
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Aug 17, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants