[Paraview] GetSources() fails with Custom Filters
Utkarsh Ayachit
utkarsh.ayachit at kitware.com
Mon May 31 09:17:53 EDT 2010
Matt,
I just tried the same with current git-master (should be same as 3.8
as far as python stuff is concerned). It seems to work just fine:
>>> from paraview.simple import *
paraview version 3.9.0, Date: 2010-05-21
>>> GetSources()
{('Sphere1', '105'): <paraview.servermanager.Sphere object at 0x4c3ffd0>,
('TwoShrinks1', '1111'): <paraview.servermanager.TwoShrinks object at
0x4c3fb10>}
>>>
Let me know if it doesn't work with 3.8 for you.
Utkarsh
On Sun, May 30, 2010 at 9:41 PM, <m.c.wilkins at massey.ac.nz> wrote:
>
> Hi,
>
> Under 3.6.2 on linux in the python shell GetSources() fails if there are
> sources in the pipeline browser that appeared from Custom Filters. The error
> is:
>
>>>> GetSources()
> Traceback (most recent call last):
> File "<console>", line 1, in <module>
> File "/home/kitware/ParaView3/Utilities/BuildScripts/ParaView-3.6/ParaView3Bin/Utilities/VTKPythonWrapping/paraview/simple.py", line 195, in GetSources
> File "/home/kitware/ParaView3/Utilities/BuildScripts/ParaView-3.6/ParaView3Bin/Utilities/VTKPythonWrapping/paraview/servermanager.py", line 1493, in GetProxiesInGroup
> File "/home/kitware/ParaView3/Utilities/BuildScripts/ParaView-3.6/ParaView3Bin/Utilities/VTKPythonWrapping/paraview/servermanager.py", line 1704, in next
> File "/home/kitware/ParaView3/Utilities/BuildScripts/ParaView-3.6/ParaView3Bin/Utilities/VTKPythonWrapping/paraview/servermanager.py", line 2280, in _getPyProxy
> File "/home/kitware/ParaView3/Utilities/BuildScripts/ParaView-3.6/ParaView3Bin/Utilities/VTKPythonWrapping/paraview/servermanager.py", line 2339, in _findClassForProxy
> KeyError: 'Foo'
>>>>
>
> What I am doing is creating a Custom Filter (Foo) by: selecting two filters I
> have applied, clicking on Create Custom Filter, then taking all the defaults
> (clicking through Next Next Next, then Finished). Then I apply that custom
> filter, then run a GetSources() in the python shell and the above error
> appears.
>
> I friend tried the above with 3.8.0 on Windows with similar results.
> I don't completely trust he did it right, but he probably did, so the
> problem is probably not limited to 3.6.2 on linux.
>
> Have I done something wrong with my Custom Filter?
>
> Thank you very much for any help you can offer.
>
> Matt Wilkins
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the ParaView Wiki at: http://paraview.org/Wiki/ParaView
>
> Follow this link to subscribe/unsubscribe:
> http://www.paraview.org/mailman/listinfo/paraview
>
More information about the ParaView
mailing list