Python book similar to Enterprise Recipes with Ruby and Rails

2009-10-07 Thread hrishy
Hi Is there a python book that resemble this http://www.amazon.com/Enterprise-Recipes-Ruby-Rails-Schmidt/dp/1934356239/ref=sr_1_1?ie=UTF8s=booksqid=1254914183sr=8-1-spell Also is there a active record version or port of Python ? regards --

difficulty in understanding rsplit(None,1)[1]

2009-09-22 Thread hrishy
Hi What does rsplit(None,1)[1] accomplish. Can somebody please decompose that to me. regards -- http://mail.python.org/mailman/listinfo/python-list

Re: difficulty in understanding rsplit(None,1)[1]

2009-09-22 Thread hrishy
: Tuesday, 22 September, 2009, 9:52 AM hrishy wrote: Hi What does rsplit(None,1)[1] accomplish. Can somebody please decompose that to me. regards Sure: test = 'This is a test' help(test.rsplit) Help on built-in function rsplit: rsplit(...)     S.rsplit([sep [,maxsplit

Re: beginner's python help

2009-09-06 Thread hrishy
Hi I am just a python beginner What you need is exceptions http://docs.python.org/tutorial/errors.html something on the lines of since you expect a integer and you wnat to catch the exception ... try: ... sum = 0; ... for item in readData: ...sum +=

Re: beginner's python help

2009-09-06 Thread hrishy
Hi Chris What if i want to log that bad data and continue processing is there a way to do that ? regards --- On Sun, 6/9/09, Chris Rebert c...@rebertia.com wrote: From: Chris Rebert c...@rebertia.com Subject: Re: beginner's python help To: Maggie la.f...@gmail.com Cc:

Re: beginner's python help

2009-09-06 Thread hrishy
Hi sum = 0 for item in readData: try: sum += int(item) except ValueError: print Oops! That was no valid number. Instead it was:, item So you mean to say this would ignore the bad data and continue processing ? regards --

Re: XML Parsing

2009-02-25 Thread hrishy
not use xpath to extract xml text from a xml doc ? regards Hrishy --- On Wed, 25/2/09, Lie Ryan lie.1...@gmail.com wrote: From: Lie Ryan lie.1...@gmail.com Subject: Re: XML Parsing To: python-list@python.org Date: Wednesday, 25 February, 2009, 7:33 AM Are you searching for answer or searching

Re: XML Parsing

2009-02-25 Thread hrishy
Ha the guru himself responding :-) --- On Wed, 25/2/09, Paul McGuire pt...@austin.rr.com wrote: From: Paul McGuire pt...@austin.rr.com Subject: Re: XML Parsing To: python-list@python.org Date: Wednesday, 25 February, 2009, 2:04 PM On Feb 25, 1:17 am, hrishy hris...@yahoo.co.uk wrote: Hi

Re: XML Parsing

2009-02-25 Thread hrishy
Hi Cliff Thanks so using elementree is the right way to handle this problem regards Hrishy --- On Wed, 25/2/09, J. Clifford Dyer j...@sdf.lonestar.org wrote: From: J. Clifford Dyer j...@sdf.lonestar.org Subject: Re: XML Parsing To: hris...@yahoo.co.uk Cc: python-list@python.org, Lie Ryan

Re: XML Parsing

2009-02-24 Thread hrishy
Hi I am just a python enthusiast and not a python user but was just wundering why didnt the list members come up with or recommen XPATH based solution which i think is very elegant for this type of a problem isnt it ? regards Hrishy --- On Wed, 25/2/09, Lie Ryan lie.1...@gmail.com wrote

Re: XML Parsing

2009-02-24 Thread hrishy
a code like above willing to hear and learn from experienced python gurus regards Hrishy -- http://mail.python.org/mailman/listinfo/python-list

Re: Equivalent of 'wget' for python?

2008-12-11 Thread hrishy
urllib.request.urlretrieve(url, local_file_name) urllib --static class request --method urlretrieve-- what is this then ? regards Hrishy --- On Mon, 8/12/08, Jerry Hill [EMAIL PROTECTED] wrote: From: Jerry Hill [EMAIL PROTECTED] Subject: Re: Equivalent of 'wget' for python? To: python-list@python.org Date

Re: Equivalent of 'wget' for python?

2008-12-11 Thread hrishy
Hi Saju Thanks for helping the oop challenged regards Hrishy --- On Thu, 11/12/08, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: From: [EMAIL PROTECTED] [EMAIL PROTECTED] Subject: Re: Equivalent of 'wget' for python? To: python-list@python.org Date: Thursday, 11 December, 2008, 10:41 AM

lxml and schema validation

2008-10-03 Thread hrishy
=etree.parse(My.XML) xmlschema.assertValid(xmldoc) will my program validate against My.xsd and My1.xsd both ? I also would like my program to continue validation against the xsd and not stope at the first failure . my question would be how do i do that in python ? regards Hrishy -- http

Sample code required to validate a xml file against XSD

2008-10-02 Thread hrishy
Hi Does anybody have a python xample program to validate a xml file against a XSD. regards Hrisy -- http://mail.python.org/mailman/listinfo/python-list

Re: Linq to Python

2008-09-25 Thread hrishy
).Value, hairCutStyle = dbGuys.stoogeHaircut, }; [/code] regards Hrishy -- http://mail.python.org/mailman/listinfo/python-list

