Re: [BangPypers] Configuring web2py to run on apache with Centos5.8

2012-07-25 Thread Kenneth Gonsalves
On Wed, 2012-07-25 at 16:10 +0530, Guruprasad wrote:
 On Wed, Jul 25, 2012 at 3:55 PM, Senthil skksun...@yahoo.co.in
 wrote:
  Hi Kenneth,
 
  Really appreciate your help. I was able to configure the web2py to
 run on apache successfully. Thanks to everyone for the support.
 
 What was the issue and how did you solve it? It'd be great if you
 could post a short writeup.
 
 

the issue was that apache was giving forbidden error when trying to
access his app and the solution was to give apache the permissions. This
is a very common issue in fedora/redhat/centos/ where the default for
most directories under / is not to give execute permission to all. This
error was further compounded by him putting his app under /root which is
usually more heavily protected than most directories. 
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Configuring web2py to run on apache with Centos5.8

2012-07-24 Thread Kenneth Gonsalves
On Tue, 2012-07-24 at 18:43 +0800, Senthil wrote:
 My app is under the directory /root/web2py/web2py. Sorry about the
 late reply.

and if you notice, that does not have 755 permissions - and it is not a
very healthy thing to put apps under /root - but it is your funeral!
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [X-POST] Introducing PRS: a web-app in Python+SQLAlchemy+Tornado for clinic patient record maintenance

2012-07-23 Thread Kenneth Gonsalves
On Mon, 2012-07-23 at 17:46 +0530, Sriram Karra wrote:
 I invite you to browse the source code
 at:https://github.com/skarra/PRSand/or give the application a spin
 here: 

am getting a 404
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [X-POST] Introducing PRS: a web-app in Python+SQLAlchemy+Tornado for clinic patient record maintenance

2012-07-23 Thread Kenneth Gonsalves
On Mon, 2012-07-23 at 17:59 +0530, Balachandran Sivakumar wrote:
  am getting a 404
 
   I guess he meant https://github.com/skarra/PRS Thanks 

figured it out - sorry for the noise.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Configuring web2py to run on apache with Centos5.8

2012-07-20 Thread Kenneth Gonsalves
On Fri, 2012-07-20 at 14:26 +0800, Senthil wrote:
 But i keep getting the 403 forbidden error. Am not sure what am doing
 wrong here .

chmod -R 755 /path_to_static/
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Configuring web2py to run on apache with Centos5.8

2012-07-20 Thread Kenneth Gonsalves
On Fri, 2012-07-20 at 17:18 +0800, Senthil wrote:
 But i have already set that. The only difference is i have given all
 permissions to all, meaning 
 
 chmod -R 777 /path_to_static/ 

there *are* easier ways to commit suicide! Disable selinux and see if it
helps.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] missing dependency while installing virtualenvwrapper on ubuntu-12.04

2012-07-20 Thread Kenneth Gonsalves
On Fri, 2012-07-20 at 15:25 +0530, kracethekingmaker wrote:
 Talk is cheap, show me the code -- Linus Torvalds

this quote taken out of context has caused enough trouble in the open
source community, please read the whole thread to understand the
context. Start here:

https://lkml.org/lkml/2000/8/26/52

-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Configuring web2py to run on apache with Centos5.8

