From agoldgod at gmail.com Mon Sep 1 10:09:14 2008 From: agoldgod at gmail.com (goldgod a) Date: Mon, 1 Sep 2008 13:39:14 +0530 Subject: [BangPypers] Tramline implementation Message-ID: <105c9ccc0809010109o18f1919ax3fc504cc22bea5b@mail.gmail.com> hi, Any body used tramline python library. Any idea to implement it separately like uploading files with python-cgi with out the plone/zope support. -- Thanks & Regards, goldgod -------------- next part -------------- An HTML attachment was scrubbed... URL: From heshan.suri at gmail.com Tue Sep 2 07:15:58 2008 From: heshan.suri at gmail.com (Heshan Suriyaarachchi) Date: Tue, 2 Sep 2008 10:45:58 +0530 Subject: [BangPypers] Module question Message-ID: <12e5d0d90809012215k3f946f5fn14ee7ab74fdcd10a@mail.gmail.com> Hi, One of my scripts returns a module like below. What I need to do is to extract the full path of the location of the script as string. i.e. '/home/heshan/repo/scripts/annotationScript.py' . Since I am dynamically loading the script, it's name and full path may vary. Can you suggest me a mechanism to extract the full path from the above data structure. -- Regards, Heshan Suriyaarachchi http://heshans.blogspot.com/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From abhinav.sarkar at gmail.com Tue Sep 2 07:21:47 2008 From: abhinav.sarkar at gmail.com (Abhinav Sarkar) Date: Tue, 02 Sep 2008 10:51:47 +0530 Subject: [BangPypers] Module question In-Reply-To: <12e5d0d90809012215k3f946f5fn14ee7ab74fdcd10a@mail.gmail.com> References: <12e5d0d90809012215k3f946f5fn14ee7ab74fdcd10a@mail.gmail.com> Message-ID: <48BCCD6B.5050305@gmail.com> Heshan Suriyaarachchi wrote: > Hi, > One of my scripts returns a module like below. > '/home/heshan/repo/scripts/annotationScript.py'> > What I need to do is to extract the full path of the location of > the script as string. i.e. > '/home/heshan/repo/scripts/annotationScript.py' . Since I am > dynamically loading the script, it's name and full path may vary. Can > you suggest me a mechanism to extract the full path from the above > data structure. > -- > Regards, > Heshan Suriyaarachchi > > http://heshans.blogspot.com/ > ------------------------------------------------------------------------ > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > Hi, __path__ attribute of module contains the path of file. >>> import lastfm >>> lastfm.__path__ ['c:\\python25\\lib\\site-packages\\lastfm-0.1-py2.5.egg\\lastfm'] I hope it helps. Cheers, -- Abhinav Sarkar Fair Isaac India Mobile:+91-9731596137 Office: +91-8041371605 Web: http://claimid.com/abhin4v Twitter: http://twitter.com/abhin4v --------- The world is a book, those who do not travel read only one page. From heshan.suri at gmail.com Tue Sep 2 07:31:55 2008 From: heshan.suri at gmail.com (Heshan Suriyaarachchi) Date: Tue, 2 Sep 2008 11:01:55 +0530 Subject: [BangPypers] Module question In-Reply-To: <48BCCD6B.5050305@gmail.com> References: <12e5d0d90809012215k3f946f5fn14ee7ab74fdcd10a@mail.gmail.com> <48BCCD6B.5050305@gmail.com> Message-ID: <12e5d0d90809012231s7f8cbe2ft19bed4abe1c9e87f@mail.gmail.com> Hi, What I need to do is somehow extract the 4th item of the below data structre. i.e. the full path Hi, > __path__ attribute of module contains the path of file. > >>> import lastfm > >>> lastfm.__path__ > ['c:\\python25\\lib\\site-packages\\lastfm-0.1-py2.5.egg\\lastfm'] > > I hope it helps. > Cheers, > > -- > Abhinav Sarkar > Fair Isaac India > > > -- Regards, Heshan Suriyaarachchi http://heshans.blogspot.com/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From abhinav.sarkar at gmail.com Tue Sep 2 07:33:43 2008 From: abhinav.sarkar at gmail.com (abhinav sarkar) Date: Tue, 2 Sep 2008 11:03:43 +0530 Subject: [BangPypers] Module question In-Reply-To: <48BCCD6B.5050305@gmail.com> References: <12e5d0d90809012215k3f946f5fn14ee7ab74fdcd10a@mail.gmail.com> <48BCCD6B.5050305@gmail.com> Message-ID: On Tue, Sep 2, 2008 at 10:51 AM, Abhinav Sarkar wrote: > Heshan Suriyaarachchi wrote: > >> Hi, >> One of my scripts returns a module like below. >> > '/home/heshan/repo/scripts/annotationScript.py'> >> What I need to do is to extract the full path of the location of the >> script as string. i.e. '/home/heshan/repo/scripts/annotationScript.py' . >> Since I am dynamically loading the script, it's name and full path may vary. >> Can you suggest me a mechanism to extract the full path from the above data >> structure. >> -- >> Regards, >> Heshan Suriyaarachchi >> >> http://heshans.blogspot.com/ >> ------------------------------------------------------------------------ >> >> _______________________________________________ >> BangPypers mailing list >> BangPypers at python.org >> http://mail.python.org/mailman/listinfo/bangpypers >> >> > Hi, > __path__ attribute of module contains the path of file. > >>> import lastfm > >>> lastfm.__path__ > ['c:\\python25\\lib\\site-packages\\lastfm-0.1-py2.5.egg\\lastfm'] > > I hope it helps. > Cheers, > > -- > Abhinav Sarkar > Fair Isaac India > > Mobile:+91-9731596137 > Office: +91-8041371605 > > Web: http://claimid.com/abhin4v > Twitter: http://twitter.com/abhin4v > --------- > The world is a book, those who do not travel read only one page. > > Hi, I was mistaken in last reply. __path__ attribute exists only for packages. You should use __file__ attribute. It works for packages and modules too. >>> import lastfm >>> from lastfm import api >>> api.__file__ 'c:\\python25\\lib\\site-packages\\lastfm-0.1-py2.5.egg\\lastfm\\api.pyc' >>> lastfm.__file__ 'c:\\python25\\lib\\site-packages\\lastfm-0.1-py2.5.egg\\lastfm\\__init__.pyc' Cheers -- Abhinav Sarkar Fair Isaac India Mobile:+91-9731596137 Office: +91-8041371605 Web: http://claimid.com/abhin4v Twitter: http://twitter.com/abhin4v --------- The world is a book, those who do not travel read only one page. -------------- next part -------------- An HTML attachment was scrubbed... URL: From heshan.suri at gmail.com Tue Sep 2 08:22:35 2008 From: heshan.suri at gmail.com (Heshan Suriyaarachchi) Date: Tue, 2 Sep 2008 11:52:35 +0530 Subject: [BangPypers] Module question In-Reply-To: References: <12e5d0d90809012215k3f946f5fn14ee7ab74fdcd10a@mail.gmail.com> <48BCCD6B.5050305@gmail.com> Message-ID: <12e5d0d90809012322o2d10fc7foae890486719b5a28@mail.gmail.com> Hi Abhinav, I managed to overcome the problem. Thanx :) On Tue, Sep 2, 2008 at 11:03 AM, abhinav sarkar wrote: > > > On Tue, Sep 2, 2008 at 10:51 AM, Abhinav Sarkar wrote: > >> Heshan Suriyaarachchi wrote: >> >>> Hi, >>> One of my scripts returns a module like below. >>> >> '/home/heshan/repo/scripts/annotationScript.py'> >>> What I need to do is to extract the full path of the location of the >>> script as string. i.e. '/home/heshan/repo/scripts/annotationScript.py' . >>> Since I am dynamically loading the script, it's name and full path may vary. >>> Can you suggest me a mechanism to extract the full path from the above data >>> structure. >>> -- >>> Regards, >>> Heshan Suriyaarachchi >>> >>> http://heshans.blogspot.com/ >>> ------------------------------------------------------------------------ >>> >>> _______________________________________________ >>> BangPypers mailing list >>> BangPypers at python.org >>> http://mail.python.org/mailman/listinfo/bangpypers >>> >>> >> Hi, >> __path__ attribute of module contains the path of file. >> >>> import lastfm >> >>> lastfm.__path__ >> ['c:\\python25\\lib\\site-packages\\lastfm-0.1-py2.5.egg\\lastfm'] >> >> I hope it helps. >> Cheers, >> >> -- >> Abhinav Sarkar >> Fair Isaac India >> >> Mobile:+91-9731596137 >> Office: +91-8041371605 >> >> Web: http://claimid.com/abhin4v >> Twitter: http://twitter.com/abhin4v >> --------- >> The world is a book, those who do not travel read only one page. >> >> > Hi, > I was mistaken in last reply. __path__ attribute exists only for packages. > You should use __file__ attribute. It works for packages and modules too. > > >>> import lastfm > >>> from lastfm import api > >>> api.__file__ > 'c:\\python25\\lib\\site-packages\\lastfm-0.1-py2.5.egg\\lastfm\\api.pyc' > >>> lastfm.__file__ > > 'c:\\python25\\lib\\site-packages\\lastfm-0.1-py2.5.egg\\lastfm\\__init__.pyc' > > > Cheers > -- > Abhinav Sarkar > Fair Isaac India > > Mobile:+91-9731596137 > Office: +91-8041371605 > > Web: http://claimid.com/abhin4v > Twitter: http://twitter.com/abhin4v > --------- > The world is a book, those who do not travel read only one page. > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- Regards, Heshan Suriyaarachchi http://heshans.blogspot.com/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From kushaldas at gmail.com Fri Sep 5 15:16:36 2008 From: kushaldas at gmail.com (Kushal Das) Date: Fri, 5 Sep 2008 18:46:36 +0530 Subject: [BangPypers] =?utf-8?b?4oCYQSBCeXRlIG9mIFB5dGhvbuKAmSB1cGRhdGVk?= =?utf-8?q?_for_Python_3=2E0?= Message-ID: Hi all, Swaroop just released the latest version of his book "A Byte of Python", the new version is for Python 3.0. Read the post at http://www.swaroopch.com/blog/book-updated-for-python-3000/ The book can be found at http://www.swaroopch.com/notes/Python Kushal -- http://fedoraproject.org http://kushaldas.in http://badvista.org http://noooxml.org From dpatel_07 at rediffmail.com Sat Sep 6 14:03:15 2008 From: dpatel_07 at rediffmail.com (Deepak Patel) Date: 6 Sep 2008 12:03:15 -0000 Subject: [BangPypers] Re :Use of module (Include file) in Python??? Message-ID: <1220701778.S.5748.26107.f4mail-234-243.rediffmail.com.old.replied.1220702595.31245@webmail.rediffmail.com> Hello,I am new to Python and need some help. Can someone please tell me whether I can use the Python Module like include file? Is there a way to use the "include" file in Python? If I try to include a file with "# include", that line is treated as comment. What is the directive to include the include file in Python?I have created a Python prgram, say RegDesc.py for my registers class definitions, for example, called as:class Reg:with all the register methods, like ReadReg(), WriteReg() etc.In the same file, I have description of various registers, like:ConfigReg = Reg(.....).Now I want to treat my RegDesc.py as include file to my other programs and use the Reg class methods in my other programs. How can I do this? Do I need to use module?Thanks,Deepak -------------- next part -------------- An HTML attachment was scrubbed... URL: From venkatasubramanian at gmail.com Sat Sep 6 14:45:55 2008 From: venkatasubramanian at gmail.com (venkata subramanian) Date: Sat, 6 Sep 2008 08:45:55 -0400 Subject: [BangPypers] Re :Use of module (Include file) in Python??? In-Reply-To: <1220701778.S.5748.26107.f4mail-234-243.rediffmail.com.old.replied.1220702595.31245@webmail.rediffmail.com> References: <1220701778.S.5748.26107.f4mail-234-243.rediffmail.com.old.replied.1220702595.31245@webmail.rediffmail.com> Message-ID: Hi Deepak, You can do this. It is using the keyword called import. The basic syntax is import example: import RegDesc then, you can do RegDesc.foo(bar) My friend had the same problem. He read the tutorial till one point and missed the part where they talk about modules and packages. So, go ahead and make sure you covered those topics. Like other languages, your module should be in a 'path' called pythonpath. you can do import sys and then type sys.path to know the path. All the modules in your current directory can be imported (well, without going into the nittie gritties of it). On Sat, Sep 6, 2008 at 8:03 AM, Deepak Patel wrote: > Hello, > > I am new to Python and need some help. > > Can someone please tell me whether I can use the Python Module like include > file? > > Is there a way to use the "include" file in Python? > > If I try to include a file with "# include", that line is treated as > comment. > > What is the directive to include the include file in Python? > > I have created a Python prgram, say RegDesc.py for my registers class > definitions, for example, called as:class Reg:with all the register methods, > like ReadReg(), WriteReg() etc. > > In the same file, I have description of various registers, like:ConfigReg = > Reg(.....). > > Now I want to treat my RegDesc.py as include file to my other programs and > use the Reg class methods in my other programs. > > How can I do this? Do I need to use module? > > Thanks, > Deepak > > > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > From elsen.david08 at gmail.com Sat Sep 6 21:44:17 2008 From: elsen.david08 at gmail.com (David Elsen) Date: Sat, 6 Sep 2008 12:44:17 -0700 Subject: [BangPypers] Re :Use of module (Include file) in Python??? In-Reply-To: References: <1220701778.S.5748.26107.f4mail-234-243.rediffmail.com.old.replied.1220702595.31245@webmail.rediffmail.com> Message-ID: Hi Venkata, Thanks. I could do this. Import my first file as module and then using all my methods . format, but I would like to include my file and want to use just as not as .. Hope I am clear. Thanks, Deepak On Sat, Sep 6, 2008 at 5:45 AM, venkata subramanian < venkatasubramanian at gmail.com> wrote: > Hi Deepak, > You can do this. > It is using the keyword called import. > > The basic syntax is > import > > example: import RegDesc > > then, you can do RegDesc.foo(bar) > > My friend had the same problem. He read the tutorial till > one point and missed the part where they talk about modules > and packages. So, go ahead and make sure you covered those topics. > > Like other languages, your module should be in a 'path' called pythonpath. > you can do import sys and then type sys.path to know the path. > > All the modules in your current directory can be imported (well, > without going into the nittie gritties of it). > > > > On Sat, Sep 6, 2008 at 8:03 AM, Deepak Patel > wrote: > > Hello, > > > > I am new to Python and need some help. > > > > Can someone please tell me whether I can use the Python Module like > include > > file? > > > > Is there a way to use the "include" file in Python? > > > > If I try to include a file with "# include", that line is treated as > > comment. > > > > What is the directive to include the include file in Python? > > > > I have created a Python prgram, say RegDesc.py for my registers class > > definitions, for example, called as:class Reg:with all the register > methods, > > like ReadReg(), WriteReg() etc. > > > > In the same file, I have description of various registers, like:ConfigReg > = > > Reg(.....). > > > > Now I want to treat my RegDesc.py as include file to my other programs > and > > use the Reg class methods in my other programs. > > > > How can I do this? Do I need to use module? > > > > Thanks, > > Deepak > > > > > > > > _______________________________________________ > > BangPypers mailing list > > BangPypers at python.org > > http://mail.python.org/mailman/listinfo/bangpypers > > > > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > -------------- next part -------------- An HTML attachment was scrubbed... URL: From abhinav.sarkar at gmail.com Sat Sep 6 21:46:29 2008 From: abhinav.sarkar at gmail.com (Abhinav Sarkar) Date: Sun, 07 Sep 2008 01:16:29 +0530 Subject: [BangPypers] Re :Use of module (Include file) in Python??? In-Reply-To: References: <1220701778.S.5748.26107.f4mail-234-243.rediffmail.com.old.replied.1220702595.31245@webmail.rediffmail.com> Message-ID: <48C2DE15.7050306@gmail.com> David Elsen wrote: > Hi Venkata, > Thanks. > I could do this. > Import my first file as module and then using all my methods > . format, but I would like to include my > file and want to use just as not as > .. > Hope I am clear. > Thanks, > Deepak > > On Sat, Sep 6, 2008 at 5:45 AM, venkata subramanian > > > wrote: > > Hi Deepak, > You can do this. > It is using the keyword called import. > > The basic syntax is > import > > example: import RegDesc > > then, you can do RegDesc.foo(bar) > > My friend had the same problem. He read the tutorial till > one point and missed the part where they talk about modules > and packages. So, go ahead and make sure you covered those topics. > > Like other languages, your module should be in a 'path' called > pythonpath. > you can do import sys and then type sys.path to know the path. > > All the modules in your current directory can be imported (well, > without going into the nittie gritties of it). > > > > On Sat, Sep 6, 2008 at 8:03 AM, Deepak Patel > > wrote: > > Hello, > > > > I am new to Python and need some help. > > > > Can someone please tell me whether I can use the Python Module > like include > > file? > > > > Is there a way to use the "include" file in Python? > > > > If I try to include a file with "# include", that line is treated as > > comment. > > > > What is the directive to include the include file in Python? > > > > I have created a Python prgram, say RegDesc.py for my registers > class > > definitions, for example, called as:class Reg:with all the > register methods, > > like ReadReg(), WriteReg() etc. > > > > In the same file, I have description of various registers, > like:ConfigReg = > > Reg(.....). > > > > Now I want to treat my RegDesc.py as include file to my other > programs and > > use the Reg class methods in my other programs. > > > > How can I do this? Do I need to use module? > > > > Thanks, > > Deepak > > > > > > > > _______________________________________________ > > BangPypers mailing list > > BangPypers at python.org > > http://mail.python.org/mailman/listinfo/bangpypers > > > > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > > ------------------------------------------------------------------------ > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > Hi In that case you should do: from modulename import methodname or to import all methods at once do: from modulename import * This should work. Cheers, -- Abhinav Sarkar Web: http://claimid.com/abhin4v Twitter: http://twitter.com/abhin4v --------- The world is a book, those who do not travel read only one page. From rajeev.sebastian at gmail.com Sat Sep 6 22:28:15 2008 From: rajeev.sebastian at gmail.com (Rajeev J Sebastian) Date: Sun, 7 Sep 2008 01:58:15 +0530 Subject: [BangPypers] Re :Use of module (Include file) in Python??? In-Reply-To: <48C2DE15.7050306@gmail.com> References: <1220701778.S.5748.26107.f4mail-234-243.rediffmail.com.old.replied.1220702595.31245@webmail.rediffmail.com> <48C2DE15.7050306@gmail.com> Message-ID: <79a035420809061328y558486cck8f222e85bdfc820b@mail.gmail.com> On Sun, Sep 7, 2008 at 1:16 AM, Abhinav Sarkar wrote: > > from modulename import methodname > > or to import all methods at once do: > > from modulename import * Of course ... the first way is better form than the second for various reasons ... so you might want to make that a habit if you're starting on a career in python. Regards Rajeev J Sebastian From sibteym at infotechsw.com Tue Sep 9 05:47:12 2008 From: sibteym at infotechsw.com (Sibtey Mehdi) Date: Tue, 9 Sep 2008 09:17:12 +0530 Subject: [BangPypers] which framework is better pylon or django Message-ID: <004a01c9122e$be064f90$5fc513ac@pwit.com> Hi I am planning to develop a website but I don't have any idea about the python framework. I found 2 or 3 framework (pylon, Django, turbo Gear) on net but couldn't understand which one should be used. Can you suggest me which framework should be better to develop a simple website? Thanks, Sibtey Mehdi -------------- next part -------------- An HTML attachment was scrubbed... URL: From pradeep at btbytes.com Tue Sep 9 05:53:13 2008 From: pradeep at btbytes.com (Pradeep Gowda) Date: Mon, 8 Sep 2008 23:53:13 -0400 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: <004a01c9122e$be064f90$5fc513ac@pwit.com> References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: <64A6A309-832A-4B3F-919B-C0A9487A0F83@btbytes.com> On Sep 8, 2008, at 11:47 PM, Sibtey Mehdi wrote: > Hi > > I am planning to develop a website but I don?t have any idea about > the python framework. I found 2 or 3 framework (pylon, Django, > turbo Gear) on net but couldn?t understand which one should be used. > > Can you suggest me which framework should be better to develop a > simple website? > > > By simple website, I assume a website having mostly textual+image content with perhaps a few forms for user interaction. In that case, django may be a good fit. From anandology at gmail.com Tue Sep 9 06:07:43 2008 From: anandology at gmail.com (Anand Chitipothu) Date: Tue, 9 Sep 2008 09:37:43 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: <004a01c9122e$be064f90$5fc513ac@pwit.com> References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: <41139fcb0809082107lc776e62k391580e8daa412ac@mail.gmail.com> On Tue, Sep 9, 2008 at 9:17 AM, Sibtey Mehdi wrote: > Hi > > I am planning to develop a website but I don't have any idea about the > python framework. I found 2 or 3 framework (pylon, Django, turbo Gear) on > net but couldn't understand which one should be used. > > Can you suggest me which framework should be better to develop a simple > website? Try web.py. http://webpy.org From parth.technofreak at gmail.com Tue Sep 9 06:08:52 2008 From: parth.technofreak at gmail.com (Parthan SR) Date: Tue, 09 Sep 2008 09:38:52 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: <004a01c9122e$be064f90$5fc513ac@pwit.com> References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: <48C5F6D4.1020107@gmail.com> Sibtey Mehdi wrote: > > Hi > > I am planning to develop a website but I don?t have any idea about the > python framework. I found 2 or 3 framework (pylon, Django, turbo Gear) > on net but couldn?t understand which one should be used. > > > > Can you suggest me which framework should be better to develop a > simple website? > > What kind of a website is it going to be? If it is a simple website, with a few pages and few forms, then you can easily do them with smaller ones like webpy (+ a templating system of your choice). If you want to build a blogging website or something like a new website which has too frequently changing content, Django might be a good choice. If you are building some web app like intranet, then both Django and Pylons are good choice. -- --- With Regards, Parthan "technofreak" 2FF01026 http://blog.technofreak.in From skpatel20 at hotmail.com Tue Sep 9 08:10:48 2008 From: skpatel20 at hotmail.com (Sanjaya Kumar Patel) Date: Tue, 9 Sep 2008 11:40:48 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: <004a01c9122e$be064f90$5fc513ac@pwit.com> References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: This is a hot topic and a lot of posts around it are available on the Internet, most of which might confuse to new comers. After my about three years of watch on this, and considerable experience on TurboGears, my suggestions go as below. If it is just developing a website, and not a part of your career decision to practice something seriously, you may choose the technology you are most familiar with, and it can very well be Drupal or DotNetNuke. But, if you think to practice a good framework and add the experience to your assets, I would suggest TurboGears for the same reasons that I chose it. Mainly these: - SQLAlchemy support (SQLAlchemy is a serious advantage when it comes to bigger applications) - Quite stable and popular - Advanced in technology - A lot of components available on the top to make life smoother Some references: http://sanjaypatel.blogspot.com/ http://groups.google.com/group/turbogears/browse_thread/thread/02ebc86c38a4075a/e32a4b4a3dd393c4?#e32a4b4a3dd393c4 Sanjay _________________________________________________________________ Search for videos of Bollywood, Hollywood, Mollywood and every other wood, only on Live.com http://www.live.com/?scope=video&form=MICOAL -------------- next part -------------- An HTML attachment was scrubbed... URL: From pintooo15 at gmail.com Tue Sep 9 08:46:40 2008 From: pintooo15 at gmail.com (Diabolic Preacher) Date: Tue, 9 Sep 2008 12:16:40 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: > ... serious advantage when it comes to > bigger applications) > - ... popular > - Advanced... > -...make life smoother These points do sound like buzzwords, coming from someone who's chosen to build skills on turbogears. I do not underestimate anything but aren't those points kind of biased towards a pre-determined conclusion? Not that it's bad and perhaps the link provided below would tell more, but the mail body itself is what shows up first. -- Diabolic Preacher As Is Blog: http://pintooo15.livejournal.com/ Bookmarks: http://simpy.com/user/dpreacher John F. Kennedy - "Liberty without learning is always in peril; learning without liberty is always in vain." From noufal at gmail.com Tue Sep 9 09:01:03 2008 From: noufal at gmail.com (Noufal Ibrahim) Date: Tue, 9 Sep 2008 12:31:03 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: <9963e56e0809090001t567564d9h8521b34322ec8503@mail.gmail.com> TG is nice. I have used it for a couple of apps but there's a lot of magic under the hood which which causes frustration proportional to the size of the project. SQLAlchemy is a redeeming feature. From reviews on the net, it *does* seem to be the ORM of choice when using Python. Some of it's other components are not as hot though (although they have replacements). Kid is the first thing that comes to mind. YMMV To the original poster, Unless you *really* want to develop custom functionality, it's quicker and easier to download/customise something prebuilt (like Wordpress for blogs etc.) -- ~noufal From venkat83 at gmail.com Tue Sep 9 09:44:34 2008 From: venkat83 at gmail.com (Venkatraman S) Date: Tue, 9 Sep 2008 13:14:34 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: <9963e56e0809090001t567564d9h8521b34322ec8503@mail.gmail.com> References: <004a01c9122e$be064f90$5fc513ac@pwit.com> <9963e56e0809090001t567564d9h8521b34322ec8503@mail.gmail.com> Message-ID: Apologies for top posting, but a quick link : http://www.ae.iitm.ac.in/pipermail/ilugc/2008-April/040727.html Personal Preference: Go for Django - it is fun! Venkat Blog @ http://blizzardzblogs.blogspot.com On 9/9/08, Noufal Ibrahim wrote: > TG is nice. I have used it for a couple of apps but there's a lot of > magic under the hood which which causes frustration proportional to > the size of the project. > > SQLAlchemy is a redeeming feature. From reviews on the net, it *does* > seem to be the ORM of choice when using Python. > Some of it's other components are not as hot though (although they > have replacements). Kid is the first thing that comes to mind. > > YMMV > > To the original poster, > Unless you *really* want to develop custom functionality, it's > quicker and easier to download/customise something prebuilt (like > Wordpress for blogs etc.) > > > -- > ~noufal > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > -- From skpatel20 at hotmail.com Tue Sep 9 12:10:45 2008 From: skpatel20 at hotmail.com (Sanjaya Kumar Patel) Date: Tue, 9 Sep 2008 15:40:45 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: > > ... serious advantage when it comes to > > bigger applications) > > - ... popular > > - Advanced... > > -...make life smoother > > These points do sound like buzzwords, coming from someone who's chosen > to build skills on turbogears. I do not underestimate anything but > aren't those points kind of biased towards a pre-determined > conclusion? Not that it's bad and perhaps the link provided below > would tell more, but the mail body itself is what shows up first. I tried to summarize my views in simple terms quickly, what probably sounded like *buzzwords* to you. And, if someone wants to dig into details, there are many posts in the Internet, which I did not want to waste time repeating. I readily gave some references which I liked. Any genuine queries for helping the subject, I will be glad to attempt. I am trying to share my experience because I feel it might help. I don't gain anything in person by recommending TurboGears. Sanjay _________________________________________________________________ Searching for weekend getaways? Try Live.com http://www.live.com/?scope=video&form=MICOAL -------------- next part -------------- An HTML attachment was scrubbed... URL: From ranganaths at gmail.com Tue Sep 9 12:16:38 2008 From: ranganaths at gmail.com (Ranganath s) Date: Tue, 9 Sep 2008 15:46:38 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: <77bb36840809090316w26f1d981g131d6cb8235efd02@mail.gmail.com> I think webpy is simple N yet powerful.. try it out.. Ranganath.S On Tue, Sep 9, 2008 at 3:40 PM, Sanjaya Kumar Patel wrote: > > > ... serious advantage when it comes to > > > bigger applications) > > > - ... popular > > > - Advanced... > > > -...make life smoother > > > > These points do sound like buzzwords, coming from someone who's chosen > > to build skills on turbogears. I do not underestimate anything but > > aren't those points kind of biased towards a pre-determined > > conclusion? Not that it's bad and perhaps the link provided below > > would tell more, but the mail body itself is what shows up first. > > I tried to summarize my views in simple terms quickly, what probably > sounded like *buzzwords* to you. And, if someone wants to dig into details, > there are many posts in the Internet, which I did not want to waste time > repeating. I readily gave some references which I liked. > > Any genuine queries for helping the subject, I will be glad to attempt. I > am trying to share my experience because I feel it might help. I don't gain > anything in person by recommending TurboGears. > > Sanjay > > > ------------------------------ > Hottest news and in-depth analysis that goes beyond the headlines. Only on > MSN News Check it out! > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- I blog at http://ranganaths.wordpress.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From skpatel20 at hotmail.com Tue Sep 9 12:23:25 2008 From: skpatel20 at hotmail.com (Sanjaya Kumar Patel) Date: Tue, 9 Sep 2008 15:53:25 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: <9963e56e0809090001t567564d9h8521b34322ec8503@mail.gmail.com> References: <004a01c9122e$be064f90$5fc513ac@pwit.com> <9963e56e0809090001t567564d9h8521b34322ec8503@mail.gmail.com> Message-ID: > TG is nice. I have used it for a couple of apps but there's a lot of > magic under the hood which which causes frustration proportional to > the size of the project. My experience with TurboGears 1.0.6 today is quite smooth. Of course, we were having some hurdles before a year or so, but now the stability and the documentation of the project seems quite good, although I can't give a comparative view, as I have not used other frameworks much. > SQLAlchemy is a redeeming feature. From reviews on the net, it *does* > seem to be the ORM of choice when using Python. > Some of it's other components are not as hot though (although they > have replacements). Kid is the first thing that comes to mind. Genshi is taking over Kid as SQLAlchemy is taking over SQLObject. Today, anybody developing a serious application on TG would prefer TurboGears + SQLAlchemy + Genshi. In the coming version 1.1, these are the defaults. For a longer project, one could consider TurboGears 2.0, which is built over Pylons and promises a lot. Sanjay _________________________________________________________________ Searching for the best deals on travel? Visit MSN Travel. http://in.msn.com/coxandkings -------------- next part -------------- An HTML attachment was scrubbed... URL: From sibteym at infotechsw.com Tue Sep 9 13:41:20 2008 From: sibteym at infotechsw.com (Sibtey Mehdi) Date: Tue, 9 Sep 2008 17:11:20 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: <003f01c91270$fc115040$5fc513ac@pwit.com> Thanks to all of you for giving me the good suggestions. I am a python developer and didn't get the chance to work on web app. Now I am thinking to learn something about web app. Thanks, Sibtey Mehdi -------------- next part -------------- An HTML attachment was scrubbed... URL: From pintooo15 at gmail.com Tue Sep 9 13:52:19 2008 From: pintooo15 at gmail.com (Diabolic Preacher) Date: Tue, 9 Sep 2008 17:22:19 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: On Tue, Sep 9, 2008 at 3:40 PM, Sanjaya Kumar Patel wrote: >> > ... serious advantage when it comes to >> > bigger applications) >> > - ... popular >> > - Advanced... >> > -...make life smoother ... > I tried to summarize my views in simple terms quickly, what probably sounded > like *buzzwords* to you. And, if someone wants to dig into details, there > are many posts in the Internet, which I did not want to waste time > repeating. I readily gave some references which I liked. no problem :) . you misinterpreted exactly as expected. I think giving references was a cool and helpful idea for saving time and i do say it well intended. but i suppose you knowing turbogears would've summarised with something more concrete than the decorative words...i mean for example you say its a serious advantage because... in not more than 10 words... that wouldn't harm anyone, now will it? > Any genuine queries for helping the subject, I will be glad to attempt. I am > trying to share my experience because I feel it might help. I don't gain > anything in person by recommending TurboGears. I know you did not want to gain anything in person, so I said what you wrote, however, sounded like some promo ad, which i am sure is more honest than anything that's been called as an advertisement or promotion. I did hope that your summary would let me know key reasons why you picked up TG, in technical words itself. Hope I cleared out things better this time. -- Diabolic Preacher As Is Blog: http://pintooo15.livejournal.com/ Bookmarks: http://simpy.com/user/dpreacher From skpatel20 at hotmail.com Tue Sep 9 15:10:35 2008 From: skpatel20 at hotmail.com (Sanjaya Kumar Patel) Date: Tue, 9 Sep 2008 18:40:35 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: Hi Diabolic, > promotion. I did hope that your summary would let me know key reasons > why you picked up TG, in technical words itself. Here I go, trying to be more specific and technical this time. :) 1. TG has SQLAlchemy readily integrated. The ORM of Django or RoR is suitable for new web applications, but it has got many limitations as compared to SA. For example, ORM of Django or RoR does not support composite primary keys. Hence, for complex application development or for integrating with already existing databases, I would highly recommend SA. TG and Pylons support SA, but Django does not. 2. While I started using TG, I don't think Django was having builtin AJAX support. TG, on the other hand, supports AJAX development since long. 3. Pylons is a very good framework, but it does not recommand any specific default components. Because TG is more definitive in terms of defaults, you get much more components on the top of TG to make the life of a business application developer smooth. This article is really useful on deciding TG or Pylons -> http://groups.google.com/group/turbogears/browse_thread/thread/02ebc86c38a4075a/e32a4b4a3dd393c4?#e32a4b4a3dd393c4 4. TG2 is built on top of Pylons. Pylons is quite advanced in terms of technology compared to Django. Another reference here -> http://nrcfosshelpline.in/code/wiki/AcademicPython (see Pradeep's observations). One of the references that I was giving, http://sanjaypatel.blogspot.com/, is actually my article which I blogged one year back, which elaborates these more. I think it stills holds very true. These are my views. Would be happy to listen to different views. Sanjay _________________________________________________________________ Movies, sports & news! Get your daily entertainment fix, only on live.com http://www.live.com/?scope=video&form=MICOAL -------------- next part -------------- An HTML attachment was scrubbed... URL: From pradeep at btbytes.com Tue Sep 9 17:01:51 2008 From: pradeep at btbytes.com (Pradeep Gowda) Date: Tue, 9 Sep 2008 11:01:51 -0400 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: <003f01c91270$fc115040$5fc513ac@pwit.com> References: <004a01c9122e$be064f90$5fc513ac@pwit.com> <003f01c91270$fc115040$5fc513ac@pwit.com> Message-ID: <30B50F21-D5DD-4B5D-A120-5D54E65A1FA7@btbytes.com> On Sep 9, 2008, at 7:41 AM, Sibtey Mehdi wrote: > Thanks to all of you for giving me the good suggestions. I am a > python developer and didn?t get the chance to work on web app. Now > I am thinking to learn something about web app. > Hi Sibtey, Thanks for reinvigorating the sleepy pypers. Nothing like a web- framework slug-fest to shake 'em out of hibernation. Since you are interested in a "web app" and not just a website (which is what I gathered from your first post), the simplest ``framework" to try would be web.py. I have previously argued for Pylons, Django, web.py and Zope frameworks(!) at different points in time. But, coming from a non-web development experience, web.py would be the least scary for you, IMO. About TG: I attended Mark Ramm's presentation on TG2 in PyOhio. I'm happy that they have taken to Pylons and WSGI in a big way. But, personally, I'd wait for TG2 release before dipping my toes into it again. These days, Erlang and Project Euler are keeping me engaged: http://github.com/btbytes/btbytes.erlang/tree/master http://btbytes.googlecode.com/svn/trunk/euler/python/ +PG From pradeep at btbytes.com Wed Sep 10 03:36:53 2008 From: pradeep at btbytes.com (Pradeep Gowda) Date: Tue, 9 Sep 2008 21:36:53 -0400 Subject: [BangPypers] The web framework for ponies with magical powers Message-ID: <1F5A85F4-A893-4210-B564-F4F62D30E999@btbytes.com> http://avalonstar.com/blog/2008/sep/9/web-framework-ponies/ and http://www.flickr.com/photos/avalonstar/2844663076/ From gates.plusplus at gmail.com Wed Sep 10 09:26:30 2008 From: gates.plusplus at gmail.com (Rohan Sharma) Date: Wed, 10 Sep 2008 12:56:30 +0530 Subject: [BangPypers] The web framework for ponies with magical powers In-Reply-To: <1F5A85F4-A893-4210-B564-F4F62D30E999@btbytes.com> References: <1F5A85F4-A893-4210-B564-F4F62D30E999@btbytes.com> Message-ID: <7dd811cb0809100026o23681f4evabf94a4c4cdc067d@mail.gmail.com> Needs more jazz. On Wed, Sep 10, 2008 at 7:06 AM, Pradeep Gowda wrote: > http://avalonstar.com/blog/2008/sep/9/web-framework-ponies/ > and > http://www.flickr.com/photos/avalonstar/2844663076/ > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > From tanjavuru at yahoo.com Wed Sep 10 09:34:50 2008 From: tanjavuru at yahoo.com (S Rangaswamy) Date: Wed, 10 Sep 2008 00:34:50 -0700 (PDT) Subject: [BangPypers] which framework is better pylon or django In-Reply-To: <41139fcb0809082107lc776e62k391580e8daa412ac@mail.gmail.com> Message-ID: <140862.47322.qm@web54603.mail.re2.yahoo.com> it is interesting to note that Zope or Plone or no longer choices being mentioned ! I have not followed Django closely. Is there support available for content management or workflow ? Our team at ZeOmega has been using zope plone to build workflow and BPM products for healthcare and would be curious to know more about other python web frameworks and support for standards such as wfmc. regards sathya --- On Mon, 9/8/08, Anand Chitipothu wrote: From: Anand Chitipothu Subject: Re: [BangPypers] which framework is better pylon or django To: "Bangalore Python Users Group - India" Date: Monday, September 8, 2008, 11:07 PM On Tue, Sep 9, 2008 at 9:17 AM, Sibtey Mehdi wrote: > Hi > > I am planning to develop a website but I don't have any idea about the > python framework. I found 2 or 3 framework (pylon, Django, turbo Gear) on > net but couldn't understand which one should be used. > > Can you suggest me which framework should be better to develop a simple > website? Try web.py. http://webpy.org _______________________________________________ BangPypers mailing list BangPypers at python.org http://mail.python.org/mailman/listinfo/bangpypers -------------- next part -------------- An HTML attachment was scrubbed... URL: From sridhar.ratna at gmail.com Wed Sep 10 10:10:39 2008 From: sridhar.ratna at gmail.com (Sridhar Ratnakumar) Date: Wed, 10 Sep 2008 01:10:39 -0700 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: <004a01c9122e$be064f90$5fc513ac@pwit.com> References: <004a01c9122e$be064f90$5fc513ac@pwit.com> Message-ID: <7c73a13a0809100110u63093377yd56018d8480e17de@mail.gmail.com> On Mon, Sep 8, 2008 at 8:47 PM, Sibtey Mehdi wrote: > Hi > > I am planning to develop a website but I don't have any idea about the > python framework. I found 2 or 3 framework (pylon, Django, turbo Gear) on > net but couldn't understand which one should be used. http://code.google.com/appengine/ .. which is basically Django, but you also get free hosting with it. Appengine is good for getting started; later you can choose any framework. You may also find this interesting - http://pythonpaste.org/do-it-yourself-framework.html (Personally I am frustrated by the web development model. We need something like GWT (is pyjamas being maintained??).. or Live Volta) From rajeev.sebastian at gmail.com Wed Sep 10 14:29:31 2008 From: rajeev.sebastian at gmail.com (Rajeev J Sebastian) Date: Wed, 10 Sep 2008 17:59:31 +0530 Subject: [BangPypers] which framework is better pylon or django In-Reply-To: <140862.47322.qm@web54603.mail.re2.yahoo.com> References: <41139fcb0809082107lc776e62k391580e8daa412ac@mail.gmail.com> <140862.47322.qm@web54603.mail.re2.yahoo.com> Message-ID: <79a035420809100529g64ea3b36p2d6506a8646703ba@mail.gmail.com> On Wed, Sep 10, 2008 at 1:04 PM, S Rangaswamy wrote: > it is interesting to note that Zope or Plone or no longer choices being > mentioned ! > I have not followed Django closely. Is there support available for content > management or workflow ? > Our team at ZeOmega has been using zope plone to build workflow and BPM > products for healthcare and would be curious to know more about other python > web frameworks and support for standards such as wfmc. There is *one* workflow engine I know about for Django ... though I doubt it supports wfmc. Regards Rajeev J Sebastian From uzmanajmal at gmail.com Thu Sep 11 09:08:37 2008 From: uzmanajmal at gmail.com (Usman Ajmal) Date: Thu, 11 Sep 2008 07:08:37 +0000 Subject: [BangPypers] XML RPC Problem.... Message-ID: Hi everyone, I am trying to call a function named system.auth at the server side running at localhost:8080 but at the same time i want to set the http header. I found that header can be set by h.putheader("AUTHORIZATION", "Basic %s"%encodestring("%s:%s" % (ustring,text_ucert))) #ustring: just a random string #text_ucert: a file containing the X509 certificate of client And i also fount that a typical system.auth call will look like: POST /xmlrpc/clarens_server.py HTTP/1.0 Host: localhost User-Agent: xmlrpclib.py/0.9.9 (by www.pythonware.com) Content-Type: text/xml Content-Length: 105 AUTHORIZATION: Basic MkhVTm9VazYxbXArVEZLS0dCY2tIRlA3bjVzPQo6RnJvbSBi system.auth Problem is that i don't know how do i generate above xml system.auth call. Can anyone please tell me how do call a function, setting the header of the call too? -------------- next part -------------- An HTML attachment was scrubbed... URL: From uzmanajmal at gmail.com Thu Sep 11 10:32:39 2008 From: uzmanajmal at gmail.com (Usman Ajmal) Date: Thu, 11 Sep 2008 08:32:39 +0000 Subject: [BangPypers] XML RPC Problem.... In-Reply-To: References: Message-ID: Thanks for ur help. But now i am getting an error xmlrpclib.ProtocolError: Here is my code at http://privatepaste.com/d81Kut9AFj Any idea what wrong am i doing? On Thu, Sep 11, 2008 at 7:18 AM, Fredrik Lundh wrote: > Usman Ajmal wrote: > > And i also fount that a typical system.auth call will look like: >> >> POST /xmlrpc/clarens_server.py HTTP/1.0 >> Host: localhost >> User-Agent: xmlrpclib.py/0.9.9 (by www.pythonware.com < >> http://www.pythonware.com>) >> >> Content-Type: text/xml >> Content-Length: 105 >> AUTHORIZATION: Basic MkhVTm9VazYxbXArVEZLS0dCY2tIRlA3bjVzPQo6RnJvbSBi >> >> >> system.auth >> >> >> >> >> >> >> Problem is that i don't know how do i generate above xml system.auth call. >> Can anyone please tell me how do call a function, setting the header of the >> call too? >> > > you need to plugin a custom transport. see this page for an example: > > http://www.python.org/doc/lib/xmlrpc-client-example.html > > in your case, it should be sufficient to override send_request, e.g. > (untested): > > class SecureTransport(xmlrpclib.Transport): > > def set_authorization(self, ustring, text_ucert): > self.authoriation = encodestring( > "%s:%s" % (ustring,text_ucert) > ) > > def send_request(self, connection, handler, request_body): > connection.putrequest("POST", handler) > connection.putheader("Authorization", > "Basic %s" % self.authorization > ) > > and instantiate the transport by doing > > t = SecureTransport() > t.set_authorization(ustring, text_ucert) > > before passing to the server proxy. > > > > -- > http://mail.python.org/mailman/listinfo/python-list > -------------- next part -------------- An HTML attachment was scrubbed... URL: From dpatel_07 at rediffmail.com Fri Sep 12 00:59:32 2008 From: dpatel_07 at rediffmail.com (Deepak Patel) Date: 11 Sep 2008 22:59:32 -0000 Subject: [BangPypers] Re :Re: Re :Use of module (Include file) in Python??? Message-ID: <1220732923.S.4625.22740.f4mail-234-243.rediffmail.com.old.1221173972.31226@webmail.rediffmail.com> Thanks a lot guys, I have not yet tried it, got involved in something else, but will try it shortly.It looks like this "IMPORT" will be replacing the "#include" kind of behaviour in Python.Thanks,Deepak.On Sun, 7 Sep 2008 01:58:15 +0530 Bangalore Python Users Group - India wroteOn Sun, Sep 7, 2008 at 1:16 AM, Abhinav Sarkar wrote:>> from modulename import methodname>> or to import all methods at once do:>> from modulename import *Of course ... the first way is better form than the second for variousreasons ... so you might want to make that a habit if you're startingon a career in python.RegardsRajeev J Sebastian_______________________________________________BangPypers mailing listBangPypers at python.orghttp://mail.python.org/mailman/listinfo/bangpypers -------------- next part -------------- An HTML attachment was scrubbed... URL: From uzmanajmal at gmail.com Fri Sep 12 20:39:00 2008 From: uzmanajmal at gmail.com (Usman Ajmal) Date: Fri, 12 Sep 2008 23:39:00 +0500 Subject: [BangPypers] Need help with the 'transport' for setting the header while calling a function at server side Message-ID: I am getting an Internal Server Error 500 when i run my client code. I am trying to call a function at the server side which for now only returns a string. Meanwhile this calling i also set the header of HTTP request. Following are my client and server code. Am i doing something wrong? #-----------------------Server code----------------------------- import SimpleXMLRPCServer class AuthenticationFunctions: def system_auth(self): # No need to print here if you are going to print it at the client side. Return it instead. return "something..." server = SimpleXMLRPCServer.SimpleXMLRPCServer(("localhost", 8000)) server.register_instance(AuthenticationFunctions()) server.serve_forever() #-----------------------Client code----------------------------- import sha,random, os, time, sha, quopri, xmlrpclib class SecureTransport(xmlrpclib.Transport): def set_authorization(self, ustring, text_ucert): self.authorization = quopri.encodestring("%s:%s" % (ustring,text_ucert)) def send_request(self, connection, handler, request_body): connection.putrequest("POST", handler) connection.putheader("Authorization","Basic %s" % self.authorization) def caller(): #Opening file named newcert.pem in which certificate generated via openssl command is placed infile = open('newcert.pem', "r+") if infile: text_ucert = infile.read() infile.close() #Generating a random string random.seed(); ustring_raw="%s_%f_%f"%(os.getpid(),time.time(),random.random()) #For calculating the hash of some arbitrary message hashValue = sha.new() hashValue.update("(.2).ch^kjdw*()!hjsu7 at hsue @!jssljdu2837.kd'lsid4vhwoi3821@#1azzZ3234202J83&") #Updating the hash with the previously generated random string hashValue.update(ustring_raw) ustring = quopri.encodestring(hashValue.digest()) #Instantiating the transport t = SecureTransport() t.set_authorization(ustring, text_ucert) server = xmlrpclib.Server('http://localhost:8000',transport=t) #Calling some arbitrary function at server side print server.system_auth() caller() -------------- next part -------------- An HTML attachment was scrubbed... URL: From uzmanajmal at gmail.com Sat Sep 13 09:32:38 2008 From: uzmanajmal at gmail.com (Usman Ajmal) Date: Sat, 13 Sep 2008 07:32:38 +0000 Subject: [BangPypers] XML RPC Problem.... In-Reply-To: References: Message-ID: Please explain the arguments of send_request. What exactly are the connection, handler and request_body? It will be really helpful if you give an example of how do i call send_request On Thu, Sep 11, 2008 at 7:18 AM, Fredrik Lundh wrote: > Usman Ajmal wrote: > > And i also fount that a typical system.auth call will look like: >> >> POST /xmlrpc/clarens_server.py HTTP/1.0 >> Host: localhost >> User-Agent: xmlrpclib.py/0.9.9 (by www.pythonware.com < >> http://www.pythonware.com>) >> >> Content-Type: text/xml >> Content-Length: 105 >> AUTHORIZATION: Basic MkhVTm9VazYxbXArVEZLS0dCY2tIRlA3bjVzPQo6RnJvbSBi >> >> >> system.auth >> >> >> >> >> >> >> Problem is that i don't know how do i generate above xml system.auth call. >> Can anyone please tell me how do call a function, setting the header of the >> call too? >> > > you need to plugin a custom transport. see this page for an example: > > http://www.python.org/doc/lib/xmlrpc-client-example.html > > in your case, it should be sufficient to override send_request, e.g. > (untested): > > class SecureTransport(xmlrpclib.Transport): > > def set_authorization(self, ustring, text_ucert): > self.authoriation = encodestring( > "%s:%s" % (ustring,text_ucert) > ) > > def send_request(self, connection, handler, request_body): > connection.putrequest("POST", handler) > connection.putheader("Authorization", > "Basic %s" % self.authorization > ) > > and instantiate the transport by doing > > t = SecureTransport() > t.set_authorization(ustring, text_ucert) > > before passing to the server proxy. > > > > -- > http://mail.python.org/mailman/listinfo/python-list > -------------- next part -------------- An HTML attachment was scrubbed... URL: From uzmanajmal at gmail.com Sat Sep 13 12:06:11 2008 From: uzmanajmal at gmail.com (Usman Ajmal) Date: Sat, 13 Sep 2008 10:06:11 +0000 Subject: [BangPypers] XML RPC Problem.... In-Reply-To: References: Message-ID: Where exactly should i call ServerProxy? Following is the code from my client.py t = SecureTransport() t.set_authorization(ustring, text_ucert) server = xmlrpclib.Server('http://localhost:8000/',transport=t) print server.s() Note: Full code for client is here at http://privatepaste.com/b56oS1Xa7P and following is my server code import SimpleXMLRPCServer #server = ServerProxy("http://betty.userland.com") class AuthenticationFunctions: def s(self): print "something..." server = SimpleXMLRPCServer.SimpleXMLRPCServer(("localhost", 8000)) server.register_instance(AuthenticationFunctions()) server.serve_forever() On Sat, Sep 13, 2008 at 8:44 AM, Fredrik Lundh wrote: > Usman Ajmal wrote: > > Please explain the arguments of send_request. What exactly are the >> connection, handler and request_body? It will be really helpful if you give >> an example of how do i call send_request >> > > you don't call send_request. you should pass the SecureTransport instance > as an argument to the ServerProxy, which will then use it to talk to the > server. see the "custom transport" example in the library reference that I > pointed you to. > > http://www.python.org/doc/lib/xmlrpc-client-example.html > > > > -- > http://mail.python.org/mailman/listinfo/python-list > -------------- next part -------------- An HTML attachment was scrubbed... URL: From uzmanajmal at gmail.com Sat Sep 13 14:23:46 2008 From: uzmanajmal at gmail.com (Usman Ajmal) Date: Sat, 13 Sep 2008 17:23:46 +0500 Subject: [BangPypers] XML RPC Problem.... In-Reply-To: References: Message-ID: Problem is that when i start client (while the server is already running), i get an error i.e. Error 500 Internal Server Error On Sat, Sep 13, 2008 at 3:58 PM, Fredrik Lundh wrote: > Usman Ajmal wrote: > > Where exactly should i call ServerProxy? Following is the code from my >> client.py >> > > ServerProxy is the preferred name. Server is an old alias for the same > class. > > t = SecureTransport() >> t.set_authorization(ustring, text_ucert) >> server = xmlrpclib.Server('http://localhost:8000/',transport=t) >> print server.s() >> > > that code looks correct. so what's the problem? > > > > > -- > http://mail.python.org/mailman/listinfo/python-list > -------------- next part -------------- An HTML attachment was scrubbed... URL: From uzmanajmal at gmail.com Sat Sep 13 14:58:09 2008 From: uzmanajmal at gmail.com (Usman Ajmal) Date: Sat, 13 Sep 2008 12:58:09 +0000 Subject: [BangPypers] XML RPC Problem.... In-Reply-To: References: Message-ID: Yeah right but i don't see something wrong in my server's code. Following is my server's simple code import SimpleXMLRPCServer #server = ServerProxy("http://betty.userland.com") class AuthenticationFunctions: def s(self): print "something..." server = SimpleXMLRPCServer.SimpleXMLRPCServer(("localhost", 8000)) server.register_instance(AuthenticationFunctions()) server.serve_forever() and following is what i get when i run my client. Traceback (most recent call last): File "ppkey.py", line 48, in caller() File "ppkey.py", line 45, in caller print server.s() File "/usr/lib/python2.5/xmlrpclib.py", line 1147, in __call__ return self.__send(self.__name, args) File "/usr/lib/python2.5/xmlrpclib.py", line 1437, in __request verbose=self.__verbose File "/usr/lib/python2.5/xmlrpclib.py", line 1191, in request headers xmlrpclib.ProtocolError: On Sat, Sep 13, 2008 at 12:37 PM, Fredrik Lundh wrote: > Usman Ajmal wrote: > > Problem is that when i start client (while the server is already running), >> i get an error i.e. >> Error 500 Internal Server Error >> > > that's a server error, not a client error. check the server logs (e.g. > error.log or similar). > > > > > -- > http://mail.python.org/mailman/listinfo/python-list > -------------- next part -------------- An HTML attachment was scrubbed... URL: From uzmanajmal at gmail.com Mon Sep 15 08:23:27 2008 From: uzmanajmal at gmail.com (Usman Ajmal) Date: Mon, 15 Sep 2008 06:23:27 +0000 Subject: [BangPypers] How to convert M2Crypto.RSA.RSA to string Message-ID: Hi, I have a M2Crypto.RSA.RSA instance that contain my public-key. I want that key as string. Is there any way to convert the said instance into string? Thanks in advance. -------------- next part -------------- An HTML attachment was scrubbed... URL: From resume.post.tc at gmail.com Mon Sep 15 20:09:11 2008 From: resume.post.tc at gmail.com (Gyani) Date: Mon, 15 Sep 2008 23:39:11 +0530 Subject: [BangPypers] Python developers? Message-ID: <48CEA4C7.9030305@gmail.com> Hi all, I am new to python. We are seeking to build a small team with the expertise on Python / Pylons. The team would need 2 developers, one with 1 year experience and 1 senior developer. We are also in need of a partime tech consultant who can trouble shoot problems if any. We are trying to enhance a existing system given to us. Are there any organizations with whom I can connect who can help / guide / advice? Regards, Gyani From srinivasaenergy at gmail.com Tue Sep 16 04:25:17 2008 From: srinivasaenergy at gmail.com (srinivasa rao) Date: Tue, 16 Sep 2008 07:55:17 +0530 Subject: [BangPypers] Python developers? In-Reply-To: <48CEA4C7.9030305@gmail.com> References: <48CEA4C7.9030305@gmail.com> Message-ID: Hi pydev I am good in python may i apply for this job with 1 year exp and i do assist for the project ,if you interested please contact me . bye srinivasa 9490682315 On Mon, Sep 15, 2008 at 11:39 PM, Gyani wrote: > Hi all, > > I am new to python. We are seeking to build a small team with the expertise > on Python / Pylons. > > The team would need 2 developers, one with 1 year experience and 1 senior > developer. We are also in need of a partime tech consultant who can trouble > shoot problems if any. We are trying to enhance a existing system given to > us. > > Are there any organizations with whom I can connect who can help / guide / > advice? > > Regards, > Gyani > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > -------------- next part -------------- An HTML attachment was scrubbed... URL: From srini at nanolets.in Tue Sep 16 04:35:32 2008 From: srini at nanolets.in (Nanolets nanolets) Date: Tue, 16 Sep 2008 08:05:32 +0530 Subject: [BangPypers] Python developers? In-Reply-To: <48CEA4C7.9030305@gmail.com> References: <48CEA4C7.9030305@gmail.com> Message-ID: We are a Python human resource organization. You can contact us. Regards Srini. On Mon, Sep 15, 2008 at 11:39 PM, Gyani wrote: > Hi all, > > I am new to python. We are seeking to build a small team with the expertise > on Python / Pylons. > > The team would need 2 developers, one with 1 year experience and 1 senior > developer. We are also in need of a partime tech consultant who can trouble > shoot problems if any. We are trying toh enhance a existing system given to > us. > > Are there any organizations with whom I can connect who can help / guide / > advice? > > Regards, > Gyani > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > -------------- next part -------------- An HTML attachment was scrubbed... URL: From skpatel20 at hotmail.com Tue Sep 16 08:12:21 2008 From: skpatel20 at hotmail.com (Sanjaya Kumar Patel) Date: Tue, 16 Sep 2008 11:42:21 +0530 Subject: [BangPypers] Python developers? In-Reply-To: <48CEA4C7.9030305@gmail.com> References: <48CEA4C7.9030305@gmail.com> Message-ID: > senior developer. We are also in need of a partime tech consultant who > can trouble shoot problems if any. We are trying to enhance a existing > system given to us. > > Are there any organizations with whom I can connect who can help / guide > / advice? We are dedicated to developing web applications on Python since June 2006, mostly on TurboGears and SQLAlchemy. An example of our work is http://www.gcollab.com. Our website is http://www.radsolutions.co.in/. Do let me know if we can be of any help. regards, Sanjay sanjay at radsolutions co in _________________________________________________________________ Search for videos of Bollywood, Hollywood, Mollywood and every other wood, only on Live.com http://www.live.com/?scope=video&form=MICOAL -------------- next part -------------- An HTML attachment was scrubbed... URL: From nishith_n at yahoo.com Tue Sep 16 13:08:47 2008 From: nishith_n at yahoo.com (Nishith Nand) Date: Tue, 16 Sep 2008 04:08:47 -0700 (PDT) Subject: [BangPypers] Handling pcap files with python Message-ID: <605176.37022.qm@web39704.mail.mud.yahoo.com> Hi,I am trying to extract an uploaded file from a pcap file. The uploaded file is split across multiple frames. What I want to do is to extract the TCP payload from these frames and join them together to form the original file. I looked around the python-libpcap module but didn't find anything interesting. ?Any suggestions. Thanks and Regards,Nishith ----------------------------------------------------------------------- The problem with the world is stupidity. Not saying there should be a capital punishment for stupidity, but why don't we just take the safety labels off of everything and let the problem solve itself? -------------- next part -------------- An HTML attachment was scrubbed... URL: From abpillai at gmail.com Tue Sep 16 17:23:26 2008 From: abpillai at gmail.com (Anand Balachandran Pillai) Date: Tue, 16 Sep 2008 17:23:26 +0200 Subject: [BangPypers] Handling pcap files with python In-Reply-To: <605176.37022.qm@web39704.mail.mud.yahoo.com> References: <605176.37022.qm@web39704.mail.mud.yahoo.com> Message-ID: <8548c5f30809160823v30eefb97l197e799f16da31d4@mail.gmail.com> Does http://code.google.com/p/pypcap/ help you ? --Anand On Tue, Sep 16, 2008 at 1:08 PM, Nishith Nand wrote: > Hi, > > I am trying to extract an uploaded file from a pcap file. The uploaded file > is split across multiple frames. What I want to do is to extract the TCP > payload from these frames and join them together to form the original file. > I looked around the python-libpcap module but didn't find anything > interesting. Any suggestions. > > Thanks and Regards, > > Nishith > > ----------------------------------------------------------------------- > The problem with the world is stupidity. Not saying there should be a > capital punishment for stupidity, but why don't we just take the > safety labels off of everything and let the problem solve itself? > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- -Anand From gnuyoga at gmail.com Wed Sep 17 06:03:46 2008 From: gnuyoga at gmail.com (=?UTF-8?Q?(=E0=A4=B6=E0=A5=8D=E0=A4=B0=E0=A5=80)_Sreekanth_B_(Open_So?= =?UTF-8?Q?urce_Consultant_&_Trainer_)?=) Date: Wed, 17 Sep 2008 09:33:46 +0530 Subject: [BangPypers] linux / scripting fundamentals Message-ID: hi folks, hope all are doing good ! Am planning for series of weekend training program in the space of linux/python/java/etc .... mainly focused on open source technologies. if any one in the group is interested please drop in a mail (you are free to recommend this to your friends / colleagues as well :-) ) First of the training series is on Linux Fundamentals / Scripting fundamentals. details: http://sites.google.com/a/slashgnu.co.in/weekend-training/ thanks in advance - sree (dont get confused with other sree at mahiti.org) -- http://picasaweb.google.com/gnuyoga Each soul is potentially divine. The goal is to manifest the divine by controlling nature, internal or external. Do this by work or worship or psychic control or philosophy by one or more, or all of these and be free. -------------- next part -------------- An HTML attachment was scrubbed... URL: From anandology at gmail.com Wed Sep 17 06:18:35 2008 From: anandology at gmail.com (Anand Chitipothu) Date: Wed, 17 Sep 2008 09:48:35 +0530 Subject: [BangPypers] linux / scripting fundamentals In-Reply-To: References: Message-ID: <41139fcb0809162118q1f6691a5vf5055d3fa7590ff3@mail.gmail.com> > Am planning for series of weekend training program in the space of > linux/python/java/etc .... mainly focused on open source technologies. > > details: http://sites.google.com/a/slashgnu.co.in/weekend-training/ It is free? I couldn't find any fee details in the above link. From gnuyoga at gmail.com Wed Sep 17 06:32:09 2008 From: gnuyoga at gmail.com (=?UTF-8?Q?(=E0=A4=B6=E0=A5=8D=E0=A4=B0=E0=A5=80)_Sreekanth_B_(Open_So?= =?UTF-8?Q?urce_Consultant_&_Trainer_)?=) Date: Wed, 17 Sep 2008 10:02:09 +0530 Subject: [BangPypers] linux / scripting fundamentals In-Reply-To: <41139fcb0809162118q1f6691a5vf5055d3fa7590ff3@mail.gmail.com> References: <41139fcb0809162118q1f6691a5vf5055d3fa7590ff3@mail.gmail.com> Message-ID: On Wed, Sep 17, 2008 at 9:48 AM, Anand Chitipothu wrote: > > Am planning for series of weekend training program in the space of > > linux/python/java/etc .... mainly focused on open source technologies. > > > > details: http://sites.google.com/a/slashgnu.co.in/weekend-training/ > > It is free? I couldn't find any fee details in the above link. > no its not free. rate details updated in site. - sree -- http://picasaweb.google.com/gnuyoga Each soul is potentially divine. The goal is to manifest the divine by controlling nature, internal or external. Do this by work or worship or psychic control or philosophy by one or more, or all of these and be free. -------------- next part -------------- An HTML attachment was scrubbed... URL: From uzmanajmal at gmail.com Wed Sep 17 11:05:41 2008 From: uzmanajmal at gmail.com (Usman Ajmal) Date: Wed, 17 Sep 2008 09:05:41 +0000 Subject: [BangPypers] How to convert M2Crypto.RSA.RSA to string In-Reply-To: <3f0d61c40809150606w2b8035b3v2eba46e44cdee9a7@mail.gmail.com> References: <3f0d61c40809150606w2b8035b3v2eba46e44cdee9a7@mail.gmail.com> Message-ID: Actually my problem is a little different. I have a .pem format file which contain my public and private key both and i want to get only the public key from that file as a string. I already have done that by just parsing the said file but if there is some direct way i will b glad to know. @marco i don't have the string at all. Infact i want the string @Toivonen i tried as_pem but it gives me some private key after doing some thing with the file i pass to it as argument which is even not the private key i have in my file. Also if i set cipher=None, even then its result is same Thanks by the way marco and Toivonen for trying to help :) On Mon, Sep 15, 2008 at 1:06 PM, Marco Bizzarri wrote: > On Mon, Sep 15, 2008 at 8:23 AM, Usman Ajmal wrote: > > Hi, > > > > I have a M2Crypto.RSA.RSA instance that contain my public-key. I want > that > > key as string. Is there any way to convert the said instance into string? > > > In case you want to write the pub-key to a file, you can use save_pub_key > > def save_pub_key(self, file): > """ > Save the public key to a file in PEM format. > > @type file: string > @param file: Name of file to save key to. > """ > > Regards > Marco > -- > Marco Bizzarri > http://notenotturne.blogspot.com/ > http://iliveinpisa.blogspot.com/ > -------------- next part -------------- An HTML attachment was scrubbed... URL: From abpillai at gmail.com Thu Sep 18 08:49:19 2008 From: abpillai at gmail.com (Anand Balachandran Pillai) Date: Thu, 18 Sep 2008 08:49:19 +0200 Subject: [BangPypers] linux / scripting fundamentals In-Reply-To: References: <41139fcb0809162118q1f6691a5vf5055d3fa7590ff3@mail.gmail.com> Message-ID: <8548c5f30809172349wbe3ecal29a247845358b1d3@mail.gmail.com> Please prefix these kind of postings with "[Training]". Thanks On Wed, Sep 17, 2008 at 6:32 AM, (????) Sreekanth B (Open Source Consultant & Trainer ) wrote: > > > On Wed, Sep 17, 2008 at 9:48 AM, Anand Chitipothu > wrote: >> >> > Am planning for series of weekend training program in the space of >> > linux/python/java/etc .... mainly focused on open source technologies. >> > >> > details: http://sites.google.com/a/slashgnu.co.in/weekend-training/ >> >> It is free? I couldn't find any fee details in the above link. > > no its not free. rate details updated in site. > > - sree > -- > http://picasaweb.google.com/gnuyoga > > Each soul is potentially divine. The goal is to manifest the divine by > controlling nature, internal or external. Do this by work or worship or > psychic control or philosophy by one or more, or all of these and be free. > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- -Anand From lawgon at au-kbc.org Thu Sep 18 08:57:33 2008 From: lawgon at au-kbc.org (Kenneth Gonsalves) Date: Thu, 18 Sep 2008 12:27:33 +0530 Subject: [BangPypers] guido praises django Message-ID: <200809181227.33477.lawgon@au-kbc.org> http://gjiro.wordpress.com/2008/09/16/bdfl-confirms-django-as-cool-as-it-appears/ -- regards Kenneth Gonsalves Associate, NRC-FOSS http://nrcfosshelpline.in/web/ From heshan.suri at gmail.com Thu Sep 18 20:07:27 2008 From: heshan.suri at gmail.com (Heshan Suriyaarachchi) Date: Thu, 18 Sep 2008 13:07:27 -0500 Subject: [BangPypers] Deploying a Python Service on Axis2 Message-ID: <12e5d0d90809181107v7be3aa54x1990ca17b5ebbc12@mail.gmail.com> Hi guys, Apache Axis2/Java, is a popular open source Web service engine. It currently supports exposing services written in Java, Javascript and Ruby as Web services. This article [1]** discusses the Python data Binding that enable exposing Web services written in Python. [1] - http://wso2.org/library/articles/deploying-python-service-axis2 [2] - http://heshans.blogspot.com/2008/09/wso2-wsfjython-10-alpha.html -- Regards, Heshan Suriyaarachchi http://heshans.blogspot.com/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From mahaboobcrc at gmail.com Fri Sep 19 13:01:36 2008 From: mahaboobcrc at gmail.com (Mahaboob subhan) Date: Fri, 19 Sep 2008 16:31:36 +0530 Subject: [BangPypers] creating exe file Message-ID: <3db08df80809190401h2b2a2b46v496ff12661ce758c@mail.gmail.com> how to covert python script files as ".exe" files in linux Regards, Subhan. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ataulla at gmail.com Fri Sep 19 13:06:41 2008 From: ataulla at gmail.com (Ataulla S H) Date: Fri, 19 Sep 2008 16:36:41 +0530 Subject: [BangPypers] creating exe file In-Reply-To: <3db08df80809190401h2b2a2b46v496ff12661ce758c@mail.gmail.com> References: <3db08df80809190401h2b2a2b46v496ff12661ce758c@mail.gmail.com> Message-ID: hi Subhan, install py2exe Its very easy to convert On Fri, Sep 19, 2008 at 4:31 PM, Mahaboob subhan wrote: > how to covert python script files as ".exe" files in linux > > Regards, > Subhan. > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- Ataulla SH -------------- next part -------------- An HTML attachment was scrubbed... URL: From kushaldas at gmail.com Fri Sep 19 13:17:08 2008 From: kushaldas at gmail.com (Kushal Das) Date: Fri, 19 Sep 2008 16:47:08 +0530 Subject: [BangPypers] creating exe file In-Reply-To: References: <3db08df80809190401h2b2a2b46v496ff12661ce758c@mail.gmail.com> Message-ID: <200809191647.08714.kushaldas@gmail.com> On Friday 19 September 2008 04:36:41 pm Ataulla S H wrote: > hi Subhan, > > install py2exe > Its very easy to convert In Linux!!! Kushal -- Fedora Ambassador, India http://kushaldas.in http://dgplug.org (Linux User Group of Durgapur) From patel.deepak.09 at gmail.com Sat Sep 20 01:02:28 2008 From: patel.deepak.09 at gmail.com (Deepak Patel) Date: Fri, 19 Sep 2008 16:02:28 -0700 Subject: [BangPypers] One python question (from verilog) Message-ID: Hello all, I want to a write a method in Python to poll a register for '1' or '0'. It is kind of very simple in verilog, but not sure if python provides flexibility or not. My algorithm (kind of Verilog syntax where I can access the bits without any extra processing) is as follows: poll_reg ( input bit_pos, input poll_val, reg_offset) { // In this bit_pos is the position of bit in my register read which are being polled to become poll_val. Poll_val can be either 0 or 1. matched = 0; while (matched != 1) begin read_data = read_reg(reg_offset); if (read_data[bit_pos] == poll_val) begin matched = 1; end else begin matched = 0; end end } Is there a way to do above in Python? Thanks, Deepak -------------- next part -------------- An HTML attachment was scrubbed... URL: From pradeep at btbytes.com Sat Sep 20 02:44:41 2008 From: pradeep at btbytes.com (Pradeep Gowda) Date: Fri, 19 Sep 2008 20:44:41 -0400 Subject: [BangPypers] One python question (from verilog) In-Reply-To: References: Message-ID: The syntax looks familiar, almost python like. The equivalent python code would be*: def poll_reg(bit_pos, poll_val, reg_offset): matched = 0 while matched != 1: read_data = read_reg(reg_offset) if read_data[bit_pos] === poll_val: matched = 1 else: matched = 0 return matched * Implementing read_reg is left as an exercise to the developer :p I'm not aware of any python library methods which allow one to access registers. But, the read_reg() can be implmented in C and imported into Python. Any low level operation like register access is usually delegated to . HTH, PG On Sep 19, 2008, at 7:02 PM, Deepak Patel wrote: > Hello all, > > I want to a write a method in Python to poll a register for '1' or > '0'. It is kind of very simple in verilog, but not sure if python > provides flexibility or not. > > My algorithm (kind of Verilog syntax where I can access the bits > without any extra processing) is as follows: > > poll_reg ( input bit_pos, input poll_val, reg_offset) > { > // In this bit_pos is the position of bit in my register read which > are being polled to become poll_val. Poll_val can be either 0 or 1. > > matched = 0; > while (matched != 1) > begin > read_data = read_reg(reg_offset); > if (read_data[bit_pos] == poll_val) > begin > matched = 1; > end > else > begin > matched = 0; > end > end > } > > Is there a way to do above in Python? > Thanks, > Deepak > > > > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers Pradeep Kishore Gowda http://pradeepgowda.com pradeep at btbytes.com +1-317-564-4660 (Day Phone) From anandology at gmail.com Sat Sep 20 03:47:51 2008 From: anandology at gmail.com (Anand Chitipothu) Date: Sat, 20 Sep 2008 07:17:51 +0530 Subject: [BangPypers] One python question (from verilog) In-Reply-To: References: Message-ID: <41139fcb0809191847n37e16b4ar172e21ac47327555@mail.gmail.com> On Sat, Sep 20, 2008 at 4:32 AM, Deepak Patel wrote: > Hello all, > > I want to a write a method in Python to poll a register for '1' or '0'. It > is kind of very simple in verilog, but not sure if python provides > flexibility or not. > > My algorithm (kind of Verilog syntax where I can access the bits without any > extra processing) is as follows: > > poll_reg ( input bit_pos, input poll_val, reg_offset) > { > // In this bit_pos is the position of bit in my register read which are > being polled to become poll_val. Poll_val can be either 0 or 1. > > matched = 0; > while (matched != 1) > begin > read_data = read_reg(reg_offset); > if (read_data[bit_pos] == poll_val) > begin > matched = 1; > end > else > begin > matched = 0; > end > end > } This is more C-like bit operation. You need to get a mask by right shiting 1 by bit_pos and do binary AND with the register value. def poll_reg(bit_pos, poll_val, reg_offset): mask = 1 << bit_pos while read_read(reg_offset) & mask == poll_val: continue From patel.deepak.09 at gmail.com Sat Sep 20 04:02:36 2008 From: patel.deepak.09 at gmail.com (Deepak Patel) Date: Fri, 19 Sep 2008 19:02:36 -0700 Subject: [BangPypers] One python question (from verilog) In-Reply-To: References: Message-ID: Pradeep, Thanks. I am not aware if Python provides the feature of accessing the value by its bit poition: Can we do "if read_data[bit_pos] === poll_val:" in Python? Can you please let me know little bit more about this line? Whether Read_data will be declread as list() or dict()? Thanks, Deepak On Fri, Sep 19, 2008 at 5:44 PM, Pradeep Gowda wrote: > The syntax looks familiar, almost python like. > The equivalent python code would be*: > > def poll_reg(bit_pos, poll_val, reg_offset): > matched = 0 > while matched != 1: > read_data = read_reg(reg_offset) > if read_data[bit_pos] === poll_val: > matched = 1 > else: > matched = 0 > return matched > > * Implementing read_reg is left as an exercise to the developer :p > > I'm not aware of any python library methods which allow one to access > registers. But, the read_reg() can be implmented in C and > imported into Python. > > Any low level operation like register access is usually delegated to . > > HTH, > PG > > > On Sep 19, 2008, at 7:02 PM, Deepak Patel wrote: > > Hello all, >> >> I want to a write a method in Python to poll a register for '1' or '0'. It >> is kind of very simple in verilog, but not sure if python provides >> flexibility or not. >> >> My algorithm (kind of Verilog syntax where I can access the bits without >> any extra processing) is as follows: >> >> poll_reg ( input bit_pos, input poll_val, reg_offset) >> { >> // In this bit_pos is the position of bit in my register read which are >> being polled to become poll_val. Poll_val can be either 0 or 1. >> >> matched = 0; >> while (matched != 1) >> begin >> read_data = read_reg(reg_offset); >> if (read_data[bit_pos] == poll_val) >> begin >> matched = 1; >> end >> else >> begin >> matched = 0; >> end >> end >> } >> >> Is there a way to do above in Python? >> Thanks, >> Deepak >> >> >> >> >> _______________________________________________ >> BangPypers mailing list >> BangPypers at python.org >> http://mail.python.org/mailman/listinfo/bangpypers >> > > Pradeep Kishore Gowda > http://pradeepgowda.com > pradeep at btbytes.com > +1-317-564-4660 (Day Phone) > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > -------------- next part -------------- An HTML attachment was scrubbed... URL: From patel.deepak.09 at gmail.com Sat Sep 20 04:03:52 2008 From: patel.deepak.09 at gmail.com (Deepak Patel) Date: Fri, 19 Sep 2008 19:03:52 -0700 Subject: [BangPypers] One python question (from verilog) In-Reply-To: <41139fcb0809191847n37e16b4ar172e21ac47327555@mail.gmail.com> References: <41139fcb0809191847n37e16b4ar172e21ac47327555@mail.gmail.com> Message-ID: Anand, Thanks. I am sure that this C like operation should work, I have not yet checked it though. Deepak On Fri, Sep 19, 2008 at 6:47 PM, Anand Chitipothu wrote: > On Sat, Sep 20, 2008 at 4:32 AM, Deepak Patel > wrote: > > Hello all, > > > > I want to a write a method in Python to poll a register for '1' or '0'. > It > > is kind of very simple in verilog, but not sure if python provides > > flexibility or not. > > > > My algorithm (kind of Verilog syntax where I can access the bits without > any > > extra processing) is as follows: > > > > poll_reg ( input bit_pos, input poll_val, reg_offset) > > { > > // In this bit_pos is the position of bit in my register read which are > > being polled to become poll_val. Poll_val can be either 0 or 1. > > > > matched = 0; > > while (matched != 1) > > begin > > read_data = read_reg(reg_offset); > > if (read_data[bit_pos] == poll_val) > > begin > > matched = 1; > > end > > else > > begin > > matched = 0; > > end > > end > > } > > This is more C-like bit operation. You need to get a mask by right > shiting 1 by bit_pos and do binary AND with the register value. > > def poll_reg(bit_pos, poll_val, reg_offset): > mask = 1 << bit_pos > while read_read(reg_offset) & mask == poll_val: > continue > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mahaboobcrc at gmail.com Sat Sep 20 17:55:19 2008 From: mahaboobcrc at gmail.com (Mahaboob subhan) Date: Sat, 20 Sep 2008 21:25:19 +0530 Subject: [BangPypers] py2exe Message-ID: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> we can install py2exe only in windows, it's not available for Linux . meaning we can't install py2exe in Linux any other alternatives? thanks, Subhan -------------- next part -------------- An HTML attachment was scrubbed... URL: From abhinav.sarkar at gmail.com Sat Sep 20 18:14:13 2008 From: abhinav.sarkar at gmail.com (Abhinav Sarkar) Date: Sat, 20 Sep 2008 21:44:13 +0530 Subject: [BangPypers] py2exe In-Reply-To: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> References: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> Message-ID: <48D52155.201@gmail.com> Mahaboob subhan wrote: > we can install py2exe only in windows, > it's not available for Linux . > > meaning we can't install py2exe in Linux > > any other alternatives? > > > thanks, > Subhan > If you are trying to make python scripts executable in Linux, then you don't need any special software to do that. Just make the script executable by chmodding them like this: chmod +x script.py Cheers, -- Abhinav Sarkar Web: http://claimid.com/abhin4v Twitter: http://twitter.com/abhin4v --------- The world is a book, those who do not travel read only one page. From banibrata.dutta at gmail.com Sat Sep 20 18:16:55 2008 From: banibrata.dutta at gmail.com (Banibrata Dutta) Date: Sat, 20 Sep 2008 21:46:55 +0530 Subject: [BangPypers] py2exe In-Reply-To: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> References: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> Message-ID: <3de8e1f70809200916n58e79d05n5f7b0aee09afbf4b@mail.gmail.com> py2exe doesn't cross-compile (rather cross-package+stub) ... it's available only on Windows. On Sat, Sep 20, 2008 at 9:25 PM, Mahaboob subhan wrote: > we can install py2exe only in windows, > it's not available for Linux . > > meaning we can't install py2exe in Linux > > any other alternatives? > > > thanks, > Subhan > > > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- regards, Banibrata http://www.linkedin.com/in/bdutta http://octapod.wordpress.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From pradeep at btbytes.com Sat Sep 20 18:12:35 2008 From: pradeep at btbytes.com (Pradeep Gowda) Date: Sat, 20 Sep 2008 12:12:35 -0400 Subject: [BangPypers] py2exe In-Reply-To: <48D52155.201@gmail.com> References: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> <48D52155.201@gmail.com> Message-ID: On Sep 20, 2008, at 12:14 PM, Abhinav Sarkar wrote: > Mahaboob subhan wrote: >> we can install py2exe only in windows, >> it's not available for Linux . >> >> meaning we can't install py2exe in Linux >> >> any other alternatives? >> > If you are trying to make python scripts executable in Linux, then > you don't need any special software to do that. Just make the > script executable by chmodding them like this: > chmod +x script.py Also don't forget the hash-bang at the top of the file : #! /usr/bin/ env python This line tells the OS which program to use launch the script. Scripts are First Class citizens in *NIX world. So, not every program has to be an executable. Pradeep Kishore Gowda http://pradeepgowda.com From noufal at gmail.com Sat Sep 20 18:55:55 2008 From: noufal at gmail.com (Noufal Ibrahim) Date: Sat, 20 Sep 2008 22:25:55 +0530 Subject: [BangPypers] py2exe In-Reply-To: References: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> <48D52155.201@gmail.com> Message-ID: <9963e56e0809200955m2f255c19o2af8badf3fec0cb9@mail.gmail.com> On Sat, Sep 20, 2008 at 9:42 PM, Pradeep Gowda wrote: > [..] > Also don't forget the hash-bang at the top of the file : #! /usr/bin/env > python > > This line tells the OS which program to use launch the script. > > Scripts are First Class citizens in *NIX world. So, not every program has > to be an executable. > This does have some 'limitations' though. There are a lot of people who just want to run their 'applications' without dependency problems and such. Being able to 'bundle' your software along with everything it needs into one binary blob is what some people want to do. -- ~noufal -------------- next part -------------- An HTML attachment was scrubbed... URL: From srsy70 at gmail.com Sun Sep 21 05:27:35 2008 From: srsy70 at gmail.com (S.Ramaswamy) Date: Sun, 21 Sep 2008 08:57:35 +0530 Subject: [BangPypers] py2exe In-Reply-To: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> References: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> Message-ID: > we can install py2exe only in windows, > it's not available for Linux . > > meaning we can't install py2exe in Linux > > any other alternatives? > PyInstaller ( http://pyinstaller.python-hosting.com/ ) seems to be one option. Not sure if it works with ver 2.5 and up. Ramaswamy From jace at pobox.com Sun Sep 21 06:29:45 2008 From: jace at pobox.com (Kiran Jonnalagadda) Date: Sun, 21 Sep 2008 09:59:45 +0530 Subject: [BangPypers] py2exe In-Reply-To: <9963e56e0809200955m2f255c19o2af8badf3fec0cb9@mail.gmail.com> References: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> <48D52155.201@gmail.com> <9963e56e0809200955m2f255c19o2af8badf3fec0cb9@mail.gmail.com> Message-ID: <941020D3-1731-4017-A89A-6D254B5985AC@pobox.com> On 20-Sep-08, at 10:25 PM, Noufal Ibrahim wrote: > This does have some 'limitations' though. There are a lot of people > who just want to run their 'applications' without dependency > problems and such. Being able to 'bundle' your software along with > everything it needs into one binary blob is what some people want to > do. That is why Linux software is distributed as DEB or RPM packages where the OS takes care of all the dependencies during installation. From noufal at gmail.com Sun Sep 21 06:57:36 2008 From: noufal at gmail.com (Noufal Ibrahim) Date: Sun, 21 Sep 2008 10:27:36 +0530 Subject: [BangPypers] py2exe In-Reply-To: <941020D3-1731-4017-A89A-6D254B5985AC@pobox.com> References: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> <48D52155.201@gmail.com> <9963e56e0809200955m2f255c19o2af8badf3fec0cb9@mail.gmail.com> <941020D3-1731-4017-A89A-6D254B5985AC@pobox.com> Message-ID: <9963e56e0809202157u3baba042w2f4a749adb059307@mail.gmail.com> On Sun, Sep 21, 2008 at 9:59 AM, Kiran Jonnalagadda wrote: > On 20-Sep-08, at 10:25 PM, Noufal Ibrahim wrote: > > This does have some 'limitations' though. There are a lot of people who >> just want to run their 'applications' without dependency problems and such. >> Being able to 'bundle' your software along with everything it needs into one >> binary blob is what some people want to do. >> > > That is why Linux software is distributed as DEB or RPM packages where the > OS takes care of all the dependencies during installation. Yes but those are specific to Debian/Ubuntu or Redhat/Fedora. These are fine for real sysads but many people don't really know/want to know about package management systems. It would be nice to have one file which I can download and 'install' in some sense (perhaps without root privileges). Something like http://0install.net/or autopackage ( http://autopackage.org/). Similar to windows. Download, double click, click a few "nexts" and you have a working app (as opposed to, add a line to the apt.sources list, update, install cycle on Debian). -- ~noufal -------------- next part -------------- An HTML attachment was scrubbed... URL: From banibrata.dutta at gmail.com Sun Sep 21 07:31:15 2008 From: banibrata.dutta at gmail.com (Banibrata Dutta) Date: Sun, 21 Sep 2008 11:01:15 +0530 Subject: [BangPypers] py2exe In-Reply-To: <9963e56e0809202157u3baba042w2f4a749adb059307@mail.gmail.com> References: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> <48D52155.201@gmail.com> <9963e56e0809200955m2f255c19o2af8badf3fec0cb9@mail.gmail.com> <941020D3-1731-4017-A89A-6D254B5985AC@pobox.com> <9963e56e0809202157u3baba042w2f4a749adb059307@mail.gmail.com> Message-ID: <3de8e1f70809202231m5aed66e2ob8082477583c6052@mail.gmail.com> On Sun, Sep 21, 2008 at 10:27 AM, Noufal Ibrahim wrote: > On Sun, Sep 21, 2008 at 9:59 AM, Kiran Jonnalagadda wrote: > >> On 20-Sep-08, at 10:25 PM, Noufal Ibrahim wrote: >> >> This does have some 'limitations' though. There are a lot of people who >>> just want to run their 'applications' without dependency problems and such. >>> Being able to 'bundle' your software along with everything it needs into one >>> binary blob is what some people want to do. >>> >> >> That is why Linux software is distributed as DEB or RPM packages where the >> OS takes care of all the dependencies during installation. > > > Yes but those are specific to Debian/Ubuntu or Redhat/Fedora. These are > fine for real sysads but many people don't really know/want to know about > package management systems. > > It would be nice to have one file which I can download and 'install' in > some sense (perhaps without root privileges). Something like > http://0install.net/ or autopackage (http://autopackage.org/). Similar to > windows. Download, double click, click a few "nexts" and you have a working > app (as opposed to, add a line to the apt.sources list, update, install > cycle on Debian). > That's a good point. Actually, dependency fulfillment is a nightmare the moment you step outside the realm of -- 1) Do it right -- "always", i.e. install only from official distro, install packages only from official distro-stream, and always do so, without exception. 2) Internet connected (or repository connected) systems, where rule-1 is followed. Those 2 are "ideal" ways (probably) of maintaining software, but the weakest link are not the software packages (installed on the system) that adhere to those, but those that don't. -- regards, Banibrata http://www.linkedin.com/in/bdutta http://octapod.wordpress.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From jace at pobox.com Sun Sep 21 10:05:12 2008 From: jace at pobox.com (Kiran Jonnalagadda) Date: Sun, 21 Sep 2008 13:35:12 +0530 Subject: [BangPypers] py2exe In-Reply-To: <9963e56e0809202157u3baba042w2f4a749adb059307@mail.gmail.com> References: <3db08df80809200855r344ba36aj2735a4163b02a90c@mail.gmail.com> <48D52155.201@gmail.com> <9963e56e0809200955m2f255c19o2af8badf3fec0cb9@mail.gmail.com> <941020D3-1731-4017-A89A-6D254B5985AC@pobox.com> <9963e56e0809202157u3baba042w2f4a749adb059307@mail.gmail.com> Message-ID: On Sun, Sep 21, 2008 at 10:27 AM, Noufal Ibrahim wrote: > Yes but those are specific to Debian/Ubuntu or Redhat/Fedora. These are > fine for real sysads but many people don't really know/want to know about > package management systems. > As a user, I'd much rather double click a .deb file and let Ubuntu take care of the rest rather than poke around a 0install or whatever while worrying about what dependencies of mine it's going to trash. You may also want to look at bbfreeze: http://pypi.python.org/pypi/bbfreeze -- Kiran Jonnalagadda http://jace.seacrow.com/ -------------- next part -------------- An HTML attachment was scrubbed... URL: From vsapre80 at gmail.com Sun Sep 21 13:34:30 2008 From: vsapre80 at gmail.com (Vishal) Date: Sun, 21 Sep 2008 17:04:30 +0530 Subject: [BangPypers] One python question (from verilog) In-Reply-To: References: <41139fcb0809191847n37e16b4ar172e21ac47327555@mail.gmail.com> Message-ID: In our company we use Python a lot to interact with hardware directly. And as pointed out earlier, there is a C++ framework to read a register, which is available as a COM library, and then Python interacts with this library. unfortunately, its proprietary and cannot be shared. But the idea itself is open. Vishal On Sat, Sep 20, 2008 at 7:33 AM, Deepak Patel wrote: > Anand, > Thanks. I am sure that this C like operation should work, I have not yet > checked it though. > Deepak > > On Fri, Sep 19, 2008 at 6:47 PM, Anand Chitipothu wrote: > >> On Sat, Sep 20, 2008 at 4:32 AM, Deepak Patel >> wrote: >> > Hello all, >> > >> > I want to a write a method in Python to poll a register for '1' or '0'. >> It >> > is kind of very simple in verilog, but not sure if python provides >> > flexibility or not. >> > >> > My algorithm (kind of Verilog syntax where I can access the bits without >> any >> > extra processing) is as follows: >> > >> > poll_reg ( input bit_pos, input poll_val, reg_offset) >> > { >> > // In this bit_pos is the position of bit in my register read which are >> > being polled to become poll_val. Poll_val can be either 0 or 1. >> > >> > matched = 0; >> > while (matched != 1) >> > begin >> > read_data = read_reg(reg_offset); >> > if (read_data[bit_pos] == poll_val) >> > begin >> > matched = 1; >> > end >> > else >> > begin >> > matched = 0; >> > end >> > end >> > } >> >> This is more C-like bit operation. You need to get a mask by right >> shiting 1 by bit_pos and do binary AND with the register value. >> >> def poll_reg(bit_pos, poll_val, reg_offset): >> mask = 1 << bit_pos >> while read_read(reg_offset) & mask == poll_val: >> continue >> _______________________________________________ >> BangPypers mailing list >> BangPypers at python.org >> http://mail.python.org/mailman/listinfo/bangpypers >> > > > _______________________________________________ > 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 vsapre80 at gmail.com Sun Sep 21 13:36:30 2008 From: vsapre80 at gmail.com (Vishal) Date: Sun, 21 Sep 2008 17:06:30 +0530 Subject: [BangPypers] GUI framework in Python... Message-ID: 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From lawgon at au-kbc.org Sun Sep 21 16:33:19 2008 From: lawgon at au-kbc.org (Kenneth Gonsalves) Date: Sun, 21 Sep 2008 20:03:19 +0530 Subject: [BangPypers] GUI framework in Python... In-Reply-To: References: Message-ID: <200809212003.19978.lawgon@au-kbc.org> On Sunday 21 Sep 2008 5:06:30 pm Vishal wrote: > We would like to use a GUI framework with our Python code. I have always been a big fan of wxPython -- regards Kenneth Gonsalves Associate, NRC-FOSS http://nrcfosshelpline.in/web/ From banibrata.dutta at gmail.com Sun Sep 21 17:31:38 2008 From: banibrata.dutta at gmail.com (Banibrata Dutta) Date: Sun, 21 Sep 2008 21:01:38 +0530 Subject: [BangPypers] GUI framework in Python... In-Reply-To: References: Message-ID: <3de8e1f70809210831w4ba9b9bbka50ed9f7b66d7568@mail.gmail.com> Reposting an interesting thread-head, from another Python list... (orig author is Todd Whitman): I've put together a tutorial that shows off how to build a GUI application using XULRunner (same architectural components as Firefox uses) that can be used in conjunction with the Python programming language. The tutorial covers how to build a Python/XULRunner GUI application: http://pyxpcomext.mozdev.org/no_wrap/tutorials/pyxulrunner/ python_xulrunner_about.html The details in this tutorial covers the initial setup to full packaging/deployment, mostly targeting a Windows/Linux platform (MacOSX is possible with a few deviations, I have tried to cover these deviations where applicable). thanks & regards, Bani -- On Sun, Sep 21, 2008 at 5:06 PM, 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 > > -- regards, Banibrata http://www.linkedin.com/in/bdutta http://octapod.wordpress.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From vibhaven at yahoo.com Mon Sep 22 06:53:37 2008 From: vibhaven at yahoo.com (vibha srinivasan) Date: Sun, 21 Sep 2008 21:53:37 -0700 (PDT) Subject: [BangPypers] GUI framework in Python... In-Reply-To: Message-ID: <647870.43671.qm@web65705.mail.ac4.yahoo.com> I would strongly recommend the open source Traits package and its accompanying GUI toolkit packages, TraitsBackendWX (or TraitsBackendQt) developed by Enthought, Inc.? (the project home page is http://code.enthought.com/projects/traits). The packages are available on pypi at: http://pypi.python.org/pypi/Traits/3.0.2 http://pypi.python.org/pypi/TraitsBackendWX/3.0.2 http://pypi.python.org/pypi/TraitsBackendQt/3.0.2 Besides providing a GUI framework (the GUI feature is optional actually), the Traits project provides support for explicitly typed attributes for Python. Disclaimer: I am an employee of Enthought, Inc. If you do try out this package, we would really appreciate your feedback. best, Vibha --- On Sun, 9/21/08, Vishal wrote: From: Vishal Subject: [BangPypers] GUI framework in Python... To: "Bangalore Python Users Group - India" Date: Sunday, September 21, 2008, 7:36 AM 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From abpillai at gmail.com Mon Sep 22 08:43:20 2008 From: abpillai at gmail.com (Anand Balachandran Pillai) Date: Mon, 22 Sep 2008 12:13:20 +0530 Subject: [BangPypers] GUI framework in Python... In-Reply-To: <647870.43671.qm@web65705.mail.ac4.yahoo.com> References: <647870.43671.qm@web65705.mail.ac4.yahoo.com> Message-ID: <8548c5f30809212343w11c065c5vc8e939bf412c645b@mail.gmail.com> If you want a simple, lightweight GUI framework without complex event handling routines, and you rate yourself from Python newbie-rookie-intermediate, I suggest easygui. http://easygui.sourceforge.net/ Easygui uses simple functions instead of typical event-driven model of UIs. I have not used it myself but I have read good things about it from people who have. It is a good option if what you are doing is a quick n dirty internal project which will be used by you or your team. However for any "serious" application with an expected life of a year or more, I suggest the regular, event-driven frameworks. For me this would be wxPython, anygui, tkinter and PythonCard in that order. --Anand On Mon, Sep 22, 2008 at 10:23 AM, vibha srinivasan wrote: > I would strongly recommend the open source Traits package and its > accompanying GUI toolkit packages, TraitsBackendWX (or TraitsBackendQt) > developed by Enthought, Inc. (the project home page is > http://code.enthought.com/projects/traits). > > The packages are available on pypi at: > > http://pypi.python.org/pypi/Traits/3.0.2 > http://pypi.python.org/pypi/TraitsBackendWX/3.0.2 > http://pypi.python.org/pypi/TraitsBackendQt/3.0.2 > > Besides providing a GUI framework (the GUI feature is optional actually), > the Traits project provides support for explicitly typed attributes for > Python. > > Disclaimer: I am an employee of Enthought, Inc. If you do try out this > package, we would really appreciate your feedback. > > best, > Vibha > > --- On Sun, 9/21/08, Vishal wrote: > > From: Vishal > Subject: [BangPypers] GUI framework in Python... > To: "Bangalore Python Users Group - India" > Date: Sunday, September 21, 2008, 7:36 AM > > 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 > > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- -Anand From kushaldas at gmail.com Mon Sep 22 09:00:14 2008 From: kushaldas at gmail.com (Kushal Das) Date: Mon, 22 Sep 2008 12:30:14 +0530 Subject: [BangPypers] GUI framework in Python... In-Reply-To: References: Message-ID: <200809221230.14614.kushaldas@gmail.com> On Sunday 21 September 2008 05:06:30 pm 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. > My choice is PyQt4 :) Kushal -- Fedora Ambassador, India http://kushaldas.in http://dgplug.org (Linux User Group of Durgapur) From nishith_n at yahoo.com Mon Sep 22 10:46:04 2008 From: nishith_n at yahoo.com (Nishith Nand) Date: Mon, 22 Sep 2008 01:46:04 -0700 (PDT) Subject: [BangPypers] Handling pcap files with python In-Reply-To: <8548c5f30809160823v30eefb97l197e799f16da31d4@mail.gmail.com> Message-ID: <700027.33751.qm@web39706.mail.mud.yahoo.com> Its not really what I had in mind. I couldn't find any tool which would extract POST data ?from a pcap file. So, I started writing my own. You can track the progress, if you want, at https://launchpad.net/tlreaderRegards, Nishith ----------------------------------------------------------------------- The problem with the world is stupidity. Not saying there should be a capital punishment for stupidity, but why don't we just take the safety labels off of everything and let the problem solve itself? --- On Tue, 9/16/08, Anand Balachandran Pillai wrote: From: Anand Balachandran Pillai Subject: Re: [BangPypers] Handling pcap files with python To: nishith_n at yahoo.com, "Bangalore Python Users Group - India" Date: Tuesday, September 16, 2008, 8:53 PM Does http://code.google.com/p/pypcap/ help you ? --Anand On Tue, Sep 16, 2008 at 1:08 PM, Nishith Nand wrote: > Hi, > > I am trying to extract an uploaded file from a pcap file. The uploaded file > is split across multiple frames. What I want to do is to extract the TCP > payload from these frames and join them together to form the original file. > I looked around the python-libpcap module but didn't find anything > interesting. Any suggestions. > > Thanks and Regards, > > Nishith > > ----------------------------------------------------------------------- > The problem with the world is stupidity. Not saying there should be a > capital punishment for stupidity, but why don't we just take the > safety labels off of everything and let the problem solve itself? > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -- -Anand -------------- next part -------------- An HTML attachment was scrubbed... URL: From urskarthiksp at gmail.com Fri Sep 26 14:34:40 2008 From: urskarthiksp at gmail.com (SP Karthik) Date: Fri, 26 Sep 2008 08:34:40 -0400 Subject: [BangPypers] Python Training Message-ID: Hello , Is there any python professional trainer in Bangalore(India) for corporate training? Can any one send the contact details to me? Thanks. Regards, Karthik -------------- next part -------------- An HTML attachment was scrubbed... URL: From srini at nanolets.in Fri Sep 26 16:32:15 2008 From: srini at nanolets.in (Nanolets nanolets) Date: Fri, 26 Sep 2008 20:02:15 +0530 Subject: [BangPypers] Python Training In-Reply-To: References: Message-ID: i am a corporate trainer checkout www.nanolets.com Regards Srini On Fri, Sep 26, 2008 at 6:04 PM, SP Karthik wrote: > Hello , > > Is there any python professional trainer in Bangalore(India) for corporate > training? Can any one send the contact details to me? Thanks. > > Regards, > Karthik > > _______________________________________________ > BangPypers mailing list > BangPypers at python.org > http://mail.python.org/mailman/listinfo/bangpypers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From sridhar.ratna at gmail.com Mon Sep 29 19:00:05 2008 From: sridhar.ratna at gmail.com (Sridhar Ratnakumar) Date: Mon, 29 Sep 2008 10:00:05 -0700 Subject: [BangPypers] GUI framework in Python... In-Reply-To: References: Message-ID: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> http://www.awaretek.com/toolkits.html 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 vsapre80 at gmail.com Tue Sep 30 10:49:24 2008 From: vsapre80 at gmail.com (Vishal) Date: Tue, 30 Sep 2008 14:19:24 +0530 Subject: [BangPypers] GUI framework in Python... In-Reply-To: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> References: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> Message-ID: Hi, 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? How to go about building one? Thanks and best regards, Vishal On Mon, Sep 29, 2008 at 10:30 PM, Sridhar Ratnakumar < sridhar.ratna at gmail.com> wrote: > http://www.awaretek.com/toolkits.html > > 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 > > > > > _______________________________________________ > 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 vsapre80 at gmail.com Tue Sep 30 11:22:57 2008 From: vsapre80 at gmail.com (Vishal) Date: Tue, 30 Sep 2008 14:52:57 +0530 Subject: [BangPypers] GUI framework in Python... In-Reply-To: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> References: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> Message-ID: Thanks Sridhar. I had tried the link earlier as well. According to them wxpython is the best one for me. However, from my short experience I have noticed the wxpython applications (at least on Windows) take very long (3 - 7 seconds) to come up. Example is the well known Wing IDE. Not only that, they are also not very responsive and remind me of some Java Swing applications. Every time they come up...its bound to make the rest of the computer unresponsive (that might be because the Java runtime is coming up...). There is no real good option for commercial development in Python in my view right now...and i am frantically searching for one !!! Fox, FLTK are not completely safe due to the LGPL license clauses. WxPython is not very good at responsiveness, and the API is not simple enough. Qt is not free, and the free distribution is not for commerical development easygui is not good enough for applications that are going to have long lifetimes. PythonCard comes without a GUI designer. Atleast I could not find one on their website. 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. Option d also looks attractive, after working with PyScripter for sometime, but I dont know Pascal/Delphi and dont own an IDE for the same. But its available only for Windows. Ideas welcome :) Thanks and best regards, Vishal On Mon, Sep 29, 2008 at 10:30 PM, Sridhar Ratnakumar < sridhar.ratna at gmail.com> wrote: > http://www.awaretek.com/toolkits.html > > 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 > > > > > _______________________________________________ > 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 rajeev.sebastian at gmail.com Tue Sep 30 11:37:03 2008 From: rajeev.sebastian at gmail.com (Rajeev J Sebastian) Date: Tue, 30 Sep 2008 15:07:03 +0530 Subject: [BangPypers] GUI framework in Python... In-Reply-To: References: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> Message-ID: <79a035420809300237u7d7c4ba6u40b612b65507af42@mail.gmail.com> On Tue, Sep 30, 2008 at 2:52 PM, Vishal wrote: > c) Use the Embedded Websever approach and make the web browser as your GUI > host. One thing you can do ... write a wrapper around QtWebKit as your browser-gui. This should insulate your proprietary code from the GPLed Qt. Regards Rajeev J Sebastian From rajeev.sebastian at gmail.com Tue Sep 30 11:37:42 2008 From: rajeev.sebastian at gmail.com (Rajeev J Sebastian) Date: Tue, 30 Sep 2008 15:07:42 +0530 Subject: [BangPypers] GUI framework in Python... In-Reply-To: <79a035420809300237u7d7c4ba6u40b612b65507af42@mail.gmail.com> References: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> <79a035420809300237u7d7c4ba6u40b612b65507af42@mail.gmail.com> Message-ID: <79a035420809300237u7a5f9980kc5fee4647054f013@mail.gmail.com> On Tue, Sep 30, 2008 at 3:07 PM, Rajeev J Sebastian wrote: > One thing you can do ... Please read as *could* do ... From pradeep at btbytes.com Tue Sep 30 14:32:26 2008 From: pradeep at btbytes.com (Pradeep Gowda) Date: Tue, 30 Sep 2008 08:32:26 -0400 Subject: [BangPypers] GUI framework in Python... In-Reply-To: References: <7c73a13a0809291000p57015e30k33b29e29756e1a33@mail.gmail.com> Message-ID: On Sep 30, 2008, at 4:49 AM, Vishal wrote: > Hi, > 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. Won't Adobe Air provide all this and a kick ass GUI at the same? If all you want is a light weight gui that works across browsers has an embedded HTML rendering engine (webkit), you don't have to look beyond AIR. Well, of course this isn't Python, but, that should not come in between the developer and a good solution.. +PG Pradeep Kishore Gowda http://pradeepgowda.com