Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Rick Johnson
On Wednesday, November 13, 2013 6:17:22 PM UTC-6, Tim Daneliuk wrote: > > But python modules can't be interfaces because interfaces > > should protect internal data, prevent external forces from > > meddling with internal state (EXCEPT via the rules of a > > predefined "contract"), hide dirty detai

Re: chroot to install packages

2013-11-13 Thread Chris Angelico
On Thu, Nov 14, 2013 at 1:12 PM, Steven D'Aprano wrote: > The next bit is the part I have no idea about... use your operating > system tools to set up a chroot jail for "inside.py". Google is your > friend there, I'm sure there will be many, many websites that discuss > chroot jails. I think Pyth

Re: Most discussion on comp.lang.python is about developing with Python

2013-11-13 Thread Cameron Simpson
On 13Nov2013 23:48, Steven D'Aprano wrote: > As a community, it is difficult to balance the conflicting needs here. If > we ignore Nikos completely, we appear unfriendly and indifferent to those > asking for help. If we answer his questions, we encourage him to post. It > is hard to find the r

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Steven D'Aprano
On Wed, 13 Nov 2013 18:10:59 -0800, Rick Johnson wrote: > On Wednesday, November 13, 2013 5:42:24 PM UTC-6, Rhodri James wrote: >> On Tue, 12 Nov 2013 02:06:09 -, Rick Johnson wrote: >> > PyMyth: Global variables are evil... WRONG! >> That's not a PyMyth. It's a CompSciMyth, or to be more acc

Re: Trying tcompile an use the Python 3.4a

2013-11-13 Thread Steven D'Aprano
On Wed, 13 Nov 2013 09:29:38 -0800, Ned Batchelder wrote: > I strongly recommend that you stay on Python 2, and focus on other > concerns. Nikos has been using Python 3.3 for his website for months now. -- Steven -- https://mail.python.org/mailman/listinfo/python-list

Re: Most discussion on comp.lang.python is about developing with Python

2013-11-13 Thread Steven D'Aprano
On Thu, 14 Nov 2013 10:29:03 +1100, Chris Angelico wrote: > On Thu, Nov 14, 2013 at 7:35 AM, bob gailer wrote: >> I am very disappointed to see so much energy and bandwidth going to >> conversations that bash individuals. >> >> > I agree, and there've been times when I've been part of the problem

Re: Trying tcompile an use the Python 3.4a

2013-11-13 Thread Steven D'Aprano
On Thu, 14 Nov 2013 01:10:09 +, Mark Lawrence wrote: > Stop him and stop the spoon feeders and I stop. Simples. Oh, why didn't you say so in the first place? Okay, I'll just wave my magic wand and say the magic words and he'll go away... Hmmm, it doesn't seem to be working. Perhaps you

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Rick Johnson
On Wednesday, November 13, 2013 7:09:42 PM UTC-6, Steven D'Aprano wrote: > On Wed, 13 Nov 2013 23:42:24 +, Rhodri James wrote: > > On Tue, 12 Nov 2013 02:06:09 -, Rick Johnson wrote: > >> Python has globals, but we just can't admit it! > > A different subject entirely, but no more accuratel

Imports and cyclical dependencies

2013-11-13 Thread Brendan Abel
I have a relatively large python package that has several cyclical dependencies. The cyclical dependencies typically aren't a problem so long as I'm just importing modules, and not named attributes (ie. function, class, globals), which may not be defined at a given point in the import routine

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Chris Angelico
On Thu, Nov 14, 2013 at 2:22 PM, Rick Johnson wrote: > Yeah, a "global" keyword that extends access ONLY as far as > module level scope -- hardly a *true* global. I have yet to see any language that gives true globals. At very best, they're just process-wide! Honestly. How am I supposed to write

Re: How to disable RTLD_NOW for Python 2.7.x dlopen() in Mac OS X Mavericks?

2013-11-13 Thread Ned Deily
In article , tcwa...@gmail.com wrote: > I'm facing a problem with a 3rd party C/C++ Framework (dynamic library) on > Mac OS X which I'm trying to import into Python using ctypes. Unfortunately > OS X has deprecated a function which is called from the Framework and is no > longer available as of

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Rick Johnson
On Wednesday, November 13, 2013 8:45:16 PM UTC-6, Steven D'Aprano wrote: > A fully-auto machine gun with a hair-trigger and no > safety is no different from a single-barrel shotgun with > a safety and a trigger lock! You can blow your foot off > with both! Yes. But in the case of the shotgun