2012-07-20 Thread Kenneth Gonsalves
On Fri, 2012-07-20 at 20:09 +0800, Senthil wrote:
 I have changed the permissions to 755 and have disabled the selinux
 already :( sad Still no luck... 

are you by any chance using firefox - I find that very often firefox
cache is the culprit - even clearing the cache does not help. Sometimes
it takes hours to work. Can you give the output of apache error logs -
maybe you have a typo somewhere.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Configuring web2py to run on apache with Centos5.8

2012-07-20 Thread Kenneth Gonsalves
On Fri, 2012-07-20 at 20:43 +0800, Senthil wrote:
 I tried it over IE, Firefox and Chrome. All had the same result.

cd to /, do ls -al and paste the output here
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [JOB] Python/Django developer for a startup

2012-07-09 Thread Kenneth Gonsalves
On Mon, 2012-07-09 at 17:14 +0530, Pradip Caulagi wrote:
 To apply, send a mail to care...@wwstay.com with your github/bitbucket
 url.  *Don't send resumes*. 

I wish more people would make this condition.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Job list

2012-07-03 Thread Kenneth Gonsalves
On Tue, 2012-07-03 at 17:01 +0530, Anand Chitipothu wrote:
  Not everyone (including me) knows about all the tags or the right
 tag for
  the purpose.
 
 I don't think there was any formal list.
 Here are the list of tags that I've seen people using:
 
 [Job]
 [Commercial]
 [OT] - Off-topic
 [X-POST] - Cross posted to multiple groups 

the last one to be used *solely* for announcements of general importance
to all the lists it is posted to. 
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python script to limit access to Internet...

2012-06-27 Thread Kenneth Gonsalves
On Wed, 2012-06-27 at 13:34 +0530, Vishal wrote:
 I would like to limit internet access at my home, for some computers.
 Basically for a given time during the day (read schedule), I wish that
 the
 a given computer should not be able to access the internet.
 However, the computer is still connected to the internal LAN, so
 file/print
 sharing should be allowed. 

what is the configuration of the LAN? are you using some proxy like
squid and a dhcp server, or are you using the router as a dhcp server?
Are you running your own firewall? 
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python script to limit access to Internet...

2012-06-27 Thread Kenneth Gonsalves
On Wed, 2012-06-27 at 14:15 +0530, Vishal wrote:
 I am using the router as the DHCP server. The firewall is windows
 firewall.

ouch
 No separate proxy server.
 
 Most solutions i looked at, pointed to being something for the entire
 network...not sure how to use them, since in my network everyone is
 connected to the router, which is then connected to the internet (just
 a
 regular home network), no central authority controlling others.

the simplest solution is to run your own dhcp/proxy/firewall server. It
is dead easy on linux and you do not need to write any scripts. Just a
cron job to handle the timing. I do not know anything about windows -
but one thing, networks where you rely on the dhcp server on the router
are highly unsafe. Please avoid them.
  
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python script to limit access to Internet...

2012-06-27 Thread Kenneth Gonsalves
On Wed, 2012-06-27 at 15:38 +0530, Noufal Ibrahim wrote:
 Kenneth Gonsalves law...@gmail.com writes:
 
 [...]
 
  but one thing, networks where you rely on the dhcp server on the
  router are highly unsafe. Please avoid them.
 
 Why so? 

in the first place, these are setup by the 'technical' staff of the
service provider. The root password is usually root123, the firewall is
identical on all modems, the permissions are the widest possible and the
client machines are usually windows. I use this, but my machines are all
linux with proper firewalls, and I can see the sort of rubbish the
router lets in in the logs.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python script to limit access to Internet...

2012-06-27 Thread Kenneth Gonsalves
On Wed, 2012-06-27 at 16:13 +0530, Baishampayan Ghose wrote:
  Why so?
 
  in the first place, these are setup by the 'technical' staff of the
  service provider. The root password is usually root123, the firewall
 is
  identical on all modems, the permissions are the widest possible and
 the
  client machines are usually windows. I use this, but my machines are
 all
  linux with proper firewalls, and I can see the sort of rubbish the
  router lets in in the logs.
 
 True, but I am not sure how this is related to running the DHCP server
 on the router. 

ok if you configure the server on the router yourself, replace the root
password and configure the firewall there also (after all most routers
run linux, so no big deal - anyway this is getting highly OT.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] ASynK - Flexible PIM synchronization across Google Contacts, Outlook, Emacs BBDB

2012-06-01 Thread Kenneth Gonsalves
On Fri, 2012-06-01 at 14:12 +0530, Anand Balachandran Pillai wrote:
  Have a look at the project page at:
 http://karra-asynk.appspot.com/ on
  where to get it, documentation etc.
 
 
 The download and other links don't seem to work for me. Btw,
 if you are sharing code please publish it in github or google code. 

or bitbucket
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


[BangPypers] workshop

2012-04-12 Thread Kenneth Gonsalves
hi,

I am conducting two python workshops for students in Trivandrum on 23rd
and 24th June. I would like to have some help in the lab on these days -
and maybe to take a few sessions also. The organisers will handle travel
and accommodation. Please contact me offlist.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [OT?] Re: Industrial Control Systems in Python

2012-04-08 Thread Kenneth Gonsalves
On Thu, 2012-04-05 at 21:24 +0530, Vishal wrote:
 If I am wrong on this line of thought i would love to be
 corrected.
 
 

you are 100% correct. If you want warranty, you have to pay for it -
many open source projects offer warranty on payment, and there are also
many third party vendors who offer warranties for specific
products/stacks.
-- 
regards
Kenneth Gonsalves


___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python for a college kid..

2012-03-30 Thread Kenneth Gonsalves

I have something available in Ooty - the only thing is my interns pay me
(and not the other way round)
On Fri, 2012-03-30 at 19:34 +0530, kracethekingmaker wrote:
 Hi
 Most important point to be noted does your brother enjoying 
 programming?
 
 He wants to code in python personally? Introduce him to other language 
 as well.
 
  Bhavyabhavya.ma...@gmail.com  writes:
 
  Hello everyone,
 
  I am looking for some information  advice on Python jobs
  internships in Bangalore. My brother will be passing out of college
  with a degree in information science  engineering this
  semester. Unfortunately, his grades are bad.
 
  I work with a start up in Montreal  we are python crazy,Though I am
  not on development side, I have been singing praises about web
  development  python to him. He is learning python right now - he is
  been on Zed Shaw's Learn python the hard way  on Udacity's course.
  Zed Shaw is a good teacher. I think he's picked a good book to work
  through.
 
  So, here is what I wanted to know - are there any entry level
  internships dealing with python  web development in Bangalore ? How
  much do academics matter to get into any of these ?
  I think there are small companies in Bangalore (and possibly other
  cities) that are open to the idea of taking smart kids as interns. They
  *might* not pay too well but I think that's okay as long as the kid
  understands that he's being paid lesser than the market rate. I'm not
  sure if this will affect his later salaries though. The larger
  companies, atleast in my experience, have become so laden with
  bureaucratic barnacle that to simply apply for an internship is a bit of
  a chore in itself.
 
  The other thing is that a lot of college students these days get exposed
  to real world software development via. free software. Along with more
  structured programs like the Google summer of code, they have a lot of
  ways other than grades to prove their mettle to prospective
  employers. This is double edged. It magnifies the differences between
  the students so smart kids get a greater advantage earlier on while
  average ones who stick to the purely academic line lose out a little.
 
  Any advice and/or help will be much appreciated.
  So, in summary, my advice would be for your brother to get involved in
  some free software work. This will give him a bit of a reputation if he
  pulls it off. Then connect with the startup and tech communities in
  Bangalore and other cities. I think something will come his way.
 
  Good luck to him!
 
  [...]
 
 
 
 


-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] JOB - Senior Web Developer - Talented Team!

2012-03-16 Thread Kenneth Gonsalves
On Fri, 2012-03-16 at 10:39 +0530, Anand Balachandran Pillai wrote:
 Ah well, that was supposed to go to the sender. My bad. Ignore it.

welcome to the club
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] JOB - Senior Web Developer - Talented Team!

2012-03-16 Thread Kenneth Gonsalves
On Fri, 2012-03-16 at 06:51 +, स्वक्ष wrote:
  Let's not change the default setting to address a corner case.
 
 Not asking for a change, just saying that blaming the mail client** is
 not a solution when it is the last point in the delivery chain.
 
 ** most linux clients are smart as is 

I use evolution which is the stupidest mail client that I have seen.
When doing a private reply, I click on 'reply privately' - it gives a
warning - 'you are replying privately to a group mail', and happily
sends the mail to the group. There is no way to reply privately other
than cutting and pasting the sender's address.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Question on GUI

2012-02-16 Thread Kenneth Gonsalves
On Fri, 2012-02-17 at 01:19 +0530, Nikunj Badjatya wrote:
 I have never worked on developing GUIs before. Need some suggestions
 on how
 to proceed with one. 

basic - tkinter, advanced - wxPython, sexy - kivy
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python private coach?

2012-02-08 Thread Kenneth Gonsalves
I do private one-to-one coaching in python and django. I am based in
Ooty and find for Indians, remote usually does not work. I normally
insist on personal presence (at least at the beginning). However I am
willing to give remote a try. I charge 25K. My code is here:
http://bitbucket.org/lawgon/

On Wed, 2012-02-08 at 01:35 -0800, quantrum75 wrote:
 Hi Bangpypers,
 I just joined this group as I am highly enthusiastic about Python. However, 
 the reason for this mail is to see if there are anyone in this group with an 
 aptitude for teaching python on a one-to-one basis? I would like to obtain 
 python coaching online for a fee. This would be the ideal situation for a 
 smart college educated pythonista to get some extra money. I am quite 
 comfortable with the syntax of python. In fact I have written fairly long 
 scripts previously. What I am looking for is a complete perspective with 
 regards to writing software professionally. I am completely self-taught so I 
 am very rough with regards to writing elegant python software. The interested 
 person would act as a coach to help me to progress to writing professional, 
 COMPLETE software. I expect this to be one hour every week online. I pick up 
 stuff fairly easily, so the main role of the person would be act as a guide 
 more than anything else. I know I could join a open source
  project etc, but what I am looking for is rigor in the learning process. I 
 also expect the person to be professional about the teaching part.
 Thank you very much for your time and I shall look forward to receiving your 
 replies (please reply to my email and not the group)
 
 Regards
 Rama
 
 PS - Anyone who is interested, I would like to go in depth your previous 
 background with python before I commit if it is ok. I am quite easy to get 
 along with, so once we are ok with each other, you should find the teaching 
 process quite interesting.
 ___
 BangPypers mailing list
 BangPypers@python.org
 http://mail.python.org/mailman/listinfo/bangpypers


