From jeff at taupro.com Wed Oct 1 00:31:50 2008 From: jeff at taupro.com (Jeff Rush) Date: Tue, 30 Sep 2008 17:31:50 -0500 Subject: [BangPypers] GUI framework in Python... In-Reply-To: References: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> Message-ID: <48E2A8D6.40007@taupro.com> Vishal wrote: > Sometime back, I came across the idea of bundling a basic webserver in a > python application and using a browser window as the GUI host. That's > probably one of the most universal kind of GUI framework > possible...though it might not have all that native GUI packages provide. > > If I want to do something like this, can someone guide if there are > already existing packages to that? > Here's what I will need, i think: > a) Python executable > b) Python scripts (which create the HTML files and implement the logic > of the application) > c) CSS files > d) Other things that make up contemporary web 2.0 frameworks > (templating, SQL related stuff) > d) A basic webserver (does this need to be a Python one...I think its > better to have a simple one as a separate EXE) > > what else? The Twisted framework would be able to these things, in a very lightweight manner. And then use py2exe to bundle it into a single executable. Twisted has their neat Nevow/STAN templating and very powerful AJAX/Athena client<->server callbacks. Lots more lately - a database interface solution and a pluggable UI framework. If you haven't visited their website lately, check it out. -Jeff From vnbang2003 at yahoo.com Wed Oct 1 06:38:10 2008 From: vnbang2003 at yahoo.com (VIJAY KUMAR) Date: Wed, 1 Oct 2008 10:08:10 +0530 (IST) Subject: [BangPypers] pdf attachment in mail Message-ID: <200332.95519.qm@web94004.mail.in2.yahoo.com> Hi All, ?????????? Am facing problem with pdf attachment in mail. I have created pdf when i try to read it code look like below. ?????????????? pdf=self.getTfmPdf() ?????????????? attachment.set_payload(pdf.read()) ???????????? ? Encoders.encode_base64(attachment) ???????? ????? attachment.add_header('Content-Disposition', 'attachment', filename=filename) ????????? ? I get? "AttributeError: "PDFTfm instance has no attribute 'read'"? -??? where PDFTfm is class for pdf creation. ?????????? when?I print? pdf?I see ?????????? Can some one please help me in this. Cheers, ?Vijay Unlimited freedom, unlimited storage. Get it now, on http://help.yahoo.com/l/in/yahoo/mail/yahoomail/tools/tools-08.html/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From sridhar.ratna at gmail.com Fri Oct 3 05:21:19 2008 From: sridhar.ratna at gmail.com (Sridhar Ratnakumar) Date: Thu, 2 Oct 2008 20:21:19 -0700 Subject: [BangPypers] GUI framework in Python... In-Reply-To: References: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> Message-ID: <7c73a13a0810022021i3446716en28143b9ef14a32c2@mail.gmail.com> On Tue, Sep 30, 2008 at 2:22 AM, Vishal wrote: > So the options left are: > a) Use IronPython to get all the Windows Forms stuff > b) Use PythonWin and use MFC to build the GUI > c) Use the Embedded Websever approach and make the web browser as your GUI > host. > d) Use Delphi to create the GUI and use P4D for connecting to Python. > I am most interested in option C, because thats the least dependent on other > language bindings etc etc. I can think of one more option: e) write separate GUI code for each platform. eg: Windows Forms, Gtk#, Cocoa# if you are going to use IronPython I wouldn't recommend option (c) as writing GUI code over HTML/JavaScript is the most painful development option even if you were to use those fancy and buggy GUI javascript toolkits. From vsapre80 at gmail.com Fri Oct 3 13:01:25 2008 From: vsapre80 at gmail.com (Vishal) Date: Fri, 3 Oct 2008 16:31:25 +0530 Subject: [BangPypers] GUI framework in Python... In-Reply-To: <7c73a13a0810022021i3446716en28143b9ef14a32c2@mail.gmail.com> References: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> <7c73a13a0810022021i3446716en28143b9ef14a32c2@mail.gmail.com> Message-ID: I wouldn't recommend option (c) as writing GUI code over HTML/JavaScript is the most painful development option even if you were to use those fancy and buggy GUI javascript toolkits. Any specific reason for this? The one I can think of is cross browser compatibility. I can force the users to use Google Chrome only :)) or any other good browser. and since the application is going to be mostly a local app...(as in the sever and client stay on the same machine) one can also think of using a simple browser which does not necessarily confirm to all the HTTP standards. (not sure how well thought that option will be...) Vishal On Fri, Oct 3, 2008 at 8:51 AM, Sridhar Ratnakumar wrote: > On Tue, Sep 30, 2008 at 2:22 AM, Vishal wrote: > > So the options left are: > > a) Use IronPython to get all the Windows Forms stuff > > b) Use PythonWin and use MFC to build the GUI > > c) Use the Embedded Websever approach and make the web browser as your > GUI > > host. > > d) Use Delphi to create the GUI and use P4D for connecting to Python. > > I am most interested in option C, because thats the least dependent on > other > > language bindings etc etc. > > I can think of one more option: > > e) write separate GUI code for each platform. eg: Windows Forms, Gtk#, > Cocoa# if you are going to use IronPython > > I wouldn't recommend option (c) as writing GUI code over > HTML/JavaScript is the most painful development option even if you > were to use those fancy and buggy GUI javascript toolkits. > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > -- "A Strong and Positive attitude creates more miracles than anything else. Because...Life is 10% how you make it, and 90% how you take it" "Diamond is another piece of coal that did well under pressure" http://www.youtube.com/watch?v=JGu0GiHlR5k Visit: http://members.soundclick.com/mukulsapre http://www.soundclick.com/gurusgrace -------------- next part -------------- An HTML attachment was scrubbed... URL: From sridhar.ratna at gmail.com Sun Oct 5 02:23:41 2008 From: sridhar.ratna at gmail.com (Sridhar Ratnakumar) Date: Sat, 4 Oct 2008 17:23:41 -0700 Subject: [BangPypers] GUI framework in Python... In-Reply-To: References: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> <7c73a13a0810022021i3446716en28143b9ef14a32c2@mail.gmail.com> Message-ID: <7c73a13a0810041723x5f3e9338mc5d8ede2971363eb@mail.gmail.com> On Fri, Oct 3, 2008 at 4:01 AM, Vishal wrote: > I wouldn't recommend option (c) as writing GUI code over > HTML/JavaScript is the most painful development option even if you > were to use those fancy and buggy GUI javascript toolkits. > > Any specific reason for this? The one I can think of is cross browser > compatibility. 1. Browser inconsistencies 2. Lack of proper rendering abstractions (for example, every GUI javascript code basically looks like a bunch of hacks - and hard to maintain. See YUI *source* code). 3. Lack of choice in programming langauge (client side code must be in Javascript) 4. Performance From sridhar.ratna at gmail.com Sun Oct 5 02:24:21 2008 From: sridhar.ratna at gmail.com (Sridhar Ratnakumar) Date: Sat, 4 Oct 2008 17:24:21 -0700 Subject: [BangPypers] GUI framework in Python... In-Reply-To: References: Message-ID: <7c73a13a0810041724o6969ac77rd1f0b16e6d05bfb4@mail.gmail.com> http://www.uxpython.com/ looks like an interesting project. On Sun, Sep 21, 2008 at 4:36 AM, Vishal wrote: > We would like to use a GUI framework with our Python code. > Any pointers by actual users of a GUI framework in Python. The web gives too > many options to easily choose from. > Just trying to learn from others from this group. > Thanks and best regards, > Vishal > > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > From abpillai at gmail.com Mon Oct 6 09:03:13 2008 From: abpillai at gmail.com (Anand Balachandran Pillai) Date: Mon, 6 Oct 2008 12:33:13 +0530 Subject: [BangPypers] pdf attachment in mail In-Reply-To: <200332.95519.qm@web94004.mail.in2.yahoo.com> References: <200332.95519.qm@web94004.mail.in2.yahoo.com> Message-ID: <8548c5f30810060003t10a8355dkb3130caca463d3b4@mail.gmail.com> Hi Vijay, If you need help, make sure you post some more context here. We cannot help without knowing how and where you are trying to do this, which email module you are using etc. If it is an open source code, you can post it or point out the location. If it proprietary, post enough context so that others can figure things out. --Anand On Wed, Oct 1, 2008 at 10:08 AM, VIJAY KUMAR wrote: > > Hi All, > Am facing problem with pdf attachment in mail. I have created pdf > when i try to read it code look like below. > pdf=self.getTfmPdf() > attachment.set_payload(pdf.read()) > Encoders.encode_base64(attachment) > attachment.add_header('Content-Disposition', 'attachment', > filename=filename) > I get "AttributeError: "PDFTfm instance has no attribute > 'read'" - where PDFTfm is class for pdf creation. > when I print pdf I see > Can some one please help me in this. > > > > Cheers, > Vijay > ________________________________ > Add more friends to your messenger and enjoy! Invite them now. > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- -Anand From kamal.gs at gmail.com Mon Oct 6 13:34:18 2008 From: kamal.gs at gmail.com (Kamal Govindraj) Date: Mon, 6 Oct 2008 17:04:18 +0530 Subject: [BangPypers] [Job posting] Looking for Python consultant to customize OpenERP Message-ID: Hi, We (http://www.lxisoft.com) are looking for a Python consultant to help us customize OpenERP for one of our clients. The application is to help automate the sales , procurement & shipping process of a small trading company. Their main business is to acquire certain products from vendors on customers request and then manage the whole process till it is shipped. They don't manufacture anything or maintain inventories. They also manage their accounting using Tally and would like some kind of integration with it (batch prcoess to pull data / push data back). We are looking at the option of customizing OpenERP to achieve this. The sales, order management and procurement modules need to be customized to match their business requirements. We are looking for a independent consultant (part time is also fine) with good knowledge of python, web development, ORM and database concepts and workflow concepts. Prior experience with OpenERP is desirable but not a must. It is sufficient if they have the required skills to master it quickly. We are also open to partnering with another company. In case anybody is interested, drop me a mail (kamal.gs at lxisoft.com or kamal.gs at gmail.com) Regards, Kamal -------------- next part -------------- An HTML attachment was scrubbed... URL: From kamal.gs at gmail.com Mon Oct 6 13:45:45 2008 From: kamal.gs at gmail.com (Kamal Govindraj) Date: Mon, 6 Oct 2008 17:15:45 +0530 Subject: [BangPypers] [Job posting] Looking for Python consultant to customize OpenERP In-Reply-To: References: Message-ID: OpenERP url (it used to be called TinyERP earlier) http://openerp.com/ On Mon, Oct 6, 2008 at 5:04 PM, Kamal Govindraj wrote: > Hi, > > We (http://www.lxisoft.com) are looking for a Python consultant to help us > customize OpenERP for one of our clients. > > The application is to help automate the sales , procurement & shipping > process of a small trading company. > Their main business is to acquire certain products from vendors on > customers request and then manage the whole process till it is shipped. > They don't manufacture anything or maintain inventories. They also manage > their accounting using Tally and would like some kind of integration with it > (batch prcoess to pull data / push data back). > > We are looking at the option of customizing OpenERP to achieve this. > The sales, order management and procurement modules need to be customized > to match their business requirements. > > We are looking for a independent consultant (part time is also fine) with > good knowledge of python, web development, ORM and database concepts and > workflow concepts. Prior experience with OpenERP is desirable but not a > must. It is sufficient if they have the required skills to master it > quickly. > We are also open to partnering with another company. > > In case anybody is interested, drop me a mail (kamal.gs at lxisoft.com or > kamal.gs at gmail.com) > > Regards, > Kamal > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ashok at parliaments.info Wed Oct 15 00:24:06 2008 From: ashok at parliaments.info (Ashok Hariharan) Date: Wed, 15 Oct 2008 01:24:06 +0300 Subject: [BangPypers] [Job Posting] Zope/Python developer for UN Project Message-ID: Hello there : We are a United Nations organization (UN/DESA) who are building a Parliamentary Information System on the Zope3 platform (see http://www.bungeni.org and http://www.parliaments.info). We are looking to hire a full time Zope developer. The attached PDF document has details about the position. The position is based in Nairobi, Kenya - and the salary package also includes medical insurance, dependency allowance, education grants - the standard UN employment benefits etc. If you are interested, please get in touch with me off-list. regards Ashok Hariharan Consultant, Africa i-Parliaments UN/DESA -------------- next part -------------- A non-text attachment was scrubbed... Name: 1702_Senior_Developer_(Zope)_Bungeni_Portal_Africa_i-Parliament.pdf Type: application/pdf Size: 90547 bytes Desc: not available URL: From srinivasaenergy at gmail.com Sat Oct 18 08:25:44 2008 From: srinivasaenergy at gmail.com (srinivasa rao) Date: Sat, 18 Oct 2008 11:55:44 +0530 Subject: [BangPypers] [Job posting] Looking for Python consultant to customize OpenERP In-Reply-To: References: Message-ID: Dear Sir Do you got my CV to you so I did not got any reply from and expect from you feed back and expect reply from you. Thanking you Yours truly, Srinivasa rao M Email: m_srienergy at rediffmail.com Or 9490682315 On Mon, Oct 6, 2008 at 5:04 PM, Kamal Govindraj wrote: > Hi, > > We (http://www.lxisoft.com) are looking for a Python consultant to help us > customize OpenERP for one of our clients. > > The application is to help automate the sales , procurement & shipping > process of a small trading company. > Their main business is to acquire certain products from vendors on > customers request and then manage the whole process till it is shipped. > They don't manufacture anything or maintain inventories. They also manage > their accounting using Tally and would like some kind of integration with it > (batch prcoess to pull data / push data back). > > We are looking at the option of customizing OpenERP to achieve this. > The sales, order management and procurement modules need to be customized > to match their business requirements. > > We are looking for a independent consultant (part time is also fine) with > good knowledge of python, web development, ORM and database concepts and > workflow concepts. Prior experience with OpenERP is desirable but not a > must. It is sufficient if they have the required skills to master it > quickly. > We are also open to partnering with another company. > > In case anybody is interested, drop me a mail (kamal.gs at lxisoft.com or > kamal.gs at gmail.com) > > Regards, > Kamal > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From vnbang2003 at yahoo.com Tue Oct 21 12:33:17 2008 From: vnbang2003 at yahoo.com (VIJAY KUMAR) Date: Tue, 21 Oct 2008 16:03:17 +0530 (IST) Subject: [BangPypers] python split Message-ID: <816975.90535.qm@web94002.mail.in2.yahoo.com> Hi , Is there a way to split text like below example textString='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab' after every 50 character . Can some one help me here with regard's vijay kumar bang Did you know? You can CHAT without downloading messenger. Go to http://in.webmessenger.yahoo.com/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From abpillai at gmail.com Tue Oct 21 12:46:51 2008 From: abpillai at gmail.com (Anand Balachandran Pillai) Date: Tue, 21 Oct 2008 16:16:51 +0530 Subject: [BangPypers] python split In-Reply-To: <816975.90535.qm@web94002.mail.in2.yahoo.com> References: <816975.90535.qm@web94002.mail.in2.yahoo.com> Message-ID: <8548c5f30810210346u58518989u2fd00ebd9eef8aee@mail.gmail.com> Here is the simplest generator for this. def splitat(s, pos=50): while s: yield s[:pos] s = s[pos:] >>> for p in splitat(textString): print p ... aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaab On Tue, Oct 21, 2008 at 4:03 PM, VIJ AY KUMAR wrote: > Hi , > Is there a way to split text like below example > > textString='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab' > after every 50 character . > Can some one help me here > > with regard's > vijay kumar bang > > ________________________________ > Download prohibited? No problem. CHAT from any browser, without download. > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- -Anand From sibteym at infotechsw.com Tue Oct 21 12:49:18 2008 From: sibteym at infotechsw.com (Sibtey Mehdi) Date: Tue, 21 Oct 2008 16:19:18 +0530 Subject: [BangPypers] python split In-Reply-To: <816975.90535.qm@web94002.mail.in2.yahoo.com> References: <816975.90535.qm@web94002.mail.in2.yahoo.com> Message-ID: <027901c9336a$ab087d20$5fc513ac@pwit.com> Try this Sep = 50 l1 = [textString[a:a+sep] for a in range(0, len(textString), sep)] Sibtey _____ From: bangpypers-bounces+sibteym=infotechsw.com at python.org [mailto:bangpypers-bounces+sibteym=infotechsw.com at python.org] On Behalf Of VIJAY KUMAR Sent: Tuesday, October 21, 2008 4:03 PM To: Bangalore Python Users Group - India Subject: [BangPypers] python split Hi , Is there a way to split text like below example textString='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaab' after every 50 character . Can some one help me here with regard's vijay kumar bang _____ Download prohibited? No problem. CHAT from any browser, without download. -------------- next part -------------- An HTML attachment was scrubbed... URL: From vnbang2003 at yahoo.com Tue Oct 21 13:13:38 2008 From: vnbang2003 at yahoo.com (VIJAY KUMAR) Date: Tue, 21 Oct 2008 16:43:38 +0530 (IST) Subject: [BangPypers] python split Message-ID: <469057.7279.qm@web94002.mail.in2.yahoo.com> Thanks Sibtey with regard's vijay kumar bang ________________________________ From: Sibtey Mehdi To: Bangalore Python Users Group - India Sent: Tuesday, 21 October, 2008 4:19:18 PM Subject: Re: [BangPypers] python split Try this Sep = 50 l1 = [textString[a:a+sep] for a in range(0, len(textString), sep)] Sibtey ________________________________ From:bangpypers-bounces+sibteym=infotechsw.com at python.org [mailto:bangpypers-bounces+sibteym=infotechsw.com at python.org] On Behalf Of VIJAY KUMAR Sent: Tuesday, October 21, 2008 4:03 PM To: Bangalore Python Users Group - India Subject: [BangPypers] python split Hi , Is there a way to split text like below example textString='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab' after every 50 character . Can some one help me here with regard's vijay kumar bang ________________________________ Download prohibited? No problem. CHAT from any browser, without download. Add more friends to your messenger and enjoy! Go to http://messenger.yahoo.com/invite/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From pythonic at gmail.com Tue Oct 21 13:43:34 2008 From: pythonic at gmail.com (Shekhar) Date: Tue, 21 Oct 2008 07:43:34 -0400 Subject: [BangPypers] python split In-Reply-To: <027901c9336a$ab087d20$5fc513ac@pwit.com> References: <816975.90535.qm@web94002.mail.in2.yahoo.com> <027901c9336a$ab087d20$5fc513ac@pwit.com> Message-ID: <48FDC066.5040209@gmail.com> With tiny modifications you get a generator object. Not sure of benefits in this particular case. sep = 50 l1 = [textString[a:a+sep] for a in xrange(0, len(textString), sep)] l2 = (textString[a:a+sep] for a in xrange(0, len(textString), sep)) print l1 print l2 Sibtey Mehdi wrote: > > Try this > > > > Sep = 50 > > l1 = [textString[a:a+sep] for a in range(0, len(textString), sep)] > > > > Sibtey > > ------------------------------------------------------------------------ > > *From:* bangpypers-bounces+sibteym=infotechsw.com at python.org > [mailto:bangpypers-bounces+sibteym=infotechsw.com at python.org] *On > Behalf Of *VIJAY KUMAR > *Sent:* Tuesday, October 21, 2008 4:03 PM > *To:* Bangalore Python Users Group - India > *Subject:* [BangPypers] python split > > > > Hi , > Is there a way to split text like below example > > textString='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab' > > after every 50 character . > Can some one help me here > > > > *with regard's*** > > *vijay kumar bang*** > > > > > > ------------------------------------------------------------------------ > > Download prohibited? No problem. CHAT > > from any browser, without download. > > ------------------------------------------------------------------------ > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > From pradeep at change-congress.org Wed Oct 22 17:05:11 2008 From: pradeep at change-congress.org (Pradeep Gowda) Date: Wed, 22 Oct 2008 11:05:11 -0400 Subject: [BangPypers] Python news Message-ID: <3e3294b70810220805v6b7912d9v39da70be9b5445b0@mail.gmail.com> Ask.com [1] is using web.py for their http://today.ask.com/default service. [1] http://en.wikipedia.org/wiki/Ask.com +PG http://pradeepgowda.com From sibteym at infotechsw.com Thu Oct 23 09:29:12 2008 From: sibteym at infotechsw.com (Sibtey Mehdi) Date: Thu, 23 Oct 2008 12:59:12 +0530 Subject: [BangPypers] how to relclaim memory Message-ID: <00af01c934e1$0c573ea0$5fc513ac@pwit.com> Hi My system is showing 900MB usage of memory, I have deleted some object (del pythonObj) but the memory is not returned to os, I have also tried gc.collect() and del (gc.garbage) but still the system is showing 900MB usage. Is there anyway to reclaim the memory? Thanks, Sibtey -------------- next part -------------- An HTML attachment was scrubbed... URL: From prashanthellina at gmail.com Thu Oct 23 09:48:44 2008 From: prashanthellina at gmail.com (Prashanth Ellina) Date: Thu, 23 Oct 2008 13:18:44 +0530 Subject: [BangPypers] how to relclaim memory In-Reply-To: <00af01c934e1$0c573ea0$5fc513ac@pwit.com> References: <00af01c934e1$0c573ea0$5fc513ac@pwit.com> Message-ID: <281962dd0810230048j1606f647i5e751f9710b9e077@mail.gmail.com> Which version of Python are you using? Which OS? On Thu, Oct 23, 2008 at 12:59 PM, Sibtey Mehdi wrote: > Hi > > My system is showing 900MB usage of memory, I have deleted some object (del > pythonObj) but the memory is not returned to *os*, I have also tried > gc.collect() and del (gc.garbage) but still the system is showing 900MB > usage. > > Is there anyway to reclaim the memory? > > > > > > Thanks, > > Sibtey > > > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- http://blog.prashanthellina.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From abpillai at gmail.com Thu Oct 23 09:52:16 2008 From: abpillai at gmail.com (Anand Balachandran Pillai) Date: Thu, 23 Oct 2008 13:22:16 +0530 Subject: [BangPypers] how to relclaim memory In-Reply-To: <00af01c934e1$0c573ea0$5fc513ac@pwit.com> References: <00af01c934e1$0c573ea0$5fc513ac@pwit.com> Message-ID: <8548c5f30810230052w7ea5e8a6gc9801cbe13954602@mail.gmail.com> On Thu, Oct 23, 2008 at 12:59 PM, Sibtey Mehdi wrote: > Hi > > My system is showing 900MB usage of memory, I have deleted some object (del > pythonObj) but the memory is not returned to os, I have also tried > gc.collect() and del (gc.garbage) but still the system is showing 900MB > usage. "Watson, I have no data yet. It is a capital mistake to theorize before one has data. Insensibly one begins to twist facts to suit theories, instead of theories to suit facts." Give me more data like the OS, Python version, any other applications running, virtual memory (swap memory) size etc. > > Is there anyway to reclaim the memory? Not enough data to go on :) > > > > > > Thanks, > > Sibtey > > > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- -Anand From sibteym at infotechsw.com Thu Oct 23 12:00:55 2008 From: sibteym at infotechsw.com (Sibtey Mehdi) Date: Thu, 23 Oct 2008 15:30:55 +0530 Subject: [BangPypers] how to relclaim memory In-Reply-To: <8548c5f30810230052w7ea5e8a6gc9801cbe13954602@mail.gmail.com> References: <00af01c934e1$0c573ea0$5fc513ac@pwit.com> <8548c5f30810230052w7ea5e8a6gc9801cbe13954602@mail.gmail.com> Message-ID: <00e601c934f6$3e279370$5fc513ac@pwit.com> I am using Windows XP, pythn 2.5, wxpython 2.8, pygame 1.8. Application over View: In my application I am creating a dialog box that shows a treeView items but on closing of that dialog box I delete the objects that contains the tree items. So I am trying to get that memory used by that tree items. Thanks, Sibtey Sibtey Mehdi wrote: > Hi > > My system is showing 900MB usage of memory, I have deleted some object (del > pythonObj) but the memory is not returned to os, I have also tried > gc.collect() and del (gc.garbage) but still the system is showing 900MB > usage. "Watson, I have no data yet. It is a capital mistake to theorize before one has data. Insensibly one begins to twist facts to suit theories, instead of theories to suit facts." Give me more data like the OS, Python version, any other applications running, virtual memory (swap memory) size etc. > > Is there anyway to reclaim the memory? Not enough data to go on :) > > > > > > Thanks, > > Sibtey > > > > _______________________________________________ From prashanthellina at gmail.com Thu Oct 23 12:18:40 2008 From: prashanthellina at gmail.com (Prashanth Ellina) Date: Thu, 23 Oct 2008 15:48:40 +0530 Subject: [BangPypers] how to relclaim memory In-Reply-To: <00e601c934f6$3e279370$5fc513ac@pwit.com> References: <00af01c934e1$0c573ea0$5fc513ac@pwit.com> <8548c5f30810230052w7ea5e8a6gc9801cbe13954602@mail.gmail.com> <00e601c934f6$3e279370$5fc513ac@pwit.com> Message-ID: <281962dd0810230318g3a76dd88pc7d8bf3c24c61b77@mail.gmail.com> Python 2.5 (unlike 2.4 and earlier versions) is expected to release memory back to the OS when objects are de-referenced. Considering that I would suspect that you are still holding references to python objects. Do you have an objects of user defined classed which define the __del__() method? If yes, this would lead to an issue with for GC when collecting for circularly referenced objects. The gc module has some methods to help is figuring out what objects are still referenced. That would be a good starting point to track down memory issues. HTH, Prashanth On Thu, Oct 23, 2008 at 3:30 PM, Sibtey Mehdi wrote: > > I am using > Windows XP, > pythn 2.5, wxpython 2.8, pygame 1.8. > > Application over View: > In my application I am creating a dialog box that shows a treeView items > but > on closing of that dialog box I delete the objects that contains the tree > items. So I am trying to get that memory used by that tree items. > > Thanks, > Sibtey > > > Sibtey Mehdi wrote: > > Hi > > > > My system is showing 900MB usage of memory, I have deleted some object > (del > > pythonObj) but the memory is not returned to os, I have also tried > > gc.collect() and del (gc.garbage) but still the system is showing 900MB > > usage. > > "Watson, I have no data yet. It is a capital mistake to theorize > before one has data. Insensibly one begins to twist facts to suit > theories, instead of theories to suit facts." > > Give me more data like the OS, Python version, any other applications > running, > virtual memory (swap memory) size etc. > > > > > Is there anyway to reclaim the memory? > > Not enough data to go on :) > > > > > > > > > > > > > Thanks, > > > > Sibtey > > > > > > > > _______________________________________________ > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > -- http://blog.prashanthellina.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From abpillai at gmail.com Thu Oct 23 12:24:38 2008 From: abpillai at gmail.com (Anand Balachandran Pillai) Date: Thu, 23 Oct 2008 15:54:38 +0530 Subject: [BangPypers] how to relclaim memory In-Reply-To: <281962dd0810230318g3a76dd88pc7d8bf3c24c61b77@mail.gmail.com> References: <00af01c934e1$0c573ea0$5fc513ac@pwit.com> <8548c5f30810230052w7ea5e8a6gc9801cbe13954602@mail.gmail.com> <00e601c934f6$3e279370$5fc513ac@pwit.com> <281962dd0810230318g3a76dd88pc7d8bf3c24c61b77@mail.gmail.com> Message-ID: <8548c5f30810230324g3557df50he120a367dd870ca2@mail.gmail.com> Hi, On Thu, Oct 23, 2008 at 3:48 PM, Prashanth Ellina wrote: > Python 2.5 (unlike 2.4 and earlier versions) is expected to release memory > back to the OS when objects are de-referenced. Considering that I would > suspect that you are still holding references to python objects. > > Do you have an objects of user defined classed which define the __del__() > method? If yes, this would lead to an issue with for GC when collecting for > circularly referenced objects. Still, it is quite unnatural for a single Python process to claim 900 MB of memory. Are you sure that the system memory usage is due to Python ? Did you check the task manager for this ? If you have cygwin installed, post the output of "top" command here. > > The gc module has some methods to help is figuring out what objects are > still referenced. That would be a good starting point to track down memory > issues. > > HTH, > Prashanth > > On Thu, Oct 23, 2008 at 3:30 PM, Sibtey Mehdi > wrote: >> >> I am using >> Windows XP, >> pythn 2.5, wxpython 2.8, pygame 1.8. >> >> Application over View: >> In my application I am creating a dialog box that shows a treeView items >> but >> on closing of that dialog box I delete the objects that contains the tree >> items. So I am trying to get that memory used by that tree items. >> >> Thanks, >> Sibtey >> >> >> Sibtey Mehdi wrote: >> > Hi >> > >> > My system is showing 900MB usage of memory, I have deleted some object >> (del >> > pythonObj) but the memory is not returned to os, I have also tried >> > gc.collect() and del (gc.garbage) but still the system is showing 900MB >> > usage. >> >> "Watson, I have no data yet. It is a capital mistake to theorize >> before one has data. Insensibly one begins to twist facts to suit >> theories, instead of theories to suit facts." >> >> Give me more data like the OS, Python version, any other applications >> running, >> virtual memory (swap memory) size etc. >> >> > >> > Is there anyway to reclaim the memory? >> >> Not enough data to go on :) >> >> > >> > >> > >> > >> > >> > Thanks, >> > >> > Sibtey >> > >> > >> > >> > _______________________________________________ >> >> _______________________________________________ >> BangPypers mailing list >> BangPypers at python.org >> http://mail.python.org/mailman/listinfo/bangpypers > > > > -- > http://blog.prashanthellina.com > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- -Anand From sibteym at infotechsw.com Thu Oct 23 12:56:46 2008 From: sibteym at infotechsw.com (Sibtey Mehdi) Date: Thu, 23 Oct 2008 16:26:46 +0530 Subject: [BangPypers] FW: how to relclaim memory Message-ID: <00f301c934fe$0b0b5780$5fc513ac@pwit.com> Python process is consuming near about 500 MB and 400MB others processes. One more problem I am facing is that if I pickle the heavy object, the python process consumes more then 700 MB. These 200 MB memory should be returned after the completion of the dumping but it doesn't return that's why I m thinking that there are some memory leaks. I use the wmi to get the memory details. Memory Details.................. AvailableBytes = "75382784"; AvailableKBytes = "73616"; AvailableMBytes = "71"; CacheBytes = "42872832"; CacheBytesPeak = "296366080"; CacheFaultsPersec = 0; CommitLimit = "2559868928"; CommittedBytes = "1345224704"; DemandZeroFaultsPersec = 58001; FreeSystemPageTableEntries = 191814; PageFaultsPersec = 63525; task manager Snaps Hi, On Thu, Oct 23, 2008 at 3:48 PM, Prashanth Ellina wrote: > Python 2.5 (unlike 2.4 and earlier versions) is expected to release memory > back to the OS when objects are de-referenced. Considering that I would > suspect that you are still holding references to python objects. > > Do you have an objects of user defined classed which define the __del__() > method? If yes, this would lead to an issue with for GC when collecting for > circularly referenced objects. Still, it is quite unnatural for a single Python process to claim 900 MB of memory. Are you sure that the system memory usage is due to Python ? Did you check the task manager for this ? If you have cygwin installed, post the output of "top" command here. > > The gc module has some methods to help is figuring out what objects are > still referenced. That would be a good starting point to track down memory > issues. > > HTH, > Prashanth > > On Thu, Oct 23, 2008 at 3:30 PM, Sibtey Mehdi > wrote: >> >> I am using >> Windows XP, >> pythn 2.5, wxpython 2.8, pygame 1.8. >> >> Application over View: >> In my application I am creating a dialog box that shows a treeView items >> but >> on closing of that dialog box I delete the objects that contains the tree >> items. So I am trying to get that memory used by that tree items. >> >> Thanks, >> Sibtey >> >> >> Sibtey Mehdi wrote: >> > Hi >> > >> > My system is showing 900MB usage of memory, I have deleted some object >> (del >> > pythonObj) but the memory is not returned to os, I have also tried >> > gc.collect() and del (gc.garbage) but still the system is showing 900MB >> > usage. -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: image/jpeg Size: 15983 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: image/jpeg Size: 20382 bytes Desc: not available URL: From abpillai at gmail.com Thu Oct 23 13:30:25 2008 From: abpillai at gmail.com (Anand Balachandran Pillai) Date: Thu, 23 Oct 2008 17:00:25 +0530 Subject: [BangPypers] FW: how to relclaim memory In-Reply-To: <00f301c934fe$0b0b5780$5fc513ac@pwit.com> References: <00f301c934fe$0b0b5780$5fc513ac@pwit.com> Message-ID: <8548c5f30810230430h55c43847s9a719f2e1158500b@mail.gmail.com> Hi, On Thu, Oct 23, 2008 at 4:26 PM, Sibtey Mehdi wrote: > Python process is consuming near about 500 MB and 400MB others processes. > > One more problem I am facing is that if I pickle the heavy object, the > python process consumes more then 700 MB. These 200 MB memory should be > returned after the completion of the dumping but it doesn't return that's > why I m thinking that there are some memory leaks. > Python pickle has memory issues. One sure shot way to write a memory hog Python program is to keep pickling large objects once in a while, especially if the object has cyclic references. How big is the object you are pickling ? If your object is huge, i.e say it is a container with more than 10,000 elements, you shouldn't try to pickle it all at one shot. Or you can try reducing the pickling frequency. If you are pickling GUI objects which are typically large, you can often expect this kind of behaviour, especially objects used by higher level APIs like pygame or wxPython, since the number of references they hold is huge. Try a shallow pickle by writing your own __getstate__ function for the objects. > > > I use the wmi to get the memory details. > > Memory Details.................. > > > > AvailableBytes = "75382784"; > > AvailableKBytes = "73616"; > > AvailableMBytes = "71"; > > CacheBytes = "42872832"; > > CacheBytesPeak = "296366080"; > > CacheFaultsPersec = 0; > > CommitLimit = "2559868928"; > > CommittedBytes = "1345224704"; > > DemandZeroFaultsPersec = 58001; > > FreeSystemPageTableEntries = 191814; > > PageFaultsPersec = 63525; > > > > task manager Snaps > > > > > > > > > > > > > > > > > > Hi, > > > > On Thu, Oct 23, 2008 at 3:48 PM, Prashanth Ellina > > wrote: > >> Python 2.5 (unlike 2.4 and earlier versions) is expected to release memory > >> back to the OS when objects are de-referenced. Considering that I would > >> suspect that you are still holding references to python objects. > >> > >> Do you have an objects of user defined classed which define the __del__() > >> method? If yes, this would lead to an issue with for GC when collecting >> for > >> circularly referenced objects. > > > > Still, it is quite unnatural for a single Python process to claim 900 MB > > of memory. Are you sure that the system memory usage is due to Python ? > > Did you check the task manager for this ? > > > > If you have cygwin installed, post the output of "top" command here. > > > >> > >> The gc module has some methods to help is figuring out what objects are > >> still referenced. That would be a good starting point to track down memory > >> issues. > >> > >> HTH, > >> Prashanth > >> > >> On Thu, Oct 23, 2008 at 3:30 PM, Sibtey Mehdi > >> wrote: > >>> > >>> I am using > >>> Windows XP, > >>> pythn 2.5, wxpython 2.8, pygame 1.8. > >>> > >>> Application over View: > >>> In my application I am creating a dialog box that shows a treeView items > >>> but > >>> on closing of that dialog box I delete the objects that contains the tree > >>> items. So I am trying to get that memory used by that tree items. > >>> > >>> Thanks, > >>> Sibtey > >>> > >>> > >>> Sibtey Mehdi wrote: > >>> > Hi > >>> > > >>> > My system is showing 900MB usage of memory, I have deleted some object > >>> (del > >>> > pythonObj) but the memory is not returned to os, I have also tried > >>> > gc.collect() and del (gc.garbage) but still the system is showing >>> > 900MB > >>> > usage. > > > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- -Anand From arunpython at ymail.com Fri Oct 31 18:19:11 2008 From: arunpython at ymail.com (Arun Python) Date: Fri, 31 Oct 2008 22:49:11 +0530 (IST) Subject: [BangPypers] Python 3.0 - Windows file is not working Message-ID: <831249.84427.qm@web95010.mail.in2.yahoo.com> Hi all, I am very new to Python Programming Language. Before which I was doing programming in Visual C++. I just thought of trying it out in this new language. I was going through the website, telling that Python 3 is going to have different syntax altogether, I downloaded the same but it is not working in the windows xp. Whereas the 2.6 final release is working. Is there any further upgrade of 3 available or otherwise guide me. With Thanks & Regards, Arun Be the first one to try the new Messenger 9 Beta! Go to http://in.messenger.yahoo.com/win/ From rajeev.sebastian at gmail.com Fri Oct 31 19:23:16 2008 From: rajeev.sebastian at gmail.com (Rajeev J Sebastian) Date: Fri, 31 Oct 2008 23:53:16 +0530 Subject: [BangPypers] Python 3.0 - Windows file is not working In-Reply-To: <831249.84427.qm@web95010.mail.in2.yahoo.com> References: <831249.84427.qm@web95010.mail.in2.yahoo.com> Message-ID: <79a035420810311123q23ebe056w4df0e295f697cc73@mail.gmail.com> On Fri, Oct 31, 2008 at 10:49 PM, Arun Python wrote: > Hi all, > > I am very new to Python Programming Language. Before which I was doing programming in Visual C++. I just thought of trying it out in this new language. > > I was going through the website, telling that Python 3 is going to have different syntax altogether, I downloaded the same but it is not working in the windows xp. Whereas the 2.6 final release is working. > > Is there any further upgrade of 3 available or otherwise guide me. If you are just starting with Python, then using 2.6 is more advisable. Regards Rajeev J Sebastian