Re: Linq to Python

2008-09-25 Thread hrishy
Hi Grant haha :-) i discounted that perspective :-) regards Hrishy --- On Thu, 25/9/08, Grant Edwards [EMAIL PROTECTED] wrote: From: Grant Edwards [EMAIL PROTECTED] Subject: Re: Linq to Python To: python-list@python.org Date: Thursday, 25 September, 2008, 2:22 AM On 2008-09-24, Bruno

Re: Linq to Python

2008-09-25 Thread hrishy
Hi Roger I am impressed (i always suspected Python programmers are smart no doubt about it). But what about the case where they join different sources like the one here http://informationr.net/ir/13-2/TB0806.html Thanks for teaching me :-) i am thankful for that regards Hrishy names

Re: Linq to Python

2008-09-25 Thread hrishy
it) regards Hrishy --- On Wed, 24/9/08, Tim Golden [EMAIL PROTECTED] wrote: From: Tim Golden [EMAIL PROTECTED] Subject: Re: Linq to Python To: Cc: python-list@python.org Date: Wednesday, 24 September, 2008, 8:20 PM [EMAIL PROTECTED] wrote: sturlamolden: No, because Python already has list

Re: Linq to Python

2008-09-25 Thread hrishy
Hi Pardon my ignorance again but id ont see any join in python or did i miss something ? regards Hrishy --- On Thu, 25/9/08, sturlamolden [EMAIL PROTECTED] wrote: From: sturlamolden [EMAIL PROTECTED] Subject: Re: Linq to Python To: python-list@python.org Date: Thursday, 25 September

Re: Linq to Python

2008-09-25 Thread hrishy
Hi Thank you very much I appreciate taking the pain to explain this to me. regards Hrishy --- On Thu, 25/9/08, sturlamolden [EMAIL PROTECTED] wrote: From: sturlamolden [EMAIL PROTECTED] Subject: Re: Linq to Python To: python-list@python.org Date: Thursday, 25 September, 2008, 12:16 PM

Re: Linq to Python

2008-09-24 Thread hrishy
here but i did google but nothing much came up thats when i posted the question here since i always see Python programmers are somehow smarter then programmers in other langauges i don't know if its the language or the programmers themselves that make them smart) regards Hrishy --- On Tue, 23

Re: Linq to Python

2008-09-24 Thread hrishy
to make everything easy ? regards Hrishy --- On Tue, 23/9/08, sturlamolden [EMAIL PROTECTED] wrote: From: sturlamolden [EMAIL PROTECTED] Subject: Re: Linq to Python To: python-list@python.org Date: Tuesday, 23 September, 2008, 7:49 PM On Sep 23, 4:48 pm, hrishy [EMAIL PROTECTED] wrote

Re: Linq to Python

2008-09-24 Thread hrishy
Hi Tom This is what i like and feel of the Python programmers smarter then every other langauge i know of. But i am not comfortable with your second statement XML i never need it one day everybody would need it. regards Hrishy --- On Tue, 23/9/08, Thomas G. Willis [EMAIL PROTECTED] wrote

Linq to Python

2008-09-23 Thread hrishy
Hi Will LINQ be ported to Python ? regards Hrishy -- http://mail.python.org/mailman/listinfo/python-list

Re: Linq to Python

2008-09-23 Thread hrishy
Hi Thanks for those links however LINQ seems to be much more then ORM tool it can for example join an XML file with a relational datasource or create a XSD regards Hrishy --- On Tue, 23/9/08, Diez B. Roggisch [EMAIL PROTECTED] wrote: From: Diez B. Roggisch [EMAIL PROTECTED] Subject: Re

Hello Gabriel cant help noticing you

2007-09-26 Thread hrishy
particularly liked the way you explained that Regular expression stuff to parse that XML i am just awestruck. NO BOOK/ARTICLE EVER OUT THERE IN MY MIND HAS DONE IT SO CLEANLY AS YOU DID IT. regards Hrishy ___ Yahoo! Answers - Got a question

Re: Hello Gabriel cant help noticing you

2007-09-26 Thread hrishy
Hi Gabriel Well it could be a bad example when we need to do lot more things via xml but..the regex in that i have preserved it carefully thats key takeawy for a beginner like me the way the problem was dissected to arrive at what was needed regards Hrishy --- Gabriel Genellina [EMAIL