-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python private coach?

2012-02-08 Thread Kenneth Gonsalves
On Wed, 2012-02-08 at 22:20 +0800, Senthil Kumaran wrote:
 On Wed, Feb 08, 2012 at 03:17:06PM +0530, Kenneth Gonsalves wrote:
  I do private one-to-one coaching in python and django. I am based in
 
 Was the group response intentional? If so, appreciate that!. :-) 

ouch
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python 3 availability

2012-01-19 Thread Kenneth Gonsalves
On Thu, 2012-01-19 at 16:06 +0530, Jins Thomas wrote:
 Would like to have some guesses on  when Python 3 will be available
 with
 standard distributions of Linux/Unix. 

depends on what you mean by standard distributions. For example
archlinux moved in 2010 to it as default. Fedora has it - but not
installed by default.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python 3 availability

2012-01-19 Thread Kenneth Gonsalves
On Thu, 2012-01-19 at 17:17 +0530, Jins Thomas wrote:
  Yes, Thanks, i meant the same, especially RHEL

debian will take some time and RHEL will take a long time.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python 3 availability

2012-01-19 Thread Kenneth Gonsalves
On Thu, 2012-01-19 at 17:29 +0530, Balachandran Sivakumar wrote:
 On Thu, Jan 19, 2012 at 5:22 PM, Kenneth Gonsalves law...@gmail.com
 wrote:
  On Thu, 2012-01-19 at 17:17 +0530, Jins Thomas wrote:
 
  debian will take some time and RHEL will take a long time.
 
You are replying without really checking  :) Debian(Squeeze)
 already has python 3. It is not the default though. Much like what you
 told for Fedora. Thanks 

my bad (/me upgrades has opinion of debian)
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python ORM

2012-01-14 Thread Kenneth Gonsalves
On Sat, 2012-01-14 at 21:40 +0530, kracekumar ramaraju wrote:
 Out all examples and discussions, every one seems to recommend
 SQLAlchemy,
 but it has deep learning curve whereas storm, peewee are light weight.
 Have
 anyone tried any of these for non-trivial project or real life big
 sites,
 in case yes please share the experience.
 
 

my (highly prejudiced) opinion:

1. I would rather write raw sql than grapple with SQLAlchemy

2. Canonical are the bad boys of the open source world, so I would not
touch any of their products with a barge pole.

3. My vote is for peewee - it is django-like, and although I have not
tried peewee in production, it looks like just the thing I need for my
forthcoming android project.

ps. thanks for introducing me to peewee.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] python framework for android

2012-01-03 Thread Kenneth Gonsalves
On Wed, 2012-01-04 at 14:13 +0800, Senthil Kumaran wrote:
 You can use django and fireup the browser in android to do the
 requests. :)

some how I have the feeling that django may be a trifle overkill ;-)
 
 Apart from that, there is android-scripting application (not a
 framework) http://code.google.com/p/android-scripting/, where in your
 restricted python scripts can be made to execute But that is far less
 featured than using Android SDK itself. I have seen people going back
 to SDK after trying the scripting environment for a while.

am looking at kivy right now
 
 
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] python framework for android

2012-01-03 Thread Kenneth Gonsalves
On Wed, 2012-01-04 at 14:24 +0800, Senthil Kumaran wrote:
 On Wed, Jan 4, 2012 at 2:18 PM, Kenneth Gonsalves law...@gmail.com
 wrote:
 
  am looking at kivy right now
 
 Looks neat. I would like to try that one too. 

there was a wonderful talk on it in the last pycon.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] golf problem

2011-12-28 Thread Kenneth Gonsalves
On Wed, 2011-12-28 at 06:44 +0530, Kenneth Gonsalves wrote:
 def peoria(holes):
 import random
 random.shuffle(holes) 
 result = []
 checklist = []
 used = []
 for hole in holes:
 if len(checklist) == 3:
 break
 if hole[1] not in checklist:
 result.append(hole)
 checklist.append(hole[1])
 used.append(hole)
 available = set(holes) - set(used)
 result.extend(list(available)[:3])
 return result 

and the my final version:

def peoria(holes):
random.shuffle(holes) 
result = []
checklist = []
for hole in holes:
if len(checklist) == 3:
break
if hole[1] not in checklist:
result.append(hole)
checklist.append(hole[1])
available = [x for x in holes if x not in result]
result.extend(available[:3])
return result
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] golf problem

2011-12-27 Thread Kenneth Gonsalves
On Tue, 2011-12-27 at 18:19 +0530, Pratap Chakravarthy wrote:
 I have posted at, http://pastebin.com/BG6X70Sv
 I don't understand why or how it got stripped. 

mailing list policy
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] golf problem

2011-12-27 Thread Kenneth Gonsalves
On Mon, 2011-12-26 at 17:34 +0530, Pratap Chakravarthy wrote:
  I don't like special casing stuff and the 3 selections outside the
 main flow sticks out in my solution.
 I guess that is right. Any logic that is outside the main flow breaks
 the beauty
 and create kludge. 

the old fashioned way:
def peoria(holes):
import random
random.shuffle(holes) 
result = []
checklist = []
used = []
for hole in holes:
if len(checklist) == 3:
break
if hole[1] not in checklist:
result.append(hole)
checklist.append(hole[1])
used.append(hole)
available = set(holes) - set(used)
result.extend(list(available)[:3])
return result
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Coming soon page designer needed (was: BangPypers Digest, Vol 52, Issue 26)

2011-12-27 Thread Kenneth Gonsalves
On Tue, 2011-12-27 at 18:26 +0530, Noufal Ibrahim wrote:
 P.S. This is the first email I've seen that's explictly asking for a
  beautiful coder to get work done. :) 

I was wondering why he did not ask for her photo
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] golf problem

2011-12-26 Thread Kenneth Gonsalves
On Mon, 2011-12-26 at 10:01 +0530, Pratap Chakravarthy wrote:
 # Initialize variables
 holes, bk = HOLES[:],   {} ;
 random.shuffle( holes )
 
 # Make buckets
 [ bk.setdefault(y, []).append((x,y)) for x, y in holes ]
 
 # Result
 print [ bk[3].pop(0), bk[4].pop(0), bk[5].pop(0) ] + random.sample(
 bk[3] + bk[4] + bk[5], 3 )
 
 Some times the crude method is the best method ? 

just curious - why do you and Noufal think this is a crude method?
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] golf problem

