enthought / mayavi

3D visualization of scientific data in Python
http://docs.enthought.com/mayavi/mayavi/
Other
1.3k stars 284 forks source link

Mayavi fails building on Ubuntu 22 LTS #1156

Closed Becheler closed 2 years ago

Becheler commented 2 years ago

It seems there is a dependency conflict between:

I struggle identifying the exact cause of the build failing.

Collecting mayavi
  Using cached mayavi-4.7.4.tar.gz (7.1 MB)
  Preparing metadata (setup.py) ... done
Requirement already satisfied: apptools in ./virtual-environment/lib/python3.10/site-packages (from mayavi) (5.1.0)
Requirement already satisfied: envisage in ./virtual-environment/lib/python3.10/site-packages (from mayavi) (6.0.1)
Requirement already satisfied: numpy in ./virtual-environment/lib/python3.10/site-packages (from mayavi) (1.23.0)
Requirement already satisfied: pyface>=6.1.1 in ./virtual-environment/lib/python3.10/site-packages (from mayavi) (7.4.1)
Requirement already satisfied: pygments in ./virtual-environment/lib/python3.10/site-packages (from mayavi) (2.12.0)
Requirement already satisfied: traits>=6.0.0 in ./virtual-environment/lib/python3.10/site-packages (from mayavi) (6.3.2)
Requirement already satisfied: traitsui>=7.0.0 in ./virtual-environment/lib/python3.10/site-packages (from mayavi) (7.3.1)
Requirement already satisfied: vtk in ./virtual-environment/lib/python3.10/site-packages (from mayavi) (9.2.0rc1)
Requirement already satisfied: configobj in ./virtual-environment/lib/python3.10/site-packages (from apptools->mayavi) (5.0.6)
Requirement already satisfied: setuptools in ./virtual-environment/lib/python3.10/site-packages (from envisage->mayavi) (59.6.0)
Requirement already satisfied: wslink>=1.0.4 in ./virtual-environment/lib/python3.10/site-packages (from vtk->mayavi) (1.6.5)
Requirement already satisfied: matplotlib>=2.0.0 in ./virtual-environment/lib/python3.10/site-packages (from vtk->mayavi) (3.5.2)
Requirement already satisfied: fonttools>=4.22.0 in ./virtual-environment/lib/python3.10/site-packages (from matplotlib>=2.0.0->vtk->mayavi) (4.33.3)
Requirement already satisfied: pillow>=6.2.0 in ./virtual-environment/lib/python3.10/site-packages (from matplotlib>=2.0.0->vtk->mayavi) (9.1.1)
Requirement already satisfied: packaging>=20.0 in ./virtual-environment/lib/python3.10/site-packages (from matplotlib>=2.0.0->vtk->mayavi) (21.3)
Requirement already satisfied: python-dateutil>=2.7 in ./virtual-environment/lib/python3.10/site-packages (from matplotlib>=2.0.0->vtk->mayavi) (2.8.2)
Requirement already satisfied: pyparsing>=2.2.1 in ./virtual-environment/lib/python3.10/site-packages (from matplotlib>=2.0.0->vtk->mayavi) (3.0.9)
Requirement already satisfied: kiwisolver>=1.0.1 in ./virtual-environment/lib/python3.10/site-packages (from matplotlib>=2.0.0->vtk->mayavi) (1.4.3)
Requirement already satisfied: cycler>=0.10 in ./virtual-environment/lib/python3.10/site-packages (from matplotlib>=2.0.0->vtk->mayavi) (0.11.0)
Requirement already satisfied: aiohttp in ./virtual-environment/lib/python3.10/site-packages (from wslink>=1.0.4->vtk->mayavi) (3.8.1)
Requirement already satisfied: six in ./virtual-environment/lib/python3.10/site-packages (from configobj->apptools->mayavi) (1.16.0)
Requirement already satisfied: attrs>=17.3.0 in ./virtual-environment/lib/python3.10/site-packages (from aiohttp->wslink>=1.0.4->vtk->mayavi) (21.4.0)
Requirement already satisfied: aiosignal>=1.1.2 in ./virtual-environment/lib/python3.10/site-packages (from aiohttp->wslink>=1.0.4->vtk->mayavi) (1.2.0)
Requirement already satisfied: yarl<2.0,>=1.0 in ./virtual-environment/lib/python3.10/site-packages (from aiohttp->wslink>=1.0.4->vtk->mayavi) (1.7.2)
Requirement already satisfied: frozenlist>=1.1.1 in ./virtual-environment/lib/python3.10/site-packages (from aiohttp->wslink>=1.0.4->vtk->mayavi) (1.3.0)
Requirement already satisfied: async-timeout<5.0,>=4.0.0a3 in ./virtual-environment/lib/python3.10/site-packages (from aiohttp->wslink>=1.0.4->vtk->mayavi) (4.0.2)
Requirement already satisfied: charset-normalizer<3.0,>=2.0 in ./virtual-environment/lib/python3.10/site-packages (from aiohttp->wslink>=1.0.4->vtk->mayavi) (2.0.12)
Requirement already satisfied: multidict<7.0,>=4.5 in ./virtual-environment/lib/python3.10/site-packages (from aiohttp->wslink>=1.0.4->vtk->mayavi) (6.0.2)
Requirement already satisfied: idna>=2.0 in ./virtual-environment/lib/python3.10/site-packages (from yarl<2.0,>=1.0->aiohttp->wslink>=1.0.4->vtk->mayavi) (3.3)
Building wheels for collected packages: mayavi
  Building wheel for mayavi (setup.py) ... error
  error: subprocess-exited-with-error

  × python setup.py bdist_wheel did not run successfully.
  │ exit code: -11
  ╰─> [166 lines of output]
      /tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/setup.py:13: DeprecationWarning:

        `numpy.distutils` is deprecated since NumPy 1.23.0, as a result
        of the deprecation of `distutils` itself. It will be removed for
        Python >= 3.12. For older Python versions it will remain present.
        It is recommended to use `setuptools < 60.0` for those Python versions.
        For more details, see:
          https://numpy.org/devdocs/reference/distutils_status_migration.html

        from numpy.distutils.command import build, install_data
      running bdist_wheel
      running build
      ----------------------------------------------------------------------
      Building TVTK classes... vtkAnimationCue: Ignoring method: Get/SetDirection
      default: 1, range: None
      vtkContextDevice2D: Ignoring method: Get/SetViewportRect
      default: [-1, 2146435071, -1, 2146435071], range: None
      vtkContextDevice2D: Ignoring method: Get/SetViewportSize
      default: [-1, 2146435071], range: None
      vtkEventDataForDevice: Ignoring method: Get/SetAction
      default: -1, range: None
      vtkEventDataForDevice: Ignoring method: Get/SetDevice
      default: -1, range: None
      vtkFXAAOptions: Ignoring method: Get/SetDebugOptionValue
      default: 0, range: None
      vtkIncrementalForceLayout: Ignoring method: Get/SetGravityPoint
      default: [200.0, 200.0], range: None
      vtkOpenGLBufferObject: Ignoring method: Get/SetType
      default: 0, range: None
      vtkOpenGLFXAAFilter: Ignoring method: Get/SetDebugOptionValue
      default: 0, range: None
      vtkRenderWidget: Ignoring method: Get/SetPosition
      default: [0, 0], range: None
      vtkRenderWidget: Ignoring method: Get/SetSize
      default: [300, 300], range: None
      vtkShader: Ignoring method: Get/SetType
      default: 3, range: None
      vtkVolumeTexture: Ignoring method: Get/SetPartitions
      default: [1, 1, 1], range: None
      vtkChartMatrix: Ignoring method: Get/SetFillStrategy
      default: 0, range: None
      vtkChartMatrix: Ignoring method: Get/SetGutter
      default: [15.0, 15.0], range: None
      vtkChartMatrix: Ignoring method: Get/SetRect
      default: [0, 0, 100, 100], range: None
      vtkChartMatrix: Ignoring method: Get/SetSize
      default: [0, 0], range: None
      vtkContextArea: Ignoring method: Get/SetDrawAreaBounds
      default: [0.0, 0.0, 300.0, 300.0], range: None
      vtkContextArea: Ignoring method: Get/SetDrawAreaResizeBehavior
      default: 0, range: None
      vtkContextArea: Ignoring method: Get/SetFixedMargins
      default: [0, 0, 0, 0], range: None
      vtkContextArea: Ignoring method: Get/SetFixedRect
      default: [0, 0, 300, 300], range: None
      vtkContextArea: Ignoring method: Get/SetGeometry
      default: [0, 0, 300, 300], range: None
      vtkImplicitProjectOnPlaneDistance: Ignoring method: Get/SetNorm
      default: 2, range: None
      vtkOpenGLVertexBufferObject: Ignoring method: Get/SetCoordShiftAndScaleMethod
      default: 0, range: None
      vtkSimple3DCirclesStrategy: Ignoring method: Get/SetMarkedValue
      default: (invalid), range: None
      vtkArrayNorm: Ignoring method: Get/SetWindow
      default: [0, 9223372036854775807), range: None
      vtkChart: Ignoring method: Get/SetSize
      default: [0.0, 0.0, 0.0, 0.0], range: None
      vtkChartXYZ: Ignoring method: Get/SetAxisColor
      default: [0, 0, 0, 255], range: None
      vtkEuclideanClusterExtraction: Radius not updatable (VTK 9.1 bug - value not properly initialized)
      Warning: We cannot determine the trait type of vtkHigherOrderHexahedron.Order
      Warning: We cannot determine the trait type of vtkHigherOrderQuadrilateral.Order
      Warning: We cannot determine the trait type of vtkHigherOrderWedge.Order
      vtkHyperTreeGridPreConfiguredSource: Ignoring method: Get/SetCustomArchitecture
      default: 0, range: None
      vtkHyperTreeGridPreConfiguredSource: Ignoring method: Get/SetHTGMode
      default: 0, range: None
      vtkLightingMapPass: Ignoring method: Get/SetRenderType
      default: 0, range: None
      vtkPlot: Ignoring method: Get/SetShiftScale
      default: [0.0, 0.0, 1.0, 1.0], range: None
      vtkScatterPlotMatrix: Ignoring method: Get/SetActivePlot
      default: [0, -2], range: None
      vtkScatterPlotMatrix: Ignoring method: Get/SetScatterPlotSelectedActiveColor
      default: [0, 204, 0, 102], range: None
      vtkScatterPlotMatrix: Ignoring method: Get/SetScatterPlotSelectedRowColumnColor
      default: [204, 0, 0, 102], range: None
      vtkScatterPlotMatrix: Ignoring method: Get/SetSize
      default: [0, 0], range: None
      vtkSparseArray_I10vtkVariantE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_I10vtkVariantE: Ignoring method: Get/SetNullValue
      default: (invalid), range: None
      vtkSparseArray_I12vtkStdStringE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IaE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IcE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IdE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IfE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IhE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IiE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IjE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IlE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_ImE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IsE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_ItE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IxE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IyE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkThresholdTable: Ignoring method: Get/SetMaxValue
      default: 2147483647, range: None
      vtkThresholdTable: Ignoring method: Get/SetMinValue
      default: 0, range: None
      vtkTransferAttributes: Ignoring method: Get/SetDefaultValue
      default: 1, range: None
      Bad to call vtkUniformHyperTreeGrid::GetXCoordinates
      Bad to call vtkUniformHyperTreeGrid::GetYCoordinates
      Bad to call vtkUniformHyperTreeGrid::GetZCoordinates
      vtkChartBox: Ignoring method: Get/SetSize
      default: [0.0, 0.0, 0.0, 0.0], range: None
      vtkColorLegend: Ignoring method: Get/SetPosition
      default: [0.0, 0.0, 0.0, 0.0], range: None
      Warning: We cannot determine the trait type of vtkImageMask.MaskedOutputValue
      vtkMolecule: Ignoring method: Get/SetLatticeOrigin
      default: [0.0, 0.0, 0.0], range: None
      vtkPOpenFOAMReader: Ignoring method: Get/SetCaseType
      default: 1, range: None
      Fatal Python error: Segmentation fault

      Current thread 0x00007f27c5e30000 (most recent call first):
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/vtk_parser.py", line 705 in _find_get_set_methods
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/vtk_parser.py", line 488 in _organize_methods
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/vtk_parser.py", line 154 in parse
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/wrapper_gen.py", line 341 in _gen_methods
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/wrapper_gen.py", line 242 in generate_code
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/code_gen.py", line 235 in _write_wrapper_class
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/code_gen.py", line 142 in generate_code
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/setup.py", line 98 in gen_tvtk_classes_zip
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/setup.py", line 254 in build_tvtk_classes_zip
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/setup.py", line 268 in run
        File "/usr/lib/python3.10/distutils/dist.py", line 985 in run_command
        File "/usr/lib/python3.10/distutils/cmd.py", line 313 in run_command
        File "/home/becheler/dev/quetzal-CRUMBS/virtual-environment/lib/python3.10/site-packages/wheel/bdist_wheel.py", line 299 in run
        File "/usr/lib/python3.10/distutils/dist.py", line 985 in run_command
        File "/usr/lib/python3.10/distutils/dist.py", line 966 in run_commands
        File "/usr/lib/python3.10/distutils/core.py", line 148 in setup
        File "/home/becheler/dev/quetzal-CRUMBS/virtual-environment/lib/python3.10/site-packages/setuptools/__init__.py", line 153 in setup
        File "/home/becheler/dev/quetzal-CRUMBS/virtual-environment/lib/python3.10/site-packages/numpy/distutils/core.py", line 169 in setup
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/setup.py", line 411 in <module>
        File "<pip-setuptools-caller>", line 34 in <module>
        File "<string>", line 2 in <module>

      Extension modules: numpy.core._multiarray_umath, numpy.core._multiarray_tests, numpy.linalg._umath_linalg, numpy.fft._pocketfft_internal, numpy.random._common, numpy.random.bit_generator, numpy.random._bounded_integers, numpy.random._mt19937, numpy.random.mtrand, numpy.random._philox, numpy.random._pcg64, numpy.random._sfc64, numpy.random._generator, vtkmodules.vtkCommonCore, vtkmodules.vtkWebCore, vtkmodules.vtkCommonMath, vtkmodules.vtkCommonTransforms, vtkmodules.vtkCommonDataModel, vtkmodules.vtkCommonExecutionModel, vtkmodules.vtkIOCore, vtkmodules.vtkImagingCore, vtkmodules.vtkIOImage, vtkmodules.vtkIOXMLParser, vtkmodules.vtkIOXML, vtkmodules.vtkCommonMisc, vtkmodules.vtkFiltersCore, vtkmodules.vtkRenderingCore, vtkmodules.vtkRenderingContext2D, vtkmodules.vtkRenderingFreeType, vtkmodules.vtkRenderingSceneGraph, vtkmodules.vtkRenderingVtkJS, vtkmodules.vtkIOExport, vtkmodules.vtkWebGLExporter, vtkmodules.vtkInteractionStyle, vtkmodules.vtkFiltersGeneral, vtkmodules.vtkFiltersSources, vtkmodules.vtkInteractionWidgets, vtkmodules.vtkViewsCore, vtkmodules.vtkViewsInfovis, vtkmodules.vtkCommonComputationalGeometry, vtkmodules.vtkCommonSystem, vtkmodules.vtkIOLegacy, vtkmodules.vtkDomainsChemistry, vtkmodules.vtkRenderingHyperTreeGrid, vtkmodules.vtkRenderingUI, vtkmodules.vtkRenderingOpenGL2, vtkmodules.vtkRenderingContextOpenGL2, vtkmodules.vtkRenderingVolume, vtkmodules.vtkImagingMath, vtkmodules.vtkRenderingVolumeOpenGL2, vtkmodules.vtkViewsContext2D, vtkmodules.vtkTestingRendering, vtkmodules.vtkRenderingVolumeAMR, vtkmodules.vtkPythonContext2D, vtkmodules.vtkRenderingParallel, vtkmodules.vtkRenderingVR, vtkmodules.vtkRenderingMatplotlib, vtkmodules.vtkRenderingLabel, vtkmodules.vtkRenderingLOD, vtkmodules.vtkRenderingLICOpenGL2, vtkmodules.vtkRenderingImage, vtkmodules.vtkRenderingExternal, vtkmodules.vtkIOXdmf2, vtkmodules.vtkIOVeraOut, vtkmodules.vtkIOVPIC, vtkmodules.vtkIOTecplotTable, vtkmodules.vtkIOTRUCHAS, vtkmodules.vtkIOSegY, vtkmodules.vtkIOParallelXML, vtkmodules.vtkIOLSDyna, vtkmodules.vtkIOParallelLSDyna, vtkmodules.vtkIOExodus, vtkmodules.vtkIOParallelExodus, vtkmodules.vtkIOPLY, vtkmodules.vtkIOPIO, vtkmodules.vtkIOMovie, vtkmodules.vtkIOOggTheora, vtkmodules.vtkIOOMF, vtkmodules.vtkIONetCDF, vtkmodules.vtkIOMotionFX, vtkmodules.vtkIOGeometry, vtkmodules.vtkIOParallel, vtkmodules.vtkIOMINC, vtkmodules.vtkIOInfovis, vtkmodules.vtkIOImport, vtkmodules.vtkParallelCore, vtkmodules.vtkIOIOSS, vtkmodules.vtkIOH5part, vtkmodules.vtkIOH5Rage, vtkmodules.vtkIOGeoJSON, vtkmodules.vtkIOVideo, vtkmodules.vtkIOExportPDF, vtkmodules.vtkRenderingGL2PSOpenGL2, vtkmodules.vtkIOExportGL2PS, vtkmodules.vtkIOEnSight, vtkmodules.vtkIOCityGML, vtkmodules.vtkIOChemistry, vtkmodules.vtkIOCesium3DTiles, vtkmodules.vtkIOCONVERGECFD, vtkmodules.vtkIOHDF, vtkmodules.vtkIOCGNSReader, vtkmodules.vtkIOAsynchronous, vtkmodules.vtkIOAMR, vtkmodules.vtkInteractionImage, vtkmodules.vtkImagingStencil, vtkmodules.vtkImagingStatistics, vtkmodules.vtkImagingGeneral, vtkmodules.vtkImagingOpenGL2, vtkmodules.vtkImagingMorphological, vtkmodules.vtkImagingFourier, vtkmodules.vtkIOSQL, vtkmodules.vtkCommonColor, vtkmodules.vtkImagingSources, vtkmodules.vtkInfovisCore, vtkmodules.vtkGeovisCore, vtkmodules.vtkInfovisLayout, vtkmodules.vtkRenderingAnnotation, vtkmodules.vtkImagingHybrid, vtkmodules.vtkImagingColor, vtkmodules.vtkFiltersTopology, vtkmodules.vtkFiltersSelection, vtkmodules.vtkFiltersSMP, vtkmodules.vtkFiltersPython, vtkmodules.vtkFiltersProgrammable, vtkmodules.vtkFiltersModeling, vtkmodules.vtkFiltersPoints, vtkmodules.vtkFiltersVerdict, vtkmodules.vtkFiltersStatistics, vtkmodules.vtkFiltersParallelStatistics, vtkmodules.vtkFiltersImaging, vtkmodules.vtkFiltersExtraction, vtkmodules.vtkFiltersGeometry, vtkmodules.vtkFiltersHybrid, vtkmodules.vtkFiltersTexture, vtkmodules.vtkFiltersParallel, vtkmodules.vtkFiltersParallelImaging, vtkmodules.vtkFiltersParallelDIY2, vtkmodules.vtkFiltersGeneric, vtkmodules.vtkFiltersFlowPaths, vtkmodules.vtkFiltersAMR, vtkmodules.vtkDomainsChemistryOpenGL2, vtkmodules.vtkFiltersHyperTree, vtkmodules.vtkCommonPython, vtkmodules.vtkChartsCore, vtkmodules.vtkAcceleratorsVTKmCore, vtkmodules.vtkAcceleratorsVTKmDataModel, vtkmodules.vtkAcceleratorsVTKmFilters (total: 147)
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for mayavi
  Running setup.py clean for mayavi
