[Paraview] Importing paraview.simple with Python 3

Nicholas Richmond nicholas.richmond at maine.edu
Fri Jun 2 17:50:18 EDT 2017


​Greetings,

First things first, I'm using the most recent (RC3) Win64 ParaView 5.4
binary. I'm working on a project with Python 3.6, and I'm having difficulty
importing the paraview.simple module. Attempting to import (from
paraview.simple import *) results in the following error:

*ImportError: dynamic module does not define module export function
(PyInit_vtkCommonCorePython)*

*During handling of the above exception, another exception occurred:*

*Traceback (most recent call last):*
*  File "<stdin>", line 1, in <module>*
*  File "C:\Program Files\ParaView
5.4.0-RC3-Qt5-OpenGL2-Windows-64bit\bin\Lib\site-packages\paraview\simple.py",
line 43, in <module>*
*    from paraview import servermanager*
*  File "C:\Program Files\ParaView
5.4.0-RC3-Qt5-OpenGL2-Windows-64bit\bin\Lib\site-packages\paraview\servermanager.py",
line 53, in <module>*
*    from paraview import vtk*
*  File "C:\Program Files\ParaView
5.4.0-RC3-Qt5-OpenGL2-Windows-64bit\bin\Lib\site-packages\paraview\vtk\__init__.py",
line 7, in <module>*
*    from paraview.vtk.vtkCommonCore import **
*  File "C:\Program Files\ParaView
5.4.0-RC3-Qt5-OpenGL2-Windows-64bit\bin\Lib\site-packages\paraview\vtk\vtkCommonCore.py",
line 9, in <module>*
*    from vtkCommonCorePython import **
*ImportError: dynamic module does not define module export function
(PyInit_vtkCommonCorePython)*

I saw this March 10 message from Utkarsh:

"*Python 3 is supported with 5.3 (except for ParaViewWeb components). We **have
dashboards testing it too. There still may be some leftovers, so **please
report if you catch anything that we missed.*"

Does this fall under the category of "please report if you catch anything
that we missed" or is it due to a lack of understanding on my part? I've
been able to successfully import this module when using a Python 2.7
environment, but I'm trying to stick to Python 3.6. Any insight would be
most appreciated.

Many thanks,
Nick Richmond
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20170602/fec5147a/attachment.html>


More information about the ParaView mailing list