2011-12-26 Thread Kenneth Gonsalves
On Mon, 2011-12-26 at 17:34 +0530, Pratap Chakravarthy wrote:
 Attached is the file. 

I think the attachment got stripped.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] golf problem

2011-12-25 Thread Kenneth Gonsalves
On Mon, 2011-12-26 at 10:01 +0530, Pratap Chakravarthy wrote:
 # Initialize variables
 holes, bk = HOLES[:],   {} ;
 random.shuffle( holes )
 
 # Make buckets
 [ bk.setdefault(y, []).append((x,y)) for x, y in holes ]
 
 # Result
 print [ bk[3].pop(0), bk[4].pop(0), bk[5].pop(0) ] + random.sample(
 bk[3] + bk[4] + bk[5], 3 )
 
 Some times the crude method is the best method ?
 
 A crude analysis on the above logic and number of passes made on the
 sample list.
 1. To copy HOLES to holes
 2. To shuffle holes using random.shuffle()
 3. To make buckets
 4. random.sample() is another crude algorithm which seems to be in
 between O(n) and O(n^2) - a wild guess. 

I am pasting Gora's and G0sub's solutions here as pastebins expire and
the next golfer who searches this list will get confused.

Gora:

import random

ALL_HOLES=[(1, 5),
 (2, 3),
 (3, 4),
 (4, 4),
 (5, 5),
 (6, 4),
 (7, 3),
 (8, 4),
 (9, 3),
 (10, 4),
 (11, 3),
 (12, 4),
 (13, 4),
 (14, 3),
 (15, 4),
 (16, 5),
 (17, 4),
 (18, 4)]

PAR3_HOLES=[i for i in ALL_HOLES if i[1]==3]
PAR4_HOLES=[i for i in ALL_HOLES if i[1]==4]
PAR5_HOLES=[i for i in ALL_HOLES if i[1]==5]

# Must allow at least 2 holes of par 4, and 5
n3 = random.randint( 1, 4 )
SEL_PAR3_HOLES = random.sample( PAR3_HOLES, n3 )

# Must allow at least 1 hole of par 5
n4 = random.randint( 1, 5 - n3 )
SEL_PAR4_HOLES = random.sample( PAR4_HOLES, n4 )

n5 = 6 - n4 - n3
SEL_PAR5_HOLES = random.sample( PAR5_HOLES, n5 )

# Selected values are in SEL_PAR3_HOLES, SEL_PAR4_HOLES, SEL_PAR5_HOLES
print len( SEL_PAR3_HOLES ), len( SEL_PAR4_HOLES ), len( SEL_PAR5_HOLES
)

G0sub:

import random

ALL_HOLES=[(1, 5),
 (2, 3),
 (3, 4),
 (4, 4),
 (5, 5),
 (6, 4),
 (7, 3),
 (8, 4),
 (9, 3),
 (10, 4),
 (11, 3),
 (12, 4),
 (13, 4),
 (14, 3),
 (15, 4),
 (16, 5),
 (17, 4),
 (18, 4)]

PAR3_HOLES=[i for i in ALL_HOLES if i[1]==3]
PAR4_HOLES=[i for i in ALL_HOLES if i[1]==4]
PAR5_HOLES=[i for i in ALL_HOLES if i[1]==5]

# Must allow at least 2 holes of par 4, and 5
n3 = random.randint( 1, 4 )
SEL_PAR3_HOLES = random.sample( PAR3_HOLES, n3 )

# Must allow at least 1 hole of par 5
n4 = random.randint( 1, 5 - n3 )
SEL_PAR4_HOLES = random.sample( PAR4_HOLES, n4 )

n5 = 6 - n4 - n3
SEL_PAR5_HOLES = random.sample( PAR5_HOLES, n5 )

# Selected values are in SEL_PAR3_HOLES, SEL_PAR4_HOLES, SEL_PAR5_HOLES
print len( SEL_PAR3_HOLES ), len( SEL_PAR4_HOLES ), len( SEL_PAR5_HOLES
)


-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] golf problem

2011-12-25 Thread Kenneth Gonsalves
On Mon, 2011-12-26 at 10:01 +0530, Pratap Chakravarthy wrote:
 # Initialize variables
 holes, bk = HOLES[:],   {} ;
 random.shuffle( holes )
 
 # Make buckets
 [ bk.setdefault(y, []).append((x,y)) for x, y in holes ]
 
 # Result
 print [ bk[3].pop(0), bk[4].pop(0), bk[5].pop(0) ] + random.sample(
 bk[3] + bk[4] + bk[5], 3 )
 
 Some times the crude method is the best method ? 

perfect - you win a free golf lesson the next time you are in Ooty.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


[BangPypers] golf problem

2011-12-24 Thread Kenneth Gonsalves
hi,

a golf course has 18 holes. There are three types of hole - par 3, par 4
and par 5. For a certain type of tournament it is necessary to generate
a random list of 6 holes. The only condition is that this list should
contain at least one of each type of hole. What would be an elegant way
of doing this. Sample data for Ooty golf course is given below. The hole
number is the first element of each tuple and the par is the second
element.

[(1, 5),
 (2, 3),
 (3, 4),
 (4, 4),
 (5, 5),
 (6, 4),
 (7, 3),
 (8, 4),
 (9, 3),
 (10, 4),
 (11, 3),
 (12, 4),
 (13, 4),
 (14, 3),
 (15, 4),
 (16, 5),
 (17, 4),
 (18, 4)]
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Fwd: GlobalLogic Python Position

2011-12-10 Thread Kenneth Gonsalves
On Sat, 2011-12-10 at 20:07 +0530, chetan giridhar wrote:
 - OOPS concepts in Python

they want people who apologise when they drop things?
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Some weird issues even though apparently the syntax is correct.

2011-12-01 Thread Kenneth Gonsalves
On Fri, 2011-12-02 at 00:19 +0530, Subhodip Biswas wrote:
 Debugging reveals that the data in s becomes nonetype during the
 flow(so print y.someresult is also nonetype in the end). I am sure I
 am missing out something very silly here but catch the cat.  Please
 help me in finding where I am going wrong here. 

it would be nice if you posted the actual code you used (even if you are
working for the CIA I am sure they won't mind)
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Selenium with python training

2011-11-22 Thread Kenneth Gonsalves
On Wed, 2011-11-23 at 07:08 +0800, Senthil Kumaran wrote:
  javascript? not java? 
 
 I think, while recording the tests with selenium ide, DOM, XPATH, CSS
 and id know-hows were more useful than anything else.  These concepts
 are language agnostic, but given that many times we try to test the
 javascript events on browser, I thought javascript is more useful.

sorry - I was under the impression that selenium was written in Java
 
 Java is for mobile /server side these days, right? :) 

I would rather not express my opinion on what Java is for ;-)
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Transmeta in django is not working with mysql

