Use literal '/'s to build internal zip file paths (#51) * Use posixpath to build internal zip file paths * Use literal / instead of posixpath * Update piptool.par and whltool.par
diff --git a/rules_python/whl.py b/rules_python/whl.py index c102d03..e3544d8 100644 --- a/rules_python/whl.py +++ b/rules_python/whl.py
@@ -60,12 +60,12 @@ with zipfile.ZipFile(self.path(), 'r') as whl: # first check for metadata.json try: - with whl.open(os.path.join(self._dist_info(), 'metadata.json')) as f: + with whl.open(self._dist_info() + '/metadata.json') as f: return json.loads(f.read().decode("utf-8")) except KeyError: pass # fall back to METADATA file (https://www.python.org/dev/peps/pep-0427/) - with whl.open(os.path.join(self._dist_info(), 'METADATA')) as f: + with whl.open(self._dist_info() + '/METADATA') as f: return self._parse_metadata(f.read().decode("utf-8")) def name(self):
diff --git a/tools/piptool.par b/tools/piptool.par index ee03cfc..206a33d 100755 --- a/tools/piptool.par +++ b/tools/piptool.par Binary files differ
diff --git a/tools/whltool.par b/tools/whltool.par index 6c06a50..fece5b0 100755 --- a/tools/whltool.par +++ b/tools/whltool.par Binary files differ