nerfstudio-project / nerfstudio

A collaboration friendly studio for NeRFs
https://docs.nerf.studio
Apache License 2.0
8.87k stars 1.18k forks source link

Forcing setuptools version to 69.5.1 to overcome build error. #3218

Open aravindhankrishnan opened 2 weeks ago

aravindhankrishnan commented 2 weeks ago

Using the latest version of setuptools (70.0.0) gives an ImportError on "import packaging". Reverting to 69.5.1 resolves this issue.

maturk commented 2 weeks ago

does setuptools==69.5.1? I think setuptools<70.0.0 should suffice?

aravindhankrishnan commented 2 weeks ago

69.5.1 is the version previous to 70.0.0.

jb-ye commented 2 weeks ago

Do you have error logs?

Is this issue?

This PR is a work-around, but I believe this is a high priority bug for setuptools/packaging to fix.

aravindhankrishnan commented 2 weeks ago

Defaulting to user installation because normal site-packages is not writeable Collecting git+https://github.com/NVlabs/tiny-cuda-nn.git@v1.6#subdirectory=bindings/torch Cloning https://github.com/NVlabs/tiny-cuda-nn.git (to revision v1.6) to /tmp/pip-req-build-lefhvrzb Running command git clone --filter=blob:none --quiet https://github.com/NVlabs/tiny-cuda-nn.git /tmp/pip-req-build-lefhvrzb Running command git checkout -q 8e6e242f36dd197134c9b9275a8e5108a8e3af78 Resolved https://github.com/NVlabs/tiny-cuda-nn.git to commit 8e6e242f36dd197134c9b9275a8e5108a8e3af78 Running command git submodule update --init --recursive -q Preparing metadata (setup.py): started Preparing metadata (setup.py): finished with status 'error' error: subprocess-exited-with-error

× python setup.py egg_info did not run successfully. │ exit code: 1 ╰─> [8 lines of output] Traceback (most recent call last): File "", line 2, in File "", line 34, in File "/tmp/pip-req-build-lefhvrzb/bindings/torch/setup.py", line 5, in from torch.utils.cpp_extension import BuildExtension, CUDAExtension File "/home/user/.local/lib/python3.10/site-packages/torch/utils/cpp_extension.py", line 25, in from pkg_resources import packaging # type: ignore[attr-defined] ImportError: cannot import name 'packaging' from 'pkg_resources' (/home/user/.local/lib/python3.10/site-packages/pkg_resources/init.p y) [end of output]

maturk commented 2 weeks ago

Do you have error logs?

Is this issue?

This PR is a work-around, but I believe this is a high priority bug for setuptools/packaging to fix.

yeah I agree, it is quite high priority. I think it should be changed in the pyproject.toml as well

abrahamezzeddine commented 2 weeks ago

Do you have error logs?

Is this issue?

This PR is a work-around, but I believe this is a high priority bug for setuptools/packaging to fix.

Please see #3159

pradyunsg commented 1 week ago

FYI: https://github.com/pypa/setuptools/issues/4385

jakepopham commented 1 week ago

69.5.1 is the version previous to 70.0.0.

But using <70 should ensure we get future maintenance updates on version 69.X.X without the breaking changes of 70.