2011-11-21 Thread Kenneth Gonsalves
On Tue, 2011-11-22 at 04:57 +, Asif Jamadar wrote:
 Thank you for your information. I'm using django_modeltranslation that
 did the trick for me.

me too
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Hello // Intro

2011-11-18 Thread Kenneth Gonsalves
On Fri, 2011-11-18 at 18:59 +0530, bhuvan thaker wrote:
 + What programming language is most suitable for web 2.0 kind of
 application development.
 This is in the context of time taken to build app + less problematic +
 platform neutral.

errm ... a wild guess - python?

-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Selenium with python training

2011-11-16 Thread Kenneth Gonsalves
On Thu, 2011-11-17 at 15:07 +0800, Senthil Kumaran wrote:
 BTW, selenium is web functional testing, more like how user uses the
 web app. It provides hooks to variety of languages, python being one.
 Javascript knowledge would be more desirable for selenium than
 python. 

javascript? not java? 
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] django signals

2011-11-15 Thread Kenneth Gonsalves
On Tue, 2011-11-15 at 14:19 +0530, Roshan Mathews wrote:
 Found via this wonderful site -
 https://www.google.com/search?q=django+signals+example which gave much
 better results than http://duckduckgo.com/?q=django+signals+example 

I resent that ;-). How about this:
http://duckduckgo.com/?q=site%3Adocs.djangoproject.com+signals+example

-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] seantis questionnaire - Django App

2011-11-15 Thread Kenneth Gonsalves
On Tue, 2011-11-15 at 06:47 +, Asif Jamadar wrote:
 Thanks for your answer.
 
 Now how user is created in 'Subject' model of Questionnaire App?
 
 Whether we need to create manually or allow user to create his
 credentials?
 
 And why this app always creates AnonymousUser?
 
 

the docs specifically state that django auth is not used. You will have
to roll your own (or use django auth)
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] seantis questionnaire - Django App

2011-11-15 Thread Kenneth Gonsalves
On Tue, 2011-11-15 at 22:32 +0530, Gora Mohanty wrote:
 * A smart person on the Solr mailing list put together this Wiki
   page on how best to use mailing lists. Somewhat Solr-specific,
   but definitely worth a read:
 http://wiki.apache.org/solr/UsingMailingLists
 
 

this is the django equivalent:
https://code.djangoproject.com/wiki/UsingTheMailingList
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] seantis questionnaire - Django App

2011-11-15 Thread Kenneth Gonsalves
On Tue, 2011-11-15 at 13:21 +, Asif Jamadar wrote:
 Another question how we can check the feature 'export CSV' in this
 questionnaire app?

export CSV means to create a comma separated file which can be imported
into a spreadsheet for analysis.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] seantis questionnaire - Django App

2011-11-14 Thread Kenneth Gonsalves
On Mon, 2011-11-14 at 13:52 +, Asif Jamadar wrote:
 Where i can get user manual or tutorial for seantis questionnaire
 django application?

their website would be a good place.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] seantis questionnaire - Django App

2011-11-14 Thread Kenneth Gonsalves
On Tue, 2011-11-15 at 04:37 +, Asif Jamadar wrote:
 Can you provide me the url for their webite?

http://duckduckgo.com/?q=seantis+questionnaire
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Seeks Professional Guidance ?

2011-11-09 Thread Kenneth Gonsalves
On Wed, 2011-11-09 at 16:45 +0530, vishnu prasad wrote:
 Greetings from vishnu prasad gaddam, am working in call centre i would
 like
 to continue my carrer in open source  especially in python language
 can u
 tell me python is related to web development how it is suppose to
 explore
 with django frame work ?

could you explain what you mean?
 is there any fresher job openings related to python

yes - many
 ?how much knowledge they can expect as a fresher in python ? 

you should know how to write a decorator.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


[BangPypers] collections

2011-11-09 Thread Kenneth Gonsalves
hi,

python collections are cool and I am dying to use them in production.
But so far I am yet to find a use case for using them - any experiences?
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] collections

2011-11-09 Thread Kenneth Gonsalves
On Wed, 2011-11-09 at 17:23 +0530, Saager Mhatre wrote:
  python collections are cool and I am dying to use them in
 production.
  But so far I am yet to find a use case for using them - any
 experiences?
 
 
 I'm assuming you mean the Python collections package that provides
 'High-performance container datatypes'.
 

yes
 We use defaultdict to good effect at work, but as far as I can tell,
 that's
 the only one we use from that package; other than Callable that I used
 in a
 bunch of test utilities, but that usage wasn't really valuable. 

but it must be useful for *something* ;-)
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] ubutu fonts..

2011-11-08 Thread Kenneth Gonsalves
On Tue, 2011-11-08 at 18:51 +0530, Sreenivas Reddy T wrote:
 Please pardon me for this off-topic post.

why should we?
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] ubutu fonts..

2011-11-08 Thread Kenneth Gonsalves
On Wed, 2011-11-09 at 10:48 +0530, Sreenivas Reddy T wrote:
 Would have been much better if you say  why should
 i?,since you cannot speak for others/you do not represent others
 here.anyway , i am leaving it to you to pardon me or not.. 

I do not - this is a blatant misuse of this list. And to add insult to
injury you give an arrogant reply instead of accepting your mistake. It
also shows that your 'apology' in the original post is insincere. btw,
since this list is governed by peer pressure every member is entitled to
speak in the list on behalf of the list. You did not ask *me* to forgive
you - you asked the list, so I have every right to ask why the list
should do so.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] File read

2011-11-07 Thread Kenneth Gonsalves
On Mon, 2011-11-07 at 16:53 +0530, Shashidhar Paragonda wrote:
 is my if else structure is wrong or not I am totally not getting
 other idea please help
   thank you in advance. 

please paste code
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


[BangPypers] pyjamas

2011-10-19 Thread Kenneth Gonsalves
hi,

I was looking at pyjamas - it seems a little unusual - has anyone used
it and has feedback on it?
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] webmail server

2011-10-13 Thread Kenneth Gonsalves
On Thu, 2011-10-13 at 11:47 +0530, Noufal Ibrahim wrote:
  that is my problem - the default for roundcube is mysql, and am
 unable
  to configure it for postgresql without spending time on
 understanding
  how installing drivers for PHP works. And I do not want to spend
 that
  time for a one-off thing like this.
 
 If it's one off and you're not going to use it for long, you can try
 posterity. 

*I* am not going to use it, and since it is not going to live on *my*
server, I went with roundcube/mysql. I now need to purify my laptop. 
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] webmail server

2011-10-12 Thread Kenneth Gonsalves
On Wed, 2011-10-12 at 18:01 +0530, Baishampayan Ghose wrote:
 Lamson - http://lamsonproject.org/

sorry - wrong question - I meant webmail client - like openwebmail.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] An interesting post on the next web app language