Failed to build mayavi
Installing collected packages: mayavi
  Running setup.py install for mayavi ... error
  error: subprocess-exited-with-error

  × Running setup.py install for mayavi did not run successfully.
  │ exit code: -11
  ╰─> [170 lines of output]
      /tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/setup.py:13: DeprecationWarning:

        `numpy.distutils` is deprecated since NumPy 1.23.0, as a result
        of the deprecation of `distutils` itself. It will be removed for
        Python >= 3.12. For older Python versions it will remain present.
        It is recommended to use `setuptools < 60.0` for those Python versions.
        For more details, see:
          https://numpy.org/devdocs/reference/distutils_status_migration.html

        from numpy.distutils.command import build, install_data
      running install
      /home/becheler/dev/quetzal-CRUMBS/virtual-environment/lib/python3.10/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
        warnings.warn(
      running build
      ----------------------------------------------------------------------
      Building TVTK classes... vtkAnimationCue: Ignoring method: Get/SetDirection
      default: 1, range: None
      vtkContextDevice2D: Ignoring method: Get/SetViewportRect
      default: [-1, 2146435071, -1, 2146435071], range: None
      vtkContextDevice2D: Ignoring method: Get/SetViewportSize
      default: [-1, 2146435071], range: None
      vtkEventDataForDevice: Ignoring method: Get/SetAction
      default: -1, range: None
      vtkEventDataForDevice: Ignoring method: Get/SetDevice
      default: -1, range: None
      vtkFXAAOptions: Ignoring method: Get/SetDebugOptionValue
      default: 0, range: None
      vtkIncrementalForceLayout: Ignoring method: Get/SetGravityPoint
      default: [200.0, 200.0], range: None
      vtkOpenGLBufferObject: Ignoring method: Get/SetType
      default: 0, range: None
      vtkOpenGLFXAAFilter: Ignoring method: Get/SetDebugOptionValue
      default: 0, range: None
      vtkRenderWidget: Ignoring method: Get/SetPosition
      default: [0, 0], range: None
      vtkRenderWidget: Ignoring method: Get/SetSize
      default: [300, 300], range: None
      vtkShader: Ignoring method: Get/SetType
      default: 3, range: None
      vtkVolumeTexture: Ignoring method: Get/SetPartitions
      default: [1, 1, 1], range: None
      vtkChartMatrix: Ignoring method: Get/SetFillStrategy
      default: 0, range: None
      vtkChartMatrix: Ignoring method: Get/SetGutter
      default: [15.0, 15.0], range: None
      vtkChartMatrix: Ignoring method: Get/SetRect
      default: [0, 0, 100, 100], range: None
      vtkChartMatrix: Ignoring method: Get/SetSize
      default: [0, 0], range: None
      vtkContextArea: Ignoring method: Get/SetDrawAreaBounds
      default: [0.0, 0.0, 300.0, 300.0], range: None
      vtkContextArea: Ignoring method: Get/SetDrawAreaResizeBehavior
      default: 0, range: None
      vtkContextArea: Ignoring method: Get/SetFixedMargins
      default: [0, 0, 0, 0], range: None
      vtkContextArea: Ignoring method: Get/SetFixedRect
      default: [0, 0, 300, 300], range: None
      vtkContextArea: Ignoring method: Get/SetGeometry
      default: [0, 0, 300, 300], range: None
      vtkImplicitProjectOnPlaneDistance: Ignoring method: Get/SetNorm
      default: 2, range: None
      vtkOpenGLVertexBufferObject: Ignoring method: Get/SetCoordShiftAndScaleMethod
      default: 0, range: None
      vtkSimple3DCirclesStrategy: Ignoring method: Get/SetMarkedValue
      default: (invalid), range: None
      vtkArrayNorm: Ignoring method: Get/SetWindow
      default: [0, 9223372036854775807), range: None
      vtkChart: Ignoring method: Get/SetSize
      default: [0.0, 0.0, 0.0, 0.0], range: None
      vtkChartXYZ: Ignoring method: Get/SetAxisColor
      default: [0, 0, 0, 255], range: None
      vtkEuclideanClusterExtraction: Radius not updatable (VTK 9.1 bug - value not properly initialized)
      Warning: We cannot determine the trait type of vtkHigherOrderHexahedron.Order
      Warning: We cannot determine the trait type of vtkHigherOrderQuadrilateral.Order
      Warning: We cannot determine the trait type of vtkHigherOrderWedge.Order
      vtkHyperTreeGridPreConfiguredSource: Ignoring method: Get/SetCustomArchitecture
      default: 0, range: None
      vtkHyperTreeGridPreConfiguredSource: Ignoring method: Get/SetHTGMode
      default: 0, range: None
      vtkLightingMapPass: Ignoring method: Get/SetRenderType
      default: 0, range: None
      vtkPlot: Ignoring method: Get/SetShiftScale
      default: [0.0, 0.0, 1.0, 1.0], range: None
      vtkScatterPlotMatrix: Ignoring method: Get/SetActivePlot
      default: [0, -2], range: None
      vtkScatterPlotMatrix: Ignoring method: Get/SetScatterPlotSelectedActiveColor
      default: [0, 204, 0, 102], range: None
      vtkScatterPlotMatrix: Ignoring method: Get/SetScatterPlotSelectedRowColumnColor
      default: [204, 0, 0, 102], range: None
      vtkScatterPlotMatrix: Ignoring method: Get/SetSize
      default: [0, 0], range: None
      vtkSparseArray_I10vtkVariantE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_I10vtkVariantE: Ignoring method: Get/SetNullValue
      default: (invalid), range: None
      vtkSparseArray_I12vtkStdStringE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IaE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IcE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IdE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IfE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IhE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IiE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IjE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IlE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_ImE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IsE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_ItE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IxE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkSparseArray_IyE: Ignoring method: Get/SetExtents
      default: , range: None
      vtkThresholdTable: Ignoring method: Get/SetMaxValue
      default: 2147483647, range: None
      vtkThresholdTable: Ignoring method: Get/SetMinValue
      default: 0, range: None
      vtkTransferAttributes: Ignoring method: Get/SetDefaultValue
      default: 1, range: None
      Bad to call vtkUniformHyperTreeGrid::GetXCoordinates
      Bad to call vtkUniformHyperTreeGrid::GetYCoordinates
      Bad to call vtkUniformHyperTreeGrid::GetZCoordinates
      vtkChartBox: Ignoring method: Get/SetSize
      default: [0.0, 0.0, 0.0, 0.0], range: None
      vtkColorLegend: Ignoring method: Get/SetPosition
      default: [0.0, 0.0, 0.0, 0.0], range: None
      Warning: We cannot determine the trait type of vtkImageMask.MaskedOutputValue
      vtkMolecule: Ignoring method: Get/SetLatticeOrigin
      default: [0.0, 0.0, 0.0], range: None
      vtkPOpenFOAMReader: Ignoring method: Get/SetCaseType
      default: 1, range: None
      Fatal Python error: Segmentation fault

      Current thread 0x00007fb9fb480000 (most recent call first):
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/vtk_parser.py", line 705 in _find_get_set_methods
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/vtk_parser.py", line 488 in _organize_methods
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/vtk_parser.py", line 154 in parse
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/wrapper_gen.py", line 341 in _gen_methods
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/wrapper_gen.py", line 242 in generate_code
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/code_gen.py", line 235 in _write_wrapper_class
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/code_gen.py", line 142 in generate_code
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/tvtk/setup.py", line 98 in gen_tvtk_classes_zip
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/setup.py", line 254 in build_tvtk_classes_zip
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/setup.py", line 268 in run
        File "/usr/lib/python3.10/distutils/dist.py", line 985 in run_command
        File "/usr/lib/python3.10/distutils/cmd.py", line 313 in run_command
        File "/usr/lib/python3.10/distutils/command/install.py", line 619 in run
        File "/home/becheler/dev/quetzal-CRUMBS/virtual-environment/lib/python3.10/site-packages/numpy/distutils/command/install.py", line 34 in setuptools_run
        File "/home/becheler/dev/quetzal-CRUMBS/virtual-environment/lib/python3.10/site-packages/numpy/distutils/command/install.py", line 60 in run
        File "/usr/lib/python3.10/distutils/dist.py", line 985 in run_command
        File "/usr/lib/python3.10/distutils/dist.py", line 966 in run_commands
        File "/usr/lib/python3.10/distutils/core.py", line 148 in setup
        File "/home/becheler/dev/quetzal-CRUMBS/virtual-environment/lib/python3.10/site-packages/setuptools/__init__.py", line 153 in setup
        File "/home/becheler/dev/quetzal-CRUMBS/virtual-environment/lib/python3.10/site-packages/numpy/distutils/core.py", line 169 in setup
        File "/tmp/pip-install-ph0k75v1/mayavi_9ffb190a517e48caa60837657c1569b7/setup.py", line 411 in <module>
        File "<pip-setuptools-caller>", line 34 in <module>
        File "<string>", line 2 in <module>

      Extension modules: numpy.core._multiarray_umath, numpy.core._multiarray_tests, numpy.linalg._umath_linalg, numpy.fft._pocketfft_internal, numpy.random._common, numpy.random.bit_generator, numpy.random._bounded_integers, numpy.random._mt19937, numpy.random.mtrand, numpy.random._philox, numpy.random._pcg64, numpy.random._sfc64, numpy.random._generator, vtkmodules.vtkCommonCore, vtkmodules.vtkWebCore, vtkmodules.vtkCommonMath, vtkmodules.vtkCommonTransforms, vtkmodules.vtkCommonDataModel, vtkmodules.vtkCommonExecutionModel, vtkmodules.vtkIOCore, vtkmodules.vtkImagingCore, vtkmodules.vtkIOImage, vtkmodules.vtkIOXMLParser, vtkmodules.vtkIOXML, vtkmodules.vtkCommonMisc, vtkmodules.vtkFiltersCore, vtkmodules.vtkRenderingCore, vtkmodules.vtkRenderingContext2D, vtkmodules.vtkRenderingFreeType, vtkmodules.vtkRenderingSceneGraph, vtkmodules.vtkRenderingVtkJS, vtkmodules.vtkIOExport, vtkmodules.vtkWebGLExporter, vtkmodules.vtkInteractionStyle, vtkmodules.vtkFiltersGeneral, vtkmodules.vtkFiltersSources, vtkmodules.vtkInteractionWidgets, vtkmodules.vtkViewsCore, vtkmodules.vtkViewsInfovis, vtkmodules.vtkCommonComputationalGeometry, vtkmodules.vtkCommonSystem, vtkmodules.vtkIOLegacy, vtkmodules.vtkDomainsChemistry, vtkmodules.vtkRenderingHyperTreeGrid, vtkmodules.vtkRenderingUI, vtkmodules.vtkRenderingOpenGL2, vtkmodules.vtkRenderingContextOpenGL2, vtkmodules.vtkRenderingVolume, vtkmodules.vtkImagingMath, vtkmodules.vtkRenderingVolumeOpenGL2, vtkmodules.vtkViewsContext2D, vtkmodules.vtkTestingRendering, vtkmodules.vtkRenderingVolumeAMR, vtkmodules.vtkPythonContext2D, vtkmodules.vtkRenderingParallel, vtkmodules.vtkRenderingVR, vtkmodules.vtkRenderingMatplotlib, vtkmodules.vtkRenderingLabel, vtkmodules.vtkRenderingLOD, vtkmodules.vtkRenderingLICOpenGL2, vtkmodules.vtkRenderingImage, vtkmodules.vtkRenderingExternal, vtkmodules.vtkIOXdmf2, vtkmodules.vtkIOVeraOut, vtkmodules.vtkIOVPIC, vtkmodules.vtkIOTecplotTable, vtkmodules.vtkIOTRUCHAS, vtkmodules.vtkIOSegY, vtkmodules.vtkIOParallelXML, vtkmodules.vtkIOLSDyna, vtkmodules.vtkIOParallelLSDyna, vtkmodules.vtkIOExodus, vtkmodules.vtkIOParallelExodus, vtkmodules.vtkIOPLY, vtkmodules.vtkIOPIO, vtkmodules.vtkIOMovie, vtkmodules.vtkIOOggTheora, vtkmodules.vtkIOOMF, vtkmodules.vtkIONetCDF, vtkmodules.vtkIOMotionFX, vtkmodules.vtkIOGeometry, vtkmodules.vtkIOParallel, vtkmodules.vtkIOMINC, vtkmodules.vtkIOInfovis, vtkmodules.vtkIOImport, vtkmodules.vtkParallelCore, vtkmodules.vtkIOIOSS, vtkmodules.vtkIOH5part, vtkmodules.vtkIOH5Rage, vtkmodules.vtkIOGeoJSON, vtkmodules.vtkIOVideo, vtkmodules.vtkIOExportPDF, vtkmodules.vtkRenderingGL2PSOpenGL2, vtkmodules.vtkIOExportGL2PS, vtkmodules.vtkIOEnSight, vtkmodules.vtkIOCityGML, vtkmodules.vtkIOChemistry, vtkmodules.vtkIOCesium3DTiles, vtkmodules.vtkIOCONVERGECFD, vtkmodules.vtkIOHDF, vtkmodules.vtkIOCGNSReader, vtkmodules.vtkIOAsynchronous, vtkmodules.vtkIOAMR, vtkmodules.vtkInteractionImage, vtkmodules.vtkImagingStencil, vtkmodules.vtkImagingStatistics, vtkmodules.vtkImagingGeneral, vtkmodules.vtkImagingOpenGL2, vtkmodules.vtkImagingMorphological, vtkmodules.vtkImagingFourier, vtkmodules.vtkIOSQL, vtkmodules.vtkCommonColor, vtkmodules.vtkImagingSources, vtkmodules.vtkInfovisCore, vtkmodules.vtkGeovisCore, vtkmodules.vtkInfovisLayout, vtkmodules.vtkRenderingAnnotation, vtkmodules.vtkImagingHybrid, vtkmodules.vtkImagingColor, vtkmodules.vtkFiltersTopology, vtkmodules.vtkFiltersSelection, vtkmodules.vtkFiltersSMP, vtkmodules.vtkFiltersPython, vtkmodules.vtkFiltersProgrammable, vtkmodules.vtkFiltersModeling, vtkmodules.vtkFiltersPoints, vtkmodules.vtkFiltersVerdict, vtkmodules.vtkFiltersStatistics, vtkmodules.vtkFiltersParallelStatistics, vtkmodules.vtkFiltersImaging, vtkmodules.vtkFiltersExtraction, vtkmodules.vtkFiltersGeometry, vtkmodules.vtkFiltersHybrid, vtkmodules.vtkFiltersTexture, vtkmodules.vtkFiltersParallel, vtkmodules.vtkFiltersParallelImaging, vtkmodules.vtkFiltersParallelDIY2, vtkmodules.vtkFiltersGeneric, vtkmodules.vtkFiltersFlowPaths, vtkmodules.vtkFiltersAMR, vtkmodules.vtkDomainsChemistryOpenGL2, vtkmodules.vtkFiltersHyperTree, vtkmodules.vtkCommonPython, vtkmodules.vtkChartsCore, vtkmodules.vtkAcceleratorsVTKmCore, vtkmodules.vtkAcceleratorsVTKmDataModel, vtkmodules.vtkAcceleratorsVTKmFilters (total: 147)
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure

× Encountered error while trying to install package.
╰─> mayavi

note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
prabhuramachandran commented 2 years ago

Thanks for the heads up, this is using the VTK pre-release 9.2.0-rc1 which is not supported but it is good to know the issues in advance so we can fix them. For now please just install the latest stable release, 9.1.0 and then try. Your problem of course is that there are no 3.10 wheels on pypi for VTK, so one option is to use Python 3.9, alternatively the conda-forge version of VTK does work well too but if conda is not an option for you then this is a problem.

Becheler commented 2 years ago

Thanks for your answer!

Ubuntu 22.04 LTS only features Python 3.10 (https://packages.ubuntu.com/jammy/python3.10), meaning that if running this version, we won't be able to use Python-VTK.

Until Kitware releases official VTK wheels for Python 3.10 on PyPI, you can use custom wheels PyVista hosted at https://github.com/pyvista/pyvista-wheels for Windows, Linux x64, and MacOS following this issue and this link.

So I had to use a non-official buid of vtk with: pip install https://github.com/pyvista/pyvista-wheels/raw/main/vtk-9.1.0.dev0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

It is a bit ugly, but this get you vtk 9.1.0 on ubuntu 22.04, after what mayavi installs successfully.

I will have to find how to handle dependencies conditionally to the OS version for users of my package :'(