Closed baoilleach closed 7 years ago
That's probably right. I don't have access to a windows machine, so I can't fix and test. I'll wait for a motivated contributor to submit a PR.
I've found a highly possible reason that may cause the problem above. Linux accept a filename containing '?' (a question mark) while Windows don't. When files are extracted from .tar.gz, all question marks in filename are converted to '_' (underscore) in Windows. Unfortunately, lots of files in tests/data/ contain a '?', and as what is described in eutils.egg-info\SOURCES.txt, Python try to find files like
einfo.fcgi?retmode=xml.xml.gz
but it has been renamed to
einfo.fcgi_retmode=xml.xml.gz
which finally leads to a failure of installation.
Is it feasible to rename those tricky files?
Thanks for identifying the cause. As you likely inferred, those paths refer to the URLs from which the data were obtained. If we rename them, we'll lose that connection.
There's a better solution. Those files are essentially just test data caches. I would like to migrate eutils tests to use the vcrpy, which will then cache the results in a cross-platform way.
If you're interested in taking that on, see https://github.com/reece/helix/blob/master/tests/ (particularly the bottom of conftest.py and test_helix_client.py) for an example of how it's used.
If you're not interested/able to undertake this, I'll do it sometime. It'll be pretty easy.
@zeanzhou Would you please try this version of the package? It eliminates the test files and replaces them with request caches from vcrpy. Please confirm on this issue that it's fixed on Windows, or reopen the issue. Thanks.
@reece Cool! Now it works well on my Windows laptop! Much appreciated :+1: =)
Great. I appreciate the confirmation. pypi packages coming shortly...
Python 2.7 32-bit on Windows 7. Failed similarly with both pip 8.1.2 and 9.0.1.
(Looks like using os.path.join might solve the error below)