2011-10-08 Thread Kenneth Gonsalves
On Sat, 2011-10-08 at 13:29 +0530, Sriram Narayanan wrote:
 http://seldo.com/weblog/2011/08/11/php_needs_to_die_what_will_replace_it

the guy seems to be a bit confused at the difference between a language
and a framework - hardly surprising given his core competency.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [OT] Git training course

2011-10-07 Thread Kenneth Gonsalves
On Fri, 2011-10-07 at 13:59 +0530, Noufal Ibrahim wrote:
 This is OT for the list but a lot of people expressed interest
 in this when I spoke to them at PyCon in Pune. 
 
 I am offering a training on git on the 22nd and 23rd of
 October
 in Bangalore. 
 
 The details are at
 http://nibrahim.net.in/2011/10/07/git_training.html
 
 Please spread the word. 

if you were to include something on mercurial, it would no longer be OT
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [OT] Git training course

2011-10-07 Thread Kenneth Gonsalves
On Fri, 2011-10-07 at 15:23 +0530, Noufal Ibrahim wrote:
  if you were to include something on mercurial, it would no longer be
  OT
 
 Arguably but I don't use hg. 

I see some repos on bitbucket - you maintain them with hg-git? (a good
topic that you could add)
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Python 3.2 and Django

2011-09-29 Thread Kenneth Gonsalves
On Wed, 2011-09-28 at 21:53 -0700, Hussain Bohra wrote:
 Let me identify if any other MVC framework I can use along with python
 3.2.

django is not an MKC framework anyway.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] List guidelines (was: [JOB] - Yahoo!)

2011-09-16 Thread Kenneth Gonsalves
On Wed, 2011-09-14 at 18:10 +0530, Noufal Ibrahim wrote:
 I hear from others (BRUG, BarCamp Bangalore) that first time posters
 who
 send recruitment mails are simply rejected. That sounds like a sane
 policy to me. 

chennaipy rejects all recruitment mail that does not have any concrete
reference to python.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] List guidelines

2011-09-16 Thread Kenneth Gonsalves
On Wed, 2011-09-14 at 18:47 +0530, Noufal Ibrahim wrote:
 So, job postings not at all related to Python are fine as long as
 they're prefixed with [JOB]? 

no - unless it is a generic 'programmers wanted' post without specifying
tools.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] List guidelines

2011-09-16 Thread Kenneth Gonsalves
On Wed, 2011-09-14 at 18:56 +0530, Noufal Ibrahim wrote:
 So, random headhunters/recruiters are free to use this list to post
 for
 any job postings but the onus is on the list members to filter out the
 Python related postings from the non python ones. Correct? 
 
 Am I the only one who thinks this is backward? 

I am with you
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers



Re: [BangPypers] List guidelines

2011-09-16 Thread Kenneth Gonsalves
On Wed, 2011-09-14 at 20:17 +0530, Sriram Narayanan wrote:
 Sorry, poking fun at a company's board of directors, etc, is in poor
 taste, and cannot be condoned off as light hearted humor. Poking fun
 at a company's practices, especially one which one may not yourself
 practice and therefore not be in a position to comment on, is also
 tells poorly poorly about that commentator. It has been only these two
 cases that I've raised concerns about. 

nothing wrong with poking fun
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [JOB] - Yahoo!

2011-09-14 Thread Kenneth Gonsalves
On Tue, 2011-09-13 at 18:37 +0530, Sriram Narayanan wrote:
 We have to then solve a problem to having a common understanding of
 what's fine and what's not. 

python is fine - non python is not fine. Lighthearted banter is fine.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [JOB] - Yahoo!

2011-09-14 Thread Kenneth Gonsalves
On Tue, 2011-09-13 at 18:38 +0530, Anand Balachandran Pillai wrote:
 Please, love your language etc, but let us give the impression that
 we are not a bunch of amateur kids here, but professionals who
 are ready to give a bit of space for others to live amongst us.
 
 I made the mistake of telling OK to this guy on posting here, never
 going to repeat the mistake again. I had thought better of this list
 in fact. My bad. 

love of language is not the issue - this list has a specific focus, and
we need to respect that.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [JOB] - Yahoo!

2011-09-14 Thread Kenneth Gonsalves
On Tue, 2011-09-13 at 18:39 +0530, hemant wrote:
 - Does it have [JOB] or something in subject, so as people can steer
 clear if they want?
 - Does it exactly say, what the requirements are and for which
 company?
 - Does it mention location?
 - It should not sound phony.
 
 If a job posting matches all of the above, it is all good. However, as
 a community if everyone agrees, one can add:
 
 - Must mention Python as keyword in job posting. 

an advertisement for a job in a zoo involving cleaning the reptile
enclosure would fulfill your criteria.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [JOB] - Yahoo!

2011-09-13 Thread Kenneth Gonsalves
On Tue, 2011-09-13 at 12:45 +0530, Sreekanth S Rameshaiah wrote:
  Let's keep it technical, they seem to look for perl guys and perhaps
 a
  python developers are useful for them too.
  Of course, any good company would think that good python programmers
  can be good (any language) programmers too. AFAIK, Y! is one such.
 
  That is not evident in their post. I think people should respect the
 list
 users when posting. In Python is not mentioned as a skill set, then
 this
 list should not be used for those wildcard job offers. 

+1
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Create Better Python community

2011-08-18 Thread Kenneth Gonsalves
On Fri, 2011-08-19 at 10:11 +0530, Noufal Ibrahim wrote:
  Maybe we should have more hackdays. Something the IPSS
  should think about pretty soon.
 
 [...]
 
 I don't mind travelling any distance once a month. 
 
 My main problem is the lack of interest. I mailed for a few months
 (after our last PyCon) and meetings took place. After that, the apathy
 was too much. 

chennaipy meets on the 4th Saturday of every month, this is fixed.
Attendance varies from 2 to 15. So the question is not 'shall we meet?'
but 'are you attending'. This has been going on since 2006 with some
breaks now and then.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] two dropdowns dependents on each other

2011-08-16 Thread Kenneth Gonsalves
On Tue, 2011-08-16 at 05:50 +, Asif Jamadar wrote:
 Can you provide me example using ajax?

I do not do ajax - all the samples are proprietary.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] two dropdowns dependents on each other

2011-08-16 Thread Kenneth Gonsalves
On Tue, 2011-08-16 at 05:46 +, Asif Jamadar wrote:
 I have two dropdowns one dropdown is dependent on other (Ex.
 Country/State dropdowns)
 
 Now how can I implement this thing in django?
 
 I'm using modelform concept to display form which having two dropdowns
 
 Any sugtgestions? 

without ajax:

1. override __init__ on your modelform, pass the value of the first
dropdown to __init__ and populate the second dropdown depending on that
value. If the value is None, the second dropdown will not be populated.

2. in your template, refresh the page when the value of the first
dropdown changes.

