Xfail the mitmproxy / pyOpenSSL dependency conflict

This is already fixed in master:
https://github.com/mitmproxy/mitmproxy/pull/2435

So it'll hopefully in the next release.

Because the pyOpenSSL package name and requirement name do not match we
also add code to lower the name for comparison.

Also the check-uc only complains about a single issue but there are 3.

Change-Id: I6657802908ac4052eeb6c73fb03098b0c3557eb2
This commit is contained in:
Dirk Mueller 2017-09-14 15:53:02 -06:00 committed by Tony Breeds
parent f640ae9d96
commit ee1a3433f1
2 changed files with 5 additions and 2 deletions

View File

@ -58,15 +58,15 @@ def main():
if req.markers in ["", pyver]:
pkg_resources.require(name)
except pkg_resources.ContextualVersionConflict as e:
if e.dist.key in xfails:
xfail_requirement = xfails[e.dist.key][0][0]
xfail_blacklists = set(xfail_requirement.markers.split(','))
conflict = e.dist.as_requirement()
conflict_specifiers = ''.join(conflict.specs[0])
conflict_name = conflict.name.lower()
if (e.required_by.issubset(xfail_blacklists) and
xfail_requirement.package == conflict.name and
xfail_requirement.package == conflict_name and
conflict_specifiers == xfail_requirement.specifiers):
print ('XFAIL while checking conflicts '

View File

@ -1,2 +1,5 @@
# Format is
# <dependency that is incompatible>==<version>;<list,of,affected,packages>
pyopenssl==17.2.0;mitmproxy
pyasn1==0.3.3;mitmproxy
cryptography==2.0.3;mitmproxy