Re: Automation

2013-11-13 Thread renato . barbosa . pim . pereira
Thanks for all the help, I finished the program, follow the download link and a brief explanation of the same (in Portuguese, my native language), I apologize again for my bad english and any inconvenience that I have generated. http://mundodacana.blogspot.com.br/2013/11/programa-para-calculo-de

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Rick Johnson
And what's this? *picks up hat* Where did this hat come from??? Spectator interrupts: Maybe Steven threw his hat in? No, no. Can't be. Steven would not wear something this old. I mean, it looks like something a farmer would put on a scarecrow or something??? *scratched head* OH

Re: Automation

2013-11-13 Thread Rick Johnson
On Sunday, November 3, 2013 5:32:46 PM UTC-6, Denis McMahon wrote: > Seems to me like you're using a sledgehammer to shell a peanut. And hopefully he knows whether or not he has a peanut allergy before he commits to enjoying the fruits of his labor. -- https://mail.python.org/mailman/listinfo/

Re: Automation

2013-11-13 Thread Rick Johnson
bob gailer wrote: > Does this have anything to do with statistics? Quantum > theory? Telephony? > > P = Pluto, V = Venus, S = Saturn? > > Help us understand - then we *might* be able to help you. bob later gailer wrote: > Oh ... will you please explain in good English and a lot > more detail. I

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Roy Smith
In article , Chris Angelico wrote: > I have yet to see any language that gives true globals. At very best, > they're just process-wide! Honestly. How am I supposed to write code > that accesses variables running on my New York server? Any one of a slew of remote procedure call protocols. These

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Rick Johnson
On Wednesday, November 13, 2013 10:33:22 PM UTC-6, Roy Smith wrote: > Wait, aren't you the guy who's into MUDs? Yes he is. But that's his second favorite hobby. His first is filling the "Devils Advocate" slot when Steven is too busy -- doing WHATEVER Steven does when he's not here. God only

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Chris Angelico
On Thu, Nov 14, 2013 at 3:33 PM, Roy Smith wrote: > In article , > Chris Angelico wrote: > >> I have yet to see any language that gives true globals. At very best, >> they're just process-wide! Honestly. How am I supposed to write code >> that accesses variables running on my New York server? >

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Steven D'Aprano
On Wed, 13 Nov 2013 19:45:42 -0800, Rick Johnson wrote: > On Wednesday, November 13, 2013 8:45:16 PM UTC-6, Steven D'Aprano wrote: >> A fully-auto machine gun with a hair-trigger and no >> safety is no different from a single-barrel shotgun with a safety and >> a trigger lock! You can blow your

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Steven D'Aprano
On Wed, 13 Nov 2013 23:33:22 -0500, Roy Smith wrote: > In article , > Chris Angelico wrote: > >> I have yet to see any language that gives true globals. At very best, >> they're just process-wide! Honestly. How am I supposed to write code >> that accesses variables running on my New York server

Re: python 2.7.x on MacOSX: failed dlopen() on .so's

2013-11-13 Thread Ned Deily
On Nov 13, 2013, at 17:24 , Paul Smith wrote: > On Wed, 2013-11-13 at 16:00 -0800, Ned Deily wrote: >>> The reason I've set PYTHONHOME is ultimately I need this installation to >>> be relocatable. It's going to be shared across lots of different >>> systems and they'll have the ability to copy

Re: writing fortran equivalent binary file using python

2013-11-13 Thread David Froger
Hi Sudheer, Fortan binary format is not portable, and it's hard to work with it with different langages, compilers, architectures... In you're Python code, you also use NetCDF, which solve all these problems. I would suggest to use only NetCDF files in both Python and Fortran code. (So never use

Re: python 2.7.x on MacOSX: failed dlopen() on .so's

2013-11-13 Thread Paul Smith
On Wed, 2013-11-13 at 16:00 -0800, Ned Deily wrote: > > The reason I've set PYTHONHOME is ultimately I need this installation to > > be relocatable. It's going to be shared across lots of different > > systems and they'll have the ability to copy it wherever they want. > > That could be problemat

<    1   2