A sample of overriding __init__ is here:
https://bitbucket.org/lawgon/djangogolf/src/822bb414b722/web/views.py#cl-379
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] two dropdowns dependents on each other

2011-08-16 Thread Kenneth Gonsalves
On Tue, 2011-08-16 at 15:45 +0530, Amit Sethi wrote:
  without ajax:
 
  1. override __init__ on your modelform, pass the value of the first
  dropdown to __init__ and populate the second dropdown depending on
 that
  value. If the value is None, the second dropdown will not be
 populated.
 
  2. in your template, refresh the page when the value of the first
  dropdown changes.
 
 There might be a small problem doing this without ajax. While
 reloading, the __init__ of the first form will also  run which will
 bring all user input to default,and thus would require you set the
 values again explicitly instead why not get the values  as json object
 and populate as required using jquery. 

ajax is the way to go - but if you need to learn ajax for it and there
is a deadline ... again depends on what kind of form it is. For bus
booking one can force the user to populate the dropdowns first.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] two dropdowns dependents on each other

2011-08-15 Thread Kenneth Gonsalves
On Tue, 2011-08-16 at 05:46 +, Asif Jamadar wrote:
 I have two dropdowns one dropdown is dependent on other (Ex.
 Country/State dropdowns)
 
 Now how can I implement this thing in django?
 
 

ajax
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Create Better Python community

2011-08-12 Thread Kenneth Gonsalves
On Fri, 2011-08-12 at 22:36 +0530, kracekumar ramaraju wrote:
 Things you could do to improve diversity

what is a diverse person?
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] how to write Operating System in python

2011-08-11 Thread Kenneth Gonsalves
On Thu, 2011-08-11 at 15:26 +0530, Noufal Ibrahim wrote:
 vikas ruhil vikasruhi...@gmail.com writes:
 
  I am looking towards to write an operating system in Python? How i
 can
  write kernel and kernel calls on Debian Linux ! any body can help
  reagrd this !!
 
 [...]
 
 I mailed a while ago about choosing the right tool for a given task
 (as
 opposed to seeing everything as a nail). 
 
 Are there any reasons why you're interested in doing this in Python
 (as
 opposed to say Ruby)? 

or C?
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] parsing xml

2011-08-01 Thread Kenneth Gonsalves
On Sun, 2011-07-31 at 19:57 +0530, Anand Balachandran Pillai wrote:
  xml parsing in the case when all that you need from the string is a
 simple
  numeric value(not a string), then good luck; unlike esr i will not
 use
  adjectives; but i would not use your code either.
 
 
 To be fair here, I think what he is saying is that Kenneth's problem
 (getting
 at the particular value) can be solved by using an aptly written
 regular
 expression which might be the fastest - not in terms of CPU cycles
 alone,
 but in terms of time to code it up - solution. 

right now I need one value - but that will probably change.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


[BangPypers] parsing xml

2011-07-28 Thread Kenneth Gonsalves
hi,

here is a simplified version of an xml file:

?xml version=1.0 encoding=UTF-8?
gpx 
metadata
author
nameCloudMade/name
email id=support domain=cloudmade.com /
link href=http://maps.cloudmade.com;/link
/author
copyright author=CloudMade
licensehttp://cloudmade.com/faq#license/license
/copyright
time2011-07-28T07:04:01/time
/metadata
extensions
distance1489/distance
time344/time
startSägerstraße/start
endIm Gisinger Feld/end
/extensions
/gpx

I want to get the value of the distance element - 1489. What is the
simplest way of doing this?
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] parsing xml

2011-07-28 Thread Kenneth Gonsalves
On Thu, 2011-07-28 at 15:33 +0530, Anand Chitipothu wrote:
  I want to get the value of the distance element - 1489. What is the
  simplest way of doing this?
 
  from xml.dom import minidom
  dom = minidom.parseString(x)
  dom.getElementsByTagName(distance)[0].childNodes[0].nodeValue
 u'1489' 

thanks - perfect.
-- 
regards
Kenneth Gonsalves

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [OT] language fanaticism

2011-07-14 Thread Kenneth Gonsalves
On Thu, 2011-07-14 at 19:18 +0530, Venkatraman S wrote:
 Never seen KG type so much till now ;)

finally getting some speed with Dvorak.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [OT] language fanaticism

2011-07-13 Thread Kenneth Gonsalves
On Wed, 2011-07-13 at 15:10 +0530, Noufal Ibrahim wrote:
  I know my limitations - a, if the client agrees or c. But I *have*
  turned away work where my skill set does not fit. (I would not touch
  java with a bargepole - if that is language fanaticism, so be it).
 
 Maybe not code in the language but if something that already does what
 your client wants exists in Java, would you stay away from it purely
 because you don't like the language? (e.g. Solr for text indexing and
 searching) 

no - as long as there is no need for me to touch the source. I use
freemind and josm very extensively.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [OT] language fanaticism

2011-07-13 Thread Kenneth Gonsalves
On Wed, 2011-07-13 at 15:07 +0530, Noufal Ibrahim wrote:
 
  let us look at all points of view. In an ideal world, one chooses
 the
  best tool for the job at hand. No quarrel. But the world is not
 ideal.
  Compromises have to be made (or trade-offs). Given a task one has to
  take into account deadlines, resources/skills available etc etc.
 Maybe
  for a particular webapp Django is overkill - but do I have the time
 to
  learn something more suitable (or the ability)?
 
 It's sometimes an option to simply use an app already available
 (e.g. Wordpress for blogging) rather than to go out and build a custom
 one. If building and deploying (and maintaining) a Django or Flask (or
 rails for that matter) blogging app takes 6 hours whereas setting up a
 wordpress blog takes 5 minutes, what would you chose? 

django - I like to sleep at night. I use apps written in all sorts of
languages, but never have and never will use a php app - unless it is
set up and supported by someone else and is running on a system for
which I am in no way responsible.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [OT] language fanaticism

2011-07-13 Thread Kenneth Gonsalves
On Wed, 2011-07-13 at 15:51 +0530, satyaakam goswami wrote:
  django - I like to sleep at night. I use apps written in all sorts
 of
  languages, but never have and never will use a php app - unless it
 is
  set up and supported by someone else and is running on a system for
  which I am in no way responsible.
 
 
 why ?  any personal bad experience or some technical reasons? 

many bitter experiences - security is a nightmare for php apps. Take a
look at the number of security updates wordpress has per *month* - more
than django has had in 6 *years*.

http://wordpress-security.net/wordpress-software-security-updates/
--- do you want to live on the edge like this? 

Most LUG sites run php, maintained by 'experts' - they are regularly
spammed or cracked even when the most draconian lockdown/captchas are
implemented. Volunteers just do not have the time to spend half their
nights applying security patches. 
quote
Important note about updating Themes:
If you have made **any** changes to your theme (tweaking things in
style.css or changes to the template files), the changes will be
overwritten when the theme is updated. Be ready to re-do the changes
after updating.
unquote

