# ModuleNotFoundError: No module named '\_ssl'

**URL:** https://discourse.paraview.org/t/modulenotfounderror-no-module-named-ssl/11578
**Category:** Web Support
**Tags:** web, python, vtk
**Created:** [March 6, 2023, 7:38am UTC](https://discourse.paraview.org/t/modulenotfounderror-no-module-named-ssl/11578 "2023-03-06T07:38:30Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![anshakeel](https://discourse.paraview.org/user_avatar/discourse.paraview.org/anshakeel/32/10709_2.png) [@anshakeel](https://discourse.paraview.org/u/anshakeel)
#### Post date: [March 6, 2023, 7:38am UTC](https://discourse.paraview.org/t/modulenotfounderror-no-module-named-ssl/11578/1 "2023-03-06T07:38:30Z")

</div>

Hello,

**Goal:** I’m trying to implement websockets in **trame** application using paraview as a rendering engine. To implement websockets in trame app, i’m using asyncio to create tasks and execute parallelly. Trame app should act like a listener for websockets connections.

**Error:**  
when I try to execute the application with the following command:  
`pvpython SimpleCone.py --server` it gives me the error that **ModuleNotFoundError: No module named ‘\_ssl’**.

**Detailed Error:**  
(pvenv) C:\Users\Ans.Shakeel\trame-app\trame-tutorial\05\_paraview\> `pvpython SimpleCone.py --server`  
ParaView is using venv: C:\Users\Ans.Shakeel\visualizer-new version\vis\_3\paraview-visualizer\pvenv  
Traceback (most recent call last):  
File “C:\Users\Ans.Shakeel\trame-app\trame-tutorial\05\_paraview\SimpleCone.py”, line 4, in   
import \_ssl  
ModuleNotFoundError: No module named ‘\_ssl’

**Note** : It is working perfectly fine with VTK as rendering engine. According to my understanding, it’s issue in pvpython interpreter. I also tried to import ssl in python shell, the error is following:  
(venv) C:\Users\Ans.Shakeel\trame-app\trame-tutorial\05\_paraview\>pvpython  
Python 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:36:42) [MSC v.1929 64 bit (AMD64)] on win32  
Type “help”, “copyright”, “credits” or “license” for more information.

> > > import \_ssl  
> > > Traceback (most recent call last):  
> > > File “”, line 1, in   
> > > ModuleNotFoundError: No module named ‘\_ssl’  
> > > import ssl  
> > > Traceback (most recent call last):  
> > > File “”, line 1, in   
> > > File “C:\Program Files\ParaView 5.11.0\bin\lib\ssl.py”, line 99, in   
> > > import \_ssl # if we can’t import it, let the error propagate  
> > > ModuleNotFoundError: No module named ‘\_ssl’  
> > > import sys  
> > > print(sys.path)  
> > > [‘’, ‘C:\Program Files\ParaView 5.11.0\bin\Lib\site-packages’, ‘C:\Program Files\ParaView 5.11.0\bin\python39.zip’, ‘C:\Program Files\ParaView 5.11.0\bin\DLLs’, ‘C:\Program Files\ParaView 5.11.0\bin\lib’, ‘C:\Program Files\ParaView 5.11.0\bin’, ‘C:\Program Files\ParaView 5.11.0\bin\lib\site-packages’, ‘C:\Program Files\ParaView 5.11.0\bin\lib\site-packages\win32’, ‘C:\Program Files\ParaView 5.11.0\bin\lib\site-packages\win32\lib’, ‘C:\Program Files\ParaView 5.11.0\bin\lib\site-packages\Pythonwin’]

Regards,  
Ans

---

<div class="post-metadata">

### Author: ![jourdain](https://discourse.paraview.org/user_avatar/discourse.paraview.org/jourdain/32/11_2.png) [@jourdain](https://discourse.paraview.org/u/jourdain)
#### Post date: [March 6, 2023, 5:59pm UTC](https://discourse.paraview.org/t/modulenotfounderror-no-module-named-ssl/11578/2 "2023-03-06T17:59:47Z")

</div>

The Python that get bundled inside ParaView does not include SSL as it will always be out of sync security wise after weeks of release.

If you build ParaView from the superbuild, you can turn ON ssl. We sometime do it as one-off on our CI when we need such binary.

In general, it is better and easier to put a trame app behind a apache/nginx to use https/wss.

HTH,

Seb

---

<div class="post-metadata">

### Author: ![anshakeel](https://discourse.paraview.org/user_avatar/discourse.paraview.org/anshakeel/32/10709_2.png) [@anshakeel](https://discourse.paraview.org/u/anshakeel)
#### Post date: [March 14, 2023, 4:54pm UTC](https://discourse.paraview.org/t/modulenotfounderror-no-module-named-ssl/11578/3 "2023-03-14T16:54:11Z")

</div>

Hi seb, Thanks for your quick answer.

I tried to build ParaView Superbuild to enable SSL so that I can use Web Sockets in Trame application using Paraview behind it. Right now the version **v5.11.1 RC1** is causing pipeline failed so I tried with **v5.11.0**. I successfully installed the ParaView-superbuild with SSL Enabled and also enabled all python modules.

Now when I try to run the Trame application using the pvpython of ParaView-superbuild it is giving me following error: `Paraview is not available`

 ![image](https://discourse.paraview.org/uploads/default/original/2X/1/145bf80ef5a80ff54aff5caab1c2b57e0bdf569b.png)

as a result the UI of the trame app is showing but the render view of paraview is not showing. The image is attached below:

 ![image](https://discourse.paraview.org/uploads/default/original/2X/b/b98a1fa85fa59fe6e1aa5bfa67feee9fa9ffb7b9.png)  
**Note** : For testing I’m running a simple paraview based Time Animation example from trame examples.

> According to my understanding, I missed some important flag while building Paraview-superbuild. If that’s the case, please guide me in the following matter.

Regards,  
Ans

---

<div class="post-metadata">

### Author: ![anshakeel](https://discourse.paraview.org/user_avatar/discourse.paraview.org/anshakeel/32/10709_2.png) [@anshakeel](https://discourse.paraview.org/u/anshakeel)
#### Post date: [March 15, 2023, 10:30am UTC](https://discourse.paraview.org/t/modulenotfounderror-no-module-named-ssl/11578/4 "2023-03-15T10:30:45Z")

</div>

Hello, after rebuilding the paraview super-build multiple times with different flags I finally found the issue. The issue was related to numpy. Enabling **USE\_SYSTEM\_numpy** resolves the problem.

Thanks
