Re: Accessing variables in __init__.py

2012-10-16 Thread Gaudha
On Tuesday, October 16, 2012 3:41:55 PM UTC+5:30, Marco Nawijn wrote: > On Tuesday, October 16, 2012 10:48:17 AM UTC+2, Gaudha wrote: > > > my_package/ > > > > > > __init__.py > > > > > > my_module1.py > > &

Accessing variables in __init__.py

2012-10-16 Thread Gaudha
my_package/ __init__.py my_module1.py my_module2.py variables.py I want to define common variables in __init__.py and use the namespace in my_module1.py or my_module2.py. Defining it is not a problem. How can call it from my modules? If I define them in a module (say, variables.py), I c

Re: to use unicode strings only

2009-06-28 Thread Gaudha
On Jun 27, 9:44 pm, Benjamin Peterson wrote: > Gaudha gmail.com> writes: > > > And Peter, I tried importing the __future__ module. It's also not > > working... > > How so? Sorry guys, __future__ module is working excellent :-). I had some bad coding somewhere el

Re: to use unicode strings only

2009-06-27 Thread Gaudha
On Jun 27, 4:54 pm, Peter Otten <__pete...@web.de> wrote: > MRAB wrote: > > Gaudha wrote: > >> I wanna make all the strings in my code unicode strings. How to do it > >> without giving unicode switch 'u' before every string? > > > Use Pytho

to use unicode strings only

2009-06-27 Thread Gaudha
Hey gentlemen, I wanna make all the strings in my code unicode strings. How to do it without giving unicode switch 'u' before every string? -- http://mail.python.org/mailman/listinfo/python-list

Re: how to stop a function execution like...

2009-06-16 Thread Gaudha
On Jun 16, 4:45 pm, "Diez B. Roggisch" wrote: > Gaudha wrote: > > Is there any built-in function to stop execution of a function similar > > to stop the program execution by sys.exit? > > In the example below, I want to skip statement 2... if the 'if' >

how to stop a function execution like...

2009-06-16 Thread Gaudha
Is there any built-in function to stop execution of a function similar to stop the program execution by sys.exit? In the example below, I want to skip statement 2... if the 'if' condition is satisfied. Don't advice me to put statement 2 in 'else' block. That's not my intention. May be this a simple

openhook

2009-06-07 Thread Gaudha
Can anybody tell me what is meant by 'openhook' ? -- http://mail.python.org/mailman/listinfo/python-list

help needed on loop controls

2009-03-29 Thread Gaudha
Hi Pythons I have got some problems with exiting and continuing nested loops. Some solving ideas found somewhere like http://offog.org/ideas/python-loop-exit.html. I searched in depth of the Official Python Documentation and couldn't find any like that. Did that ideas implemented as it is or in s