what fun!
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [OT] language fanaticism

2011-07-12 Thread Kenneth Gonsalves
On Wed, 2011-07-13 at 05:28 +0800, Senthil Kumaran wrote:
  The Ruby Speed Center (which is similar to speed.pypy.org) uses
  codespeed which is a Python/Django based application[1].
 
 And yeah, not to miss that many python based projects have started
 using jenkins for CI which is Java based. :) Quite recently, my
 experience with (good) developers is that everyone is picking up a
 variety of languages and libraries for different tasks. The choice
 seem to be with things that stack up well. For e.g using solr for
 python webapps. 

let us look at all points of view. In an ideal world, one chooses the
best tool for the job at hand. No quarrel. But the world is not ideal.
Compromises have to be made (or trade-offs). Given a task one has to
take into account deadlines, resources/skills available etc etc. Maybe
for a particular webapp Django is overkill - but do I have the time to
learn something more suitable (or the ability)? 
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [OT] language fanaticism

2011-07-12 Thread Kenneth Gonsalves
On Wed, 2011-07-13 at 08:07 +0800, Senthil Kumaran wrote:
 Question to you (hypothetical) - You have two choices:
 
 a) Choose Pyramid web-framework because the ORM works well the
 existing database.
 
 b) Java project with heavy interaction with database.
 
 Which would you likely choose? My bet is a) because it is much easier
 for a python programmer with django skills to do that than b).
 Of course, you are free to invent your choices like c) quit and do
 django elsewhere.
 
 

I know my limitations - a, if the client agrees or c. But I *have*
turned away work where my skill set does not fit. (I would not touch
java with a bargepole - if that is language fanaticism, so be it).
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Iterating list of tuples

2011-07-04 Thread Kenneth Gonsalves
On Mon, 2011-07-04 at 06:37 +, delegb...@dudupay.com wrote:
 
 data = [
 (10, 25, 18, 17, 10, 12, 26, 5),
 ]
 
 for value in data:
  if value  5: 

value = (10, 25, 18, 17, 10, 12, 26, 5)
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [OT] getting a business email vendor

2011-06-30 Thread Kenneth Gonsalves
On Thu, 2011-06-30 at 11:57 +0530, Vishal wrote:
 This is Off Topic and nothing related to Python in general...thought
 of
 sending here since many industry veterans watch this list.
 
 

please refrain from such questions in future.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] svg string to pdf

2011-06-29 Thread Kenneth Gonsalves
On Thu, 2011-06-30 at 01:40 +0530, Gora Mohanty wrote:
 You must have mistaken me for someone willing to do your homework for
 you
 for free. 

please watch your tone - this is not ilugd.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


[BangPypers] bof

2011-06-28 Thread Kenneth Gonsalves
hi,

there will be a bof this evening at Koshys, 7 pm onwards.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] bof

2011-06-28 Thread Kenneth Gonsalves
On Tue, 2011-06-28 at 14:18 +0530, Shashidhar P wrote:
 Which Koshys ? Richmond town or where?

st Marks road
 and what is bof? 

come and find out
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] python SVN delete functionality

2011-06-22 Thread Kenneth Gonsalves
On Wed, 2011-06-22 at 17:19 +0530, Shashidhar P wrote:
   If end user deletes some files from working copy MANUALLY
 not
 using SVN delete, I need to comapare working copy and repository
 before
 checkin and make sure that files which are deleted manually from
 working
 copy should be deleted from the repository. 

that is what svn status does.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] python SVN delete functionality

2011-06-22 Thread Kenneth Gonsalves
On Wed, 2011-06-22 at 17:45 +0530, Shashidhar P wrote:
 I want to check all the files from working copy to repository if
 files are missing from working copy and found in repository I need to
 delete
 them.
 
Ya SVN Status gives me files added, removed, I mentioned
 user
 deletes files manually not using SVN delete. how should I check for
 deleted
 files. 

shown as '!' - svn help status
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Error loading fixtures after adding a contenttype relation

2011-06-13 Thread Kenneth Gonsalves
On Mon, 2011-06-13 at 22:05 +0530, Amit Sethi wrote:
 IntegrityError: duplicate key value violates unique constraint
 django_content_type_app_label_key 

it means that that particular column is already in the database.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] Using south for migration for a django project

2011-05-19 Thread Kenneth Gonsalves
On Thu, 2011-05-19 at 12:45 +0530, Amit Sethi wrote:
 Can some one help me out with this . Point to a good tutorial for
 south or recommend a tool that has worked for them in the past.
 
 

as mentioned on IRC the easiest way is to write a script and do it
manually.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] The myth of free software

2011-05-18 Thread Kenneth Gonsalves
On Tue, 2011-05-17 at 17:35 +0530, Santosh Rajan wrote:
 Hey, great argument, but I have some riders. Atleast, finally, I think
 we
 are on the same page. 

did you not notice that he was pulling your leg?
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] [commercial] python/django training

2011-05-16 Thread Kenneth Gonsalves
On Mon, 2011-05-16 at 11:48 +0530, Ramdas S wrote:
 Kenneth as I understand is *offering nothing free*. He is charging*
 25,000*for mentoring someone to be a Django/Python developer spending
 his personal
 time, energy and sharing his vast experience. He says exercise would
 take
 1-3  months. Personally I feel he's charging low, but I am sure he has
 his
 economics right!

Introductory offer
 
 It *does not in anyway make it a community* effort.  Kenneth  or
 anyone in
 this list has any such notion, or even making any such claims. I am
 not able
 to understand where you formed such an opinion that we are passing
 this off
 as a community effort. No we are not, and as far as I see there's
 *commercial
 in square brackets* in the subject of the mail. 

and to set the record straight, I have conducted innumerable workshops
in python/django (and a whole raft of other topics), usually free,
sometimes with accommodation and food provided, at other times even with
travel provided and at other times entirely at my own expense. And have
mentored very many people (totally free), and none of those people are
walking around bare footed. From all this I have learned three things:

1. Quality training is takes up a lot of time and effort - no one can
afford to do this free. 

2. Unfortunately in our country very few people appreciate things that
are free - and even fewer people really make much effort when doing
something for free. At the most they will put up a few slides they have
shown somewhere else, demo a few things and answer a few questions.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


Re: [BangPypers] The myth of free software

2011-05-16 Thread Kenneth Gonsalves
On Mon, 2011-05-16 at 20:22 +0530, Santosh Rajan wrote:
 Disclaimer 2. I am not an expert on the subject of free Vs paid.

this is obvious - I suggest you stick to things you are an expert on.
-- 
regards
Kenneth Gonsalves
http://lawgon.livejournal.com/

___
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers


  1   2   3   4   5   >