# using Python shell inside ParaView

**URL:** https://discourse.paraview.org/t/using-python-shell-inside-paraview/11358
**Category:** ParaView Support
**Tags:** python
**Created:** [February 8, 2023, 2:56pm UTC](https://discourse.paraview.org/t/using-python-shell-inside-paraview/11358 "2023-02-08T14:56:04Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Rigel](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/r/8e7dd6/32.png) [@Rigel](https://discourse.paraview.org/u/Rigel)
#### Post date: [February 8, 2023, 2:56pm UTC](https://discourse.paraview.org/t/using-python-shell-inside-paraview/11358/1 "2023-02-08T14:56:05Z")

</div>

Hi,

I am trying to run scripts from ParaView’s built-in Python shell, but I started getting a weird error which was not happening before:

```auto
>>> 
Python 3.9.5 (default, Mar 14 2022, 17:13:12) 
[GCC 7.3.1 20180303 (Red Hat 7.3.1-5)] on linux
>>> import sys
>>> print(sys.path)
['/ccc/scratch/cont003/gen7178/alvesrig/ic3/fine-hex', '/ccc/cont003/home/isae/alvesrig/dhanush/includes', '/ccc/cont003/dsku/blanchet/home/user/isae/alvesrig/ParaView/5.10.1/lib/python39.zip', '/ccc/cont003/dsku/blanchet/home/user/isae/alvesrig/ParaView/5.10.1/lib/python3.9', '/ccc/cont003/dsku/blanchet/home/user/isae/alvesrig/ParaView/5.10.1/lib/python3.9/lib-dynload', '/ccc/cont003/dsku/blanchet/home/user/isae/alvesrig/ParaView/5.10.1/lib/python3.9/site-packages']
>>> from paraview.simple import *
Traceback (most recent call last):
  File "<console>", line 1, in <module>
  File "/ccc/scratch/cont003/gen7178/alvesrig/ic3/fine-hex/paraview.py", line 24, in <module>
    from paraview.simple import *
ModuleNotFoundError: No module named 'paraview.simple'; 'paraview' is not a package
>>>

```

Here is the version I am using:

> Client Information:  
> Version: 5.10.1  
> VTK Version: 9.0.20210922  
> Qt Version: 5.12.9  
> vtkIdType size: 64bits  
> Embedded Python: On  
> Python Library Path: /ccc/cont003/dsku/blanchet/home/user/isae/alvesrig/ParaView/5.10.1/lib/python3.9  
> Python Library Version: 3.9.5 (default, Mar 14 2022, 17:13:12) [GCC 7.3.1 20180303 (Red Hat 7.3.1-5)]  
> Python Numpy Support: On  
> Python Numpy Path: /ccc/cont003/dsku/blanchet/home/user/isae/alvesrig/ParaView/5.10.1/lib/python3.9/site-packages/numpy  
> Python Numpy Version: 1.21.1  
> Python Matplotlib Support: On  
> Python Matplotlib Path: /ccc/cont003/dsku/blanchet/home/user/isae/alvesrig/ParaView/5.10.1/lib/python3.9/site-packages/matplotlib  
> Python Matplotlib Version: 3.2.1  
> Python Testing: Off  
> MPI Enabled: On  
> ParaView Build ID: superbuild 6dd132601dbb2a9ebdc0d31825989f5b92595b76 (!969)  
> Disable Registry: Off  
> Test Directory:  
> Data Directory:  
> SMP Backend: TBB  
> SMP Max Number of Threads: 72  
> OpenGL Vendor: NVIDIA Corporation  
> OpenGL Version: 3.2.0 NVIDIA 440.64.00  
> OpenGL Renderer: Tesla V100-PCIE-32GB/PCIe/SSE2
> 
> Connection Information:  
> Remote Connection: No

It is just the standard version you download from ParaView’s website. Could you help me understand what is causing this issue? Could it be that I am currently using the same ParaView installation in a Slurm job (running at this moment)?

Kind regards,

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [February 8, 2023, 2:59pm UTC](https://discourse.paraview.org/t/using-python-shell-inside-paraview/11358/2 "2023-02-08T14:59:45Z")

</div>

Can you try with the last release, 5.11.0 ?

---

<div class="post-metadata">

### Author: ![Rigel](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/r/8e7dd6/32.png) [@Rigel](https://discourse.paraview.org/u/Rigel)
#### Post date: [February 8, 2023, 3:19pm UTC](https://discourse.paraview.org/t/using-python-shell-inside-paraview/11358/3 "2023-02-08T15:19:24Z")

</div>

Thanks Mathieu for your reply. The problem solved by itself. It can only be that the built-in Python shell gets somehow confused if `pvbatch` (from the same ParaView installation) is running in the background…
