Showing results for 
Search instead for 
Did you mean: 

AttributeError: module 'socket' has no attribute 'SO_REUSEPORT'

Both the 2020.1 and 2020.2 release give me an error when I use SO_REUSEPORT:

$ python3 --version
Python 3.7.7 :: Intel(R) Corporation

$ ipython3
Python 3.7.7 (default, Jun 26 2020, 05:10:03) 
Type 'copyright', 'credits' or 'license' for more information
IPython 7.17.0 -- An enhanced Interactive Python. Type '?' for help.

In [1]: import socket

In [2]: s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM, socket.IPPROTO_UDP)

In [3]: s.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEPORT, True) 
AttributeError Traceback (most recent call last)
<ipython-input-3-abe33f584d23> in <module>
----> 1 s.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEPORT, True)

AttributeError: module 'socket' has no attribute 'SO_REUSEPORT'

I am installing through Anaconda on Ubuntu 20.04.

If I create a conda virtual environment without INTEL using the same python version 3.7.7, I have the same issue so perhaps it's a problem with the base Anaconda Python version?

I do not have this issue with the current Anaconda Python 3.8.5 (non-Intel obviously).

Also, if I pull a docker image for Python 3.7.8 (non-Intel) I don't have this problem.

(I can't find an Anaconda Python 3.7.8, nor a docker Python 3.7.7, so I can't isolate the problem to Anaconda or the 3.7.7.)


Assuming this is not fixable in the current Intel Python release, is Intel planning to switch to Python 3.8 for the next release?


Labels (1)
Tags (1)
0 Kudos
1 Reply


Thank you for posting in Intel Forum.

We could reproduce your issue in python 3.7.7.We will inform this to the concerned team. However we observed that the issue is not present in the older version python 3.6.3. As a workaround, you can use the older version. We are forwarding this query to the concerned team so that they will help you with the future release plan.



0 Kudos