Docker install fails because of python setuptools 24.0.0 fault #143

Closed
opened 2025-12-29 15:35:16 +01:00 by adam · 1 comment
Owner

Originally created by @davecoutts on GitHub (Jul 3, 2016).

The docker install fails during the netbox_netbox image build phase.
It fails while installing the xmltodict package.

...
   File "/usr/local/lib/python2.7/dist-packages/setuptools/msvc.py", line 253, in PlatformInfo
    current_cpu = safe_env['processor_architecture'].lower()
  File "/usr/lib/python2.7/UserDict.py", line 23, in __getitem__
    raise KeyError(key)
  KeyError: 'processor_architecture'
...

This is caused by a known fault in setuptools 24.0.0 as stated here, https://github.com/pypa/setuptools/issues/626

As a workaround until setuptools is fixed you can edit netbox Docker file and pin the setuptools install version to 23.1.0.

...
    && git clone --depth 1 https://github.com/digitalocean/netbox.git -b master . \
    && pip install -U setuptools==23.1.0 \ # < add this line as a workaround
    && pip install -r requirements.txt \
...
Originally created by @davecoutts on GitHub (Jul 3, 2016). The docker install fails during the netbox_netbox image build phase. It fails while installing the xmltodict package. ``` python ... File "/usr/local/lib/python2.7/dist-packages/setuptools/msvc.py", line 253, in PlatformInfo current_cpu = safe_env['processor_architecture'].lower() File "/usr/lib/python2.7/UserDict.py", line 23, in __getitem__ raise KeyError(key) KeyError: 'processor_architecture' ... ``` This is caused by a known fault in setuptools 24.0.0 as stated here, https://github.com/pypa/setuptools/issues/626 As a workaround until setuptools is fixed you can edit netbox Docker file and pin the setuptools install version to 23.1.0. ``` bash ... && git clone --depth 1 https://github.com/digitalocean/netbox.git -b master . \ && pip install -U setuptools==23.1.0 \ # < add this line as a workaround && pip install -r requirements.txt \ ... ```
adam closed this issue 2025-12-29 15:35:17 +01:00
Author
Owner

@davecoutts commented on GitHub (Jul 3, 2016):

Issue resolved with the release of setuptools 24.0.1
https://github.com/pypa/setuptools/pull/627

@davecoutts commented on GitHub (Jul 3, 2016): Issue resolved with the release of setuptools 24.0.1 https://github.com/pypa/setuptools/pull/627
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#143