Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make sure `python_root` and `neuropod_path` are not the same #138

Open
VivekPanyam opened this issue Aug 27, 2019 · 1 comment
Open

Make sure `python_root` and `neuropod_path` are not the same #138

VivekPanyam opened this issue Aug 27, 2019 · 1 comment

Comments

@VivekPanyam
Copy link
Member

@VivekPanyam VivekPanyam commented Aug 27, 2019

This check currently ensures that neuropod_path is not a subdirectory of python_root. However, it misses cases where they are the same directory

https://github.com/uber/neuropods/blob/9c4b58b84429b4390e8dfa658963d65312b6b52c/source/neuropods/python/backends/python/packager.py#L152-L153

@VivekPanyam
Copy link
Member Author

@VivekPanyam VivekPanyam commented Apr 5, 2020

Relevant lines are now

if os.path.realpath(neuropod_path).startswith(
os.path.realpath(python_root) + os.sep
):
raise ValueError(
"`neuropod_path` cannot be a subdirectory of `python_root`"
)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.