That's odd. Maybe you have something in your pythonrc or pythonstartup that is defining sys.ps1. Try adding this before the import paraview line in your script:<br><br>import sys<br>del sys.ps1<br><br>Pat<br><br><div class="gmail_quote">
On Fri, Feb 11, 2011 at 9:09 AM, Adriano Gagliardi <span dir="ltr"><<a href="mailto:agagliardi@ara.co.uk">agagliardi@ara.co.uk</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
I receive the message when executing a Python script with pvpython or<br>
pvbatch after 'from paraview.simple import *'. Whether I run it as:<br>
<br>
pvpython ./my-script.py<br>
pvbatch ./my-script.py<br>
<br>
or if I include the executable at the top of the Python script ie:<br>
#!/usr/bin/env pvpython or #!/usr/bin/env pvbatch<br>
<br>
I still get the message. Is there another way I should be executing the<br>
scripts?<br>
<div class="im"><br>
Adriano<br>
<br>
===================================<br>
<br>
Adriano Gagliardi MEng PhD<br>
Business Sector Leader<br>
Computational Aerodynamics<br>
Aircraft Research Association Ltd.<br>
Manton Lane<br>
Bedford<br>
<br>
Tel: 01234 32 4644<br>
E-mail: <a href="mailto:agagliardi@ara.co.uk">agagliardi@ara.co.uk</a><br>
Url: <a href="http://www.ara.co.uk" target="_blank">www.ara.co.uk</a><br>
</div><div class="im">-----Original Message-----<br>
From: Utkarsh Ayachit [mailto:<a href="mailto:utkarsh.ayachit@kitware.com">utkarsh.ayachit@kitware.com</a>]<br>
Sent: 11 February 2011 13:58<br>
To: <a href="mailto:agagliardi@ara.co.uk">agagliardi@ara.co.uk</a><br>
</div><div><div></div><div class="h5">Cc: Aurélien Marsan; <a href="mailto:paraview@paraview.org">paraview@paraview.org</a><br>
Subject: Re: [Paraview] pvpython message<br>
<br>
Out of curiosity, why would you want to disable the message? It's only shown<br>
when pvpython is run as an interactive session, never when a script argument<br>
is specified or with pvbatch.<br>
<br>
Utkarsh<br>
<br>
2011/2/11 Adriano Gagliardi <<a href="mailto:agagliardi@ara.co.uk">agagliardi@ara.co.uk</a>>:<br>
><br>
> Thanks, Aurelian. I don't like random hacks, but if that is the only<br>
> option for the moment, so be it.<br>
><br>
> Thanks again.<br>
><br>
><br>
> ===================================<br>
><br>
> Adriano Gagliardi MEng PhD<br>
> Business Sector Leader<br>
> Computational Aerodynamics<br>
> Aircraft Research Association Ltd.<br>
> Manton Lane<br>
> Bedford<br>
><br>
> Tel: 01234 32 4644<br>
> E-mail: <a href="mailto:agagliardi@ara.co.uk">agagliardi@ara.co.uk</a><br>
> Url: <a href="http://www.ara.co.uk" target="_blank">www.ara.co.uk</a><br>
><br>
><br>
> ________________________________<br>
> From: Aurélien Marsan [mailto:<a href="mailto:aur.marsan@gmail.com">aur.marsan@gmail.com</a>]<br>
> Sent: 11 February 2011 13:29<br>
> To: <a href="mailto:agagliardi@ara.co.uk">agagliardi@ara.co.uk</a><br>
> Cc: <a href="mailto:paraview@paraview.org">paraview@paraview.org</a><br>
> Subject: Re: [Paraview] pvpython message<br>
><br>
> Hello,<br>
><br>
> In<br>
> PARAVIEW_DIR\lib\paraview-3.8\site-packages\paraview\servermanager.py<br>
> comment the lines 2947 and 2949.<br>
>><br>
>> if hasattr(sys, "ps1"):<br>
>> # session is interactive.<br>
>> print vtkSMProxyManager.GetParaViewSourceVersion();<br>
>><br>
><br>
> Aurélien.<br>
><br>
> 2011/2/11 Adriano Gagliardi <<a href="mailto:agagliardi@ara.co.uk">agagliardi@ara.co.uk</a>><br>
>><br>
>> Hello,<br>
>><br>
>> Is there a way to suppress the message you get each time you open<br>
>> pvpython<br>
>> i.e.:<br>
>><br>
>> paraview version 3.7.0, Date: 2009-10-03<br>
>><br>
>> Regards,<br>
>><br>
>> Adriano<br>
>><br>
>> ===================================<br>
>><br>
>> Adriano Gagliardi MEng PhD<br>
>> Business Sector Leader<br>
>> Computational Aerodynamics<br>
>> Aircraft Research Association Ltd.<br>
>> Manton Lane<br>
>> Bedford<br>
>><br>
>> Tel: 01234 32 4644<br>
>> E-mail: <a href="mailto:agagliardi@ara.co.uk">agagliardi@ara.co.uk</a><br>
>> Url: <a href="http://www.ara.co.uk" target="_blank">www.ara.co.uk</a><br>
>><br>
>><br>
>> *********************************************************************<br>
>> * This email contains information that is private and confidential<br>
>> and is intended only for the addressee.<br>
>> If you are not the intended recipient please delete it and notify us<br>
>> immediately by e-mailing the sender.<br>
>> Note: All email sent to or from this address may be accessed by<br>
>> someone other than the recipient, for system management and security<br>
>> reasons.<br>
>> Aircraft Research Association Ltd. Registered in England,<br>
>> Registration No<br>
>> 503668 Registered Office:<br>
>> Manton Lane, Bedford MK41 7PF England VAT No GB 196351245<br>
>><br>
>> *********************************************************************<br>
>> * _______________________________________________<br>
>> Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
>><br>
>> Visit other Kitware open-source projects at<br>
>> <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
>><br>
>> Please keep messages on-topic and check the ParaView Wiki at:<br>
>> <a href="http://paraview.org/Wiki/ParaView" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
>><br>
>> Follow this link to subscribe/unsubscribe:<br>
>> <a href="http://www.paraview.org/mailman/listinfo/paraview" target="_blank">http://www.paraview.org/mailman/listinfo/paraview</a><br>
><br>
> **********************************************************************<br>
> This email contains information that is private and confidential and<br>
> is intended only for the addressee.<br>
> If you are not the intended recipient please delete it and notify us<br>
> immediately by e-mailing the sender.<br>
> Note: All email sent to or from this address may be accessed by<br>
> someone other than the recipient, for system management and security<br>
> reasons.<br>
> Aircraft Research Association Ltd. Registered in England,<br>
> Registration No<br>
> 503668 Registered Office:<br>
> Manton Lane, Bedford MK41 7PF England VAT No GB 196351245<br>
><br>
> **********************************************************************<br>
><br>
> _______________________________________________<br>
> Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
><br>
> Visit other Kitware open-source projects at<br>
> <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
><br>
> Please keep messages on-topic and check the ParaView Wiki at:<br>
> <a href="http://paraview.org/Wiki/ParaView" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
><br>
> Follow this link to subscribe/unsubscribe:<br>
> <a href="http://www.paraview.org/mailman/listinfo/paraview" target="_blank">http://www.paraview.org/mailman/listinfo/paraview</a><br>
><br>
><br>
<br>
<br>
**********************************************************************<br>
This email contains information that is private and confidential and is intended only for the addressee.<br>
If you are not the intended recipient please delete it and notify us immediately by e-mailing the sender.<br>
Note: All email sent to or from this address may be accessed by someone other than the recipient, for<br>
system management and security reasons.<br>
Aircraft Research Association Ltd. Registered in England, Registration No 503668 Registered Office:<br>
Manton Lane, Bedford MK41 7PF England VAT No GB 196351245<br>
<br>
**********************************************************************<br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the ParaView Wiki at: <a href="http://paraview.org/Wiki/ParaView" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.paraview.org/mailman/listinfo/paraview" target="_blank">http://www.paraview.org/mailman/listinfo/paraview</a><br>
</div></div></blockquote></div><br>