Skip to content
This repository has been archived by the owner on Dec 10, 2018. It is now read-only.

Confused with absulute path in windows #341

Open
kep-w opened this issue Sep 7, 2018 · 1 comment
Open

Confused with absulute path in windows #341

kep-w opened this issue Sep 7, 2018 · 1 comment

Comments

@kep-w
Copy link

kep-w commented Sep 7, 2018

https://github.com/eleme/thriftpy/blob/c49a3adf2c52948b5c1a01c3109c9676763095f0/thriftpy/parser/parser.py#L547

hi,
I am using the thriftpy in our project, our environment is Windows, and when i use thriftpy.load(path, ....) function. the question is if use relative path as the path argument, it will raise an IOError, told that do not have the file. But, if I change absulute path, after urlparse, the scheme is 'c'/'d'/'e', and the judgment here will not be matched. So why is the judgment here not changed to be able to adapt to the absolute path in windows?
My suggestion is:
elif len(url_scheme) <= 1:

@ethe
Copy link
Member

ethe commented Dec 9, 2018

Have already been solved in thriftpy2, thanks.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants