Re: sys.argv[0] doesn't always contain the full path of running script.
Joel Hedlund wrote: > Yes indeed! But the path to the module will not be the same as the path to > the script if you are currently in an imported module. Consider this: I thought that was the point - to get the full path of the running script? I see you use the terms "script" and "module" in different contexts, while I use them as: script = module = file. I can't say which is right, though :). Cheers, ivan -- http://mail.python.org/mailman/listinfo/python-list
Re: sys.argv[0] doesn't always contain the full path of running script.
gmax2006 wrote: > Hi, > > I use RedHat linux. > > How can I find where exactly the current python script is running? Hi, Doesnt __file__ attribute of each module contain the full filepath of the module? So, try this: filepath = __file__ print filepath Works for me :) Cheers, i. zuzak -- http://mail.python.org/mailman/listinfo/python-list
Re: Calling Web Services from Python
m.banaouas wrote: > Can you tell us more about SOAPpy bug ? > Is it about authentication ? > > Ivan Zuzak a écrit : > >> ... >> I need a package/tool that generates web service proxies that will do >> all the low-level HTTP work. (Someting like the WSDL.EXE tool in .NET >> Framework) The ZSI and SOAPy packages [1] that i found (should) have >> those functionalities but either have a bug (SOAPy) or either do not >> work for arbitrary web services (ZSI). ... SOAPy : http://soapy.sourceforge.net/ SOAPPy : http://pywebsvcs.sourceforge.net/ The bugged one is SOAPy (parsing errors and something else). I just downloaded and tried SOAPPy and that one crashes too. I get an "Index out of range" error while parsing the wsdl ( in XMLSchema.py ). The traceback is a bit long, so I wont list the whole thing here. Bellow this message is the wsdl of the service for which im trying to get a proxy. If anyone manages to get a proxy out of it - please let me know :). Thank you for your help, Ivan WSDL START http://www.ris.fer.hr/overlay/addressing"; xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"; xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"; xmlns:s="http://www.w3.org/2001/XMLSchema"; xmlns:s3="http://www.ris.fer.hr/OpenCollectives/CoopetitionServices/MailBox/MessageStatistics"; xmlns:s2="http://www.ris.fer.hr/OpenCollectives/CoopetitionServices/XmlDoc"; xmlns:s4="http://ris.zemris.fer.hr/remotingSchema"; xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"; xmlns:tns="http://www.ris.fer.hr/OpenCollectives/CoopetitionServices/MailBox"; xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/"; xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"; targetNamespace="http://www.ris.fer.hr/OpenCollectives/CoopetitionServices/MailBox"; xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";> http://www.ris.fer.hr/OpenCollectives/CoopetitionServices/MailBox";> http://www.ris.fer.hr/overlay/addressing"; /> http://www.ris.fer.hr/OpenCollectives/CoopetitionServices/XmlDoc"; /> xmlns http://www.ris.fer.hr/overlay/addressing";> xmlns xmlns xmlns http://www.ris.fer.hr/OpenCollectives/CoopetitionServices/XmlDoc";> http://www.ris.fer.hr/OpenCollectives/CoopetitionServices/MailBox/MessageStatistics";> http://ris.zemris.fer.hr/remotingSchema";>
Calling Web Services from Python
Hello, My Python application calls web services available on the Internet. The web service being called is defined through application user input. The Python built-in library allows access to web services using HTTP protocol, which is not acceptible - generating SOAP messages for arbitrary web services is something i wish to avoid. I need a package/tool that generates web service proxies that will do all the low-level HTTP work. (Someting like the WSDL.EXE tool in .NET Framework) The ZSI and SOAPy packages [1] that i found (should) have those functionalities but either have a bug (SOAPy) or either do not work for arbitrary web services (ZSI). I tried the ZSI wsdl2py script on a wsdl of one of my services, and the script crashes. I suppose the wsdl was "too hard" for the script to parse. Are there any other packages that utilize generation of web service proxies that are compatible with SOAP & WSDL standards? Thank you, ivan zuzak [1] - http://pywebsvcs.sourceforge.net/ -- http://mail.python.org/mailman/listinfo/python-list