Re: Python's "only one way to do it" philosophy isn't good?

2007-06-30 Thread Douglas Alan
Paul Rubin <http://[EMAIL PROTECTED]> writes: > Douglas Alan <[EMAIL PROTECTED]> writes: >> P.S. Besides Haskell is basically a refinement of ML, which is a >> dialect of Lisp. > I'd say Haskell and ML are descended from Lisp, just like mammals are > de

Re: Python's "only one way to do it" philosophy isn't good?

2007-06-30 Thread Douglas Alan
Paul Rubin writes: > Haskell and ML are both evaluate typed lambda calculus unlike Lisp > which is based on untyped lambda calculus. Certainly the most > familiar features of Lisp (dynamic typing, S-expression syntax, > programs as data (Lisp's macro system results from

Re: Python's "only one way to do it" philosophy isn't good?

2007-06-30 Thread Douglas Alan
Lenard Lindstrom <[EMAIL PROTECTED]> writes: > Explicitly clear the exception? With sys.exc_clear? Yes. Is there a problem with that? |>oug -- http://mail.python.org/mailman/listinfo/python-list

Re: Python's "only one way to do it" philosophy isn't good?

2007-06-30 Thread Douglas Alan
I wrote: > P.S. The last time I took a language class (about five or six years > ago), the most interesting languages I thought were descended from > Self, not any functional language. (And Self, of course is descended > from Smalltalk, which is descended from Lisp.) I think that Cecil is the p

Re: equality & comparison by default (was Re: Too many 'self' in python.That's a big flaw in this language.)

2007-07-01 Thread Alan Isaac
lly not identical in this sense. Of course you can make them so if you wish, but it is odd. So *nothing* is wrong here, imo. Btw: >>> a = 12 >>> b = 12 >>> a == b True >>> a is b True Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: Python's "only one way to do it" philosophy isn't good?

2007-07-02 Thread Douglas Alan
Lenard Lindstrom <[EMAIL PROTECTED]> writes: >>> Explicitly clear the exception? With sys.exc_clear? >> Yes. Is there a problem with that? > As long as nothing tries to re-raise the exception I doubt it breaks > anything: > > >>> import sys > >>> try: > raise StandardError("Hello") > ex

Re: Python's "only one way to do it" philosophy isn't good?

2007-07-02 Thread Douglas Alan
Lenard Lindstrom <[EMAIL PROTECTED]> writes: >> You don't necessarily want a function that raises an exception to >> deallocate all of its resources before raising the exception, since >> you may want access to these resources for debugging, or what have >> you. > No problem: > > [...] > > >>> c

Re: Python's "only one way to do it" philosophy isn't good?

2007-07-02 Thread Douglas Alan
Lenard Lindstrom <[EMAIL PROTECTED]> writes: >> I'm not sure I understand you here. You're saying that I should have >> the foresight to wrap all my file opens is a special class to >> facilitate debugging? > Obviously you had the foresight to realize with statements could > compromise debugging

Re: Python's "only one way to do it" philosophy isn't good?

2007-07-02 Thread Douglas Alan
Lenard Lindstrom <[EMAIL PROTECTED]> writes: >> Also, any caught exception is automatically cleared when >> the catching procedure returns anyway, so it's not like Python has >> ever considered a caught exception to be precious information that >> ought to be preserved long past the point where it

allow scripts to use .pth files?

2007-07-03 Thread Alan Isaac
assuming there is not one. (?) How about allowing a `scripts.pth` file in such a `scripts` directory, to work like a path configuration file? (But to be used only when __name__=="__main__".) Drawbacks? Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Memory leak issue with complex data structure

2007-07-04 Thread Alan Franzoni
my problem without seeing the actual code (which I can't post) but I'm asking if there's any tool/debugger I could employ in order to track what's happening. Thanks! -- Alan Franzoni <[EMAIL PROTECTED]> - Togli .xyz dalla mia email per contattarmi. Remove .xyz from my address

Re: allow scripts to use .pth files?

2007-07-04 Thread Alan Isaac
> On Jul 3, 7:35 am, Alan Isaac <[EMAIL PROTECTED]> wrote: >>Suppose I have a directory `scripts`. >>I'd like the scripts to have access to a package >>that is not "installed", i.e., it is not on sys.path. >>On this list, various people have describe

disappearing documentation of `coerce`

2007-07-04 Thread Alan Isaac
Once upon a time, `coerce` was documented with the other built-ins. http://pydoc.org/1.5.2/__builtin__.html Now it is not. http://docs.python.org/lib/built-in-funcs.html Reason? Thanks, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: disappearing documentation of `coerce`

2007-07-05 Thread Alan Isaac
> On 2007-07-05, Alan Isaac <[EMAIL PROTECTED]> wrote: >>Once upon a time, `coerce` was documented >>with the other built-ins. Neil Cerutti wrote: > It's now documented in Library Reference 2.2 Non-essential > Built-in Functions. > Apparently it is no longer

Re: Python's "only one way to do it" philosophy isn't good?

2007-07-05 Thread Douglas Alan
"Chris Mellon" <[EMAIL PROTECTED]> writes: >> Some people here have been arguing that all code should use "with" to >> ensure that the files are closed. But this still wouldn't solve the >> problem of the large data structures being left around for an >> arbitrary amount of time. > I don't think

Re: Python's "only one way to do it" philosophy isn't good?

2007-07-06 Thread Douglas Alan
"Chris Mellon" <[EMAIL PROTECTED]> writes: > Sure, but thats part of the general refcounting vs GC argument - > refcounting gives (a certain level of) timeliness in resource > collection, GC often only runs under memory pressure. If you're > saying that we should keep refcounting because it provid

Re: Python's "only one way to do it" philosophy isn't good?

2007-07-09 Thread Douglas Alan
"Chris Mellon" <[EMAIL PROTECTED]> writes: >> And why would you do that? People rely very heavily in C++ on when >> destructors will be called, and they are in fact encouraged to do so. >> They are, in fact, encouraged to do so *so* much that constructs like >> "finally" and "with" have been reje

Re: Python's "only one way to do it" philosophy isn't good?

2007-07-09 Thread Douglas Alan
Steve Holden <[EMAIL PROTECTED]> writes: >> I'm relying on a feature that has worked fine since the early '90s, >> and if it is ever changed in the future, I'm sure that plenty of other >> language changes will come along with it that will make adapting code >> that relies on this feature to be th

bool behavior in Python 3000?

2007-07-10 Thread Alan Isaac
Is there any discussion of having real booleans in Python 3000? Say something along the line of the numpy implementation for arrays of type 'bool'? Hoping the bool type will be fixed will be fixed, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: allow scripts to use .pth files?

2007-07-10 Thread Alan Isaac
s the script > that wanted to import it. Right. > I'm curious whether you think that the OP's use of ".pth" was a typo, > and whether you have read this: > http://docs.python.org/lib/module-site.html You seem to understand what I'm getting at.

Re: The best platform and editor for Python

2007-07-10 Thread Douglas Alan
[EMAIL PROTECTED] (Alex Martelli) writes: > Kay Schluehr <[EMAIL PROTECTED]> wrote: >> half of the community is happy with Emacs and the other half wants to >> program in a VS-like environment, neither consensus nor progress has > Calling all vi/vim users (and we'll heartily appreciate the suppo

Re: bool behavior in Python 3000?

2007-07-10 Thread Alan Isaac
Stargaming wrote: > I think Bjoern just wanted to point out that all those binary > boolean operators already work *perfectly*. >>> bool(False-True) True But reread Steven. Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: bool behavior in Python 3000?

2007-07-10 Thread Alan Isaac
Bjoern Schliessmann wrote: > Is there any type named "bool" in standard Python? >>> type(True) Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: bool behavior in Python 3000?

2007-07-11 Thread Alan Isaac
ce of certain arguments, not proposing an implementation. Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: bool behavior in Python 3000?

2007-07-11 Thread Alan Isaac
arithmetic. I mentioned Python 3000 since that is an opportunity for an ideal world. Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: Fastest way to convert a byte of integer into a list

2007-07-12 Thread Alan Isaac
> On Jul 13, 9:54 am, Matimus <[EMAIL PROTECTED]> wrote: >>num = 255 >>numlist = [num >> i & 1 for i in range(8)] Godzilla wrote: > Thanks matimus! I will look into it... Watch out for the order, which might or might not match your intent. Cheers, Ala

Re: bool behavior in Python 3000?

2007-07-12 Thread Alan Isaac
> Alan Isaac skrev: >>http://www.python.org/dev/peps/pep-0285/ Nis Jørgensen wrote: > You forgot to quote this bit: [4)] Actually not. That is a different point. Ben seems bothered by this, but not me. I do not mind that True+1 is 2. I won't do it, but I do not object to it b

Re: comparison with None

2007-04-18 Thread Alan Isaac
so be true if None always compared greater than any object, and the current behavior does not seem to be guaranteed. Is that about right? Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: comparison with None

2007-04-18 Thread Alan Isaac
so be true if None always compared greater than any object, and the current behavior does not seem to be guaranteed. Is that about right? Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: comparison with None

2007-04-19 Thread Alan Isaac
"Steve Holden" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Steven Howe wrote: > > Alan Isaac wrote: [type comparison stuff] > > I love scripting languages ... but sometimes an explicit evaluation that > > one would find in > > a comp

Re: comparison with None

2007-04-19 Thread Alan Isaac
an error to compare > incomparable objects. Indeed, that was the basis of my original question. I wondered why no exception was raised. Thanks, Alan Isaac PS Note that the change you mention will conflict with currently documented behavior: "objects of different types always compare

gotcha or bug? random state reset on irrelevant import

2007-04-24 Thread Alan Isaac
Running test.py will print False. Is this expected/desirable? Thanks, Alan Isaac %%% test.py %%% from random import seed, getstate seed(217) x = getstate() from test2 import Trivial y = getstate() print x == y % test2.py % from random import seed seed(314) class

Re: gotcha or bug? random state reset on irrelevant import

2007-04-24 Thread Alan Isaac
ion is: is it a good design to only be able to use seed to set a global state? (See for contrast numpy.random, for which my appreciation has just increased yet again.) Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: gotcha or bug? random state reset on irrelevant import

2007-04-24 Thread Alan Isaac
"James Stroud" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > if __name__ == "__main__": >seed(314) Thanks for this suggestion. Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: gotcha or bug? random state reset on irrelevant import

2007-04-25 Thread Alan Isaac
an instantiate your own instances of Random to get generators that don't share state. Sheesh. I must have been asleep when reading the documentation. Thanks, Alan -- http://mail.python.org/mailman/listinfo/python-list

Re: Preferred Random Library

2007-04-26 Thread Alan Isaac
"Robert Kern" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > numpy.random does not implement jumpahead(). Which may be removed from the random API: http://www.python.org/dev/peps/pep-3100/#standard-library Cheers, Alan Isaac -- http://mail.python.org/mail

relative import problem

2007-04-27 Thread Alan Isaac
I'm new to relative imports and having a problem. (ValueError: Attempted relative import in non-package) I noticed this: http://www.thescripts.com/forum/thread549516.html Is this behavior intentional? I'm seeing it in Python 2.5.1. Thanks, Alan Isaac -- http://mail.python.org/mailma

relative import broken?

2007-04-28 Thread Alan Isaac
output:: Traceback (most recent call last): File "F:\temp\test1.py", line 1, in from . import test2 ValueError: Attempted relative import in non-package Why? Thanks, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: relative import broken?

2007-04-29 Thread Alan Isaac
, any module that I wish to make available for execution as a script (in the usual way, with a main function) cannot have any relative imports. Is this right? What is the reason for this restriction? (And where is it documented?) Thank you, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: relative import broken?

2007-04-30 Thread Alan Isaac
ss the package modules. That is, suppose I have directory ``mypackage`` with subdirectory ``scripts``. What is the pretty way for the scripts to access ``mypackage`` without assuming ``mypackage`` is in ``sys.path``? Thanks, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: relative import broken?

2007-05-01 Thread Alan Isaac
es, that seems to be the standard solution. I find it ugly. Anyway, I suppose my question remains: why are we constrained from solving this with a relative import? (And I suppose your answer will be: well then, relative to *what*? I am having trouble seeing why that answer cannot be giv

Re: relative import broken?

2007-05-01 Thread Alan Isaac
> "Alex Martelli" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > > I don't know of any "pretty" way -- I'd do it by path manipulation > > (finding mypackage from os.path.abspath(__file__) and inserting its > > _paren

Re: relative import broken?

2007-05-02 Thread Alan Isaac
a script when executed could not do imports relative to __file__. This seems like natural behavior to me. Thanks, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: Can I use Python instead of Joomla?

2007-05-02 Thread Alan Franzoni
u just download it, follow the instructions, plug in any pre-packed addon, and use it. You could probably do the very same with some of the Python CMSes around. Django is different: you must be able to program Python in order to use it. Nothing works from the beginning, since it's not a C

Re: relative import broken?

2007-05-03 Thread Alan Isaac
t; """ To change my question somewhat, can you give me an example where this behavior (when __name__ is '__main__') would be useful for a script? (I.e., more useful than importing relative to the directory holding the script, as indicated by __file__.) Thanks, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

change of random state when pyc created??

2007-05-04 Thread Alan Isaac
he shell. I get result1. I execute it again; I get result2. >From then on I get result2, unless I delete module.pyc again, in which case I once again get result1. Can someone explain this to me? Thank you, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: change of random state when pyc created??

2007-05-05 Thread Alan Isaac
unlikely. Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: change of random state when pyc created??

2007-05-05 Thread Alan Isaac
The files are not appropriate for posting. I do not yet have a "minimum" case. But surely I am not the first to notice this! Alan Isaac PS I'll send you the files off list. -- http://mail.python.org/mailman/listinfo/python-list

Re: change of random state when pyc created??

2007-05-05 Thread Alan Isaac
ully-pure module as a > script") I'm not going to call this a bad practice, since it has clear virtues. I will say that it does not seem to be a common practice, although that may be my lack of exposure to other's code. And it still does not address the common need of playing with a "package in progress" or a "package under consideration" without installing it. Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: change of random state when pyc created??

2007-05-07 Thread Alan Isaac
files. Explanation welcome!! Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: change of random state when pyc created??

2007-05-08 Thread Alan Isaac
outcome (result2) - the two outcomes are different (result1 != result2) Do you see something different than this if you run the test as I suggested? If not, how can in not involve the .pyc file (in some sense)? Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: change of random state when pyc created??

2007-05-09 Thread Alan Isaac
"Peter Otten" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Alan Isaac wrote: > There is nothing wrong with the random module -- you get the same numbers on > every run. When there is no pyc-file Python uses some RAM to create it and > therefore y

Re: change of random state when pyc created??

2007-05-09 Thread Alan Isaac
>> Robert Kern wrote: >>> http://docs.python.org/lib/typesmapping.html >>> """ >>> Keys and values are listed in an arbitrary order which is non-random, varies >>> across Python implementations, and depends on the dictionary's history

Re: change of random state when pyc created??

2007-05-09 Thread Alan Isaac
the same script give different objects by identity > and thus the "history of insertions and deletions" is different. OK. Thank you. Alan -- http://mail.python.org/mailman/listinfo/python-list

Re: change of random state when pyc created??

2007-05-09 Thread Alan Isaac
trary > order." If this wording is not present for sets, something to this > effect should be added. Even Robert did not claim that *that* phrase was adequate. I note that you cut off "which is non-random"! Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: change of random state when pyc created??

2007-05-09 Thread Alan Isaac
set.html: append a new sentence to 2nd paragraph Iteration over a set returns elements in an arbitrary order, which may depend on the memory location of the elements. fwiw, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: change of random state when pyc created??

2007-05-10 Thread Alan Isaac
>> Alan Isaac requested: >> http://docs.python.org/lib/typesmapping.html: to footnote (3), add phrase >> http://docs.python.org/lib/types-set.html: append a new sentence to 2nd paragraph "Hamilton, William " <[EMAIL PROTECTED]> wrote in message news:[EMAIL

vim e autoindentazione commenti

2007-05-11 Thread Alan Franzoni
a) questa aggiunta è automatica e la trovo molto, molto comoda. Dovrei andae a intaccare il file di indentazione? o quello di sintassi? -- Alan Franzoni <[EMAIL PROTECTED]> - Togli .xyz dalla mia email per contattarmi. Remove .xyz from my address in order to contact me. - GPG Key Fingerprint

Re: change of random state when pyc created??

2007-05-11 Thread Alan Isaac
d par. Iteration over a set returns elements in an indeterminate order, which generally depends on factors outside the scope of the containing program. Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: vim e autoindentazione commenti

2007-05-11 Thread Alan Franzoni
Il Fri, 11 May 2007 13:15:01 GMT, Neil Cerutti ha scritto: >:help format-comments > > (Spiacente per la mia scrittura difettosa. Sto utilizzando il > traduttore di altavista.) Really sorry ^_^ I thought I was posting in it.comp.lang.python Thank you BTW! -- Alan Franzoni <[

docs patch: dicts and sets

2007-05-11 Thread Alan Isaac
python.org/lib/types-set.html: append a new sentence to 2nd par. Iteration over a set returns elements in an indeterminate order,which generally depends on factors outside the scope of the containing program. Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-13 Thread Alan Franzoni
ibile encoding for any reader, a kind of translittering (is that a proper english word) system out-of-the-box, not requiring any other tool that's not included in the Python distro. This will let people to retain their usual working environments even though they're dealing with source code

docs patch: dicts and sets

2007-05-15 Thread Alan Isaac
the scope of the containing program. Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: docs patch: dicts and sets

2007-05-19 Thread Alan Isaac
I submitted the language based on Bill and Carsten's proposals: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1721372&group_id=5470 That language has been rejected. You many want to read the discussion and see if acceptible language still seems discoverable. Alan

Re: docs patch: dicts and sets

2007-05-20 Thread Alan Isaac
s surprised as I was. As I said, I am not attached to any language, and in fact I just used the proposals of others. I just wanted there to be some clue for users who read the docs. If you prefer to leave such users baffled, so be it. My effort is exhausted. Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: Basic Class/Instance Question

2007-05-23 Thread Alan Franzoni
7;shared' between all instances. If you don't want that, do something like: def __init__(self, defaultvalue=None): if defaultvalue is None: defaultvalue=[] http://docs.python.org/tut/node6.html#SECTION006710000 -- Alan Franzoni <[EMAIL PROTECTED

Re: Basic Class/Instance Question

2007-05-23 Thread Alan Franzoni
lt value of the function (which is part of the definition, not of the body) is a mutable object, because it's the very same default value that gets modified at each time. -- Alan Franzoni <[EMAIL PROTECTED]> - Togli .xyz dalla mia email per contattarmi. Remove .xyz from my address in

Re: c[:]()

2007-05-31 Thread Alan Franzoni
p() to achieve the very same result. Or you could define a function of your own like: def call_elems(iterable): for elem in iterable: elem() and just do call_elems(c) when needed. -- Alan Franzoni <[EMAIL PROTECTED]> - Togli .xyz dalla mia email per contattarmi.

Re: JPype - passing to Java main

2007-08-14 Thread Alan Kennedy
ut the signature for java main functions is public static void main (String [] args) So try com.JPypeTest.main(["arg"]) Note the addition of square brackets to create a *list* of arguments, which presumably jpype will transform into a java String[]. Alan. -- http://mail.python.org/mailman/listinfo/python-list

create Powerpoint via com

2007-08-30 Thread Alan Isaac
Can someone point me to a simple example or better yet tutorial for creating a Powerpoint using Python. Thanks, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: Please assist- Python Consultant needed for 3-6 month project

2007-08-30 Thread Alan Meyer
er with no specific experience in a particular language, and an average programmer with lots of experience, the good programmer will outperform the average one in any task lasting more than a couple of months. Of course I haven't always been able to convince managers of that. Alan --

Re: create Powerpoint via com

2007-08-30 Thread Alan Isaac
[EMAIL PROTECTED] wrote: > Hope that helps! Yes indeed. Thanks! Alan -- http://mail.python.org/mailman/listinfo/python-list

Re: create Powerpoint via com

2007-08-30 Thread Alan Isaac
[EMAIL PROTECTED] wrote: > OK, creating bulleted lists, or tables, or adding pictures is all straightforward. How about chart creation (in Ppt 2003)? I do not see how to do this with Python. Thanks, Alan -- http://mail.python.org/mailman/listinfo/python-list

Re: create Powerpoint via com

2007-08-31 Thread Alan Isaac
003-March/000839.html > http://www.thescripts.com/forum/thread21565.html > http://mathieu.fenniak.net/plotting-in-excel-through-pythoncom/ Thanks! Alan -- http://mail.python.org/mailman/listinfo/python-list

Re: create Powerpoint via com

2007-09-02 Thread Alan Isaac
Well, my needs were very limited so the result is too, but in case someone else just needs to get started: http://econpy.googlecode.com/svn/trunk/utilities/mso.py Comments, suggestions, additions welcom. Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: Any syntactic cleanup likely for Py3? And what about doc standards?

2007-09-05 Thread Alan Isaac
t pass a "self" > parameter to them. http://www.kylev.com/2004/10/13/fun-with-python-properties/ fwiw, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

announcement: OpenOpt and GenericOpt

2007-09-10 Thread Alan Isaac
cikits/browser/trunk/openopt/scikits/openopt/examples/lp_1.py>, MILP <http://projects.scipy.org/scipy/scikits/browser/trunk/openopt/scikits/openopt/examples/milp_1.py> Acknowledgements Development of OpenOpt was supported by Google through the Google Summer of Code

Re: Python Source Code Beautifier

2007-03-02 Thread Alan Franzoni
n.org/ref/augassign.html But... I don't know, still think it's confusing and not going to use it. -- Alan Franzoni <[EMAIL PROTECTED]> - Togli .xyz dalla mia email per contattarmi. Remove .xyz from my address in order to contact me. - GPG Key Fingerprint (Key ID = FE068F3E): 5C77 9DC3 BD5B 3A28 E7BC 921A 0255 42AA FE06 8F3E -- http://mail.python.org/mailman/listinfo/python-list

Re: Python Source Code Beautifier

2007-03-05 Thread Alan Franzoni
my own programs. At least, this is I what I think today; tomorrow, when I'm more experienced, I could think about them and say 'Hey! They're really cute, why haven't I used them before?' Bye! -- Alan Franzoni <[EMAIL PROTECTED]> - Togli .xyz dalla mia email pe

arenable in Python

2007-03-06 Thread Alan Isaac
Is the functionality of arenable http://sourceforge.net/projects/arenable/ available as a Python project? (It enables commenting features in Reader.) I am assuming the legitimacy of the arenable project. Correct me if I am wrong. Thanks, Alan Isaac -- http://mail.python.org/mailman/listinfo

Re: Python Source Code Beautifier

2007-03-07 Thread Alan Franzoni
hat I want to use in place of a list, to carefully craft an __iadd__ method which works just like the a list's own __iadd__ method; if I forget, I may introduce a subtle error. -- Alan Franzoni <[EMAIL PROTECTED]> - Togli .xyz dalla mia email per contattarmi. Remove .xyz from my add

Re: Python Source Code Beautifier

2007-03-08 Thread Alan Franzoni
I would agree it would be useful. But if there're such methods, do we really need this syntactic sugar to introduce confusion? -- Alan Franzoni <[EMAIL PROTECTED]> - Togli .xyz dalla mia email per contattarmi. Remove .xyz from my address in order to contact me. - GPG Key Fingerprint (Key ID = FE068F3E): 5C77 9DC3 BD5B 3A28 E7BC 921A 0255 42AA FE06 8F3E -- http://mail.python.org/mailman/listinfo/python-list

pylint: don't warn about tabs

2007-03-08 Thread Alan Isaac
I am brand new to pylint. As a tab user, I want the tabs warning turned off. How? Larger question: where is the config file format documented? Thanks, Alan Isaac PS This is a wonderful tool. -- http://mail.python.org/mailman/listinfo/python-list

Re: pylint: don't warn about tabs

2007-03-09 Thread Alan Isaac
entation. I have never seen this violated. Users of spaces cannot even count on shared code being 4 rather than 8 spaces. Even though tabs when on this score, face it, in the end it is pure preference. There is no "right" answer (even for emacs users). ;-) And my actual question r

Re: pylint: don't warn about tabs

2007-03-09 Thread Alan Isaac
> Alan Isaac wrote: > > I am brand new to pylint. > > As a tab user, I want the tabs warning turned off. "Robert Kern" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > doc/features.txt > examples/pylintrc The example is very helpful. Thanks! Alan

Re: pylint: don't warn about tabs

2007-03-09 Thread Alan Isaac
ad the PEP, which is making the opposite of your point. Cheers, Alan -- http://mail.python.org/mailman/listinfo/python-list

__init__ in subclass of tuple

2007-03-09 Thread Alan Isaac
st question: where should I have looked to answer these questions? Thanks, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: pylint: don't warn about tabs

2007-03-10 Thread Alan Isaac
> Alan: >> I really think you should reread the PEP, which is making >> the opposite of your point. Skip: > Quite the opposite, in fact. Laura Creighton wrote that > PEP precisely with the expectation (and hope) that Guido > would reject it, which he did: Note the title

Re: pylint: don't warn about tabs

2007-03-10 Thread Alan Isaac
> Alan: >> my actual question remains unanswered... Bjoern: > --indent-string or changing a config file doesn't work for you? Works great. (I read Robert's message subsequent to that complaint.) And pylint is wonderful. Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: __init__ in subclass of tuple

2007-03-10 Thread Alan Isaac
f > 'tuple' objects. Compare with: > py> tuple.__len__ > Thanks for that clue! Alan -- http://mail.python.org/mailman/listinfo/python-list

Putting Metaclasses to Work

2007-03-11 Thread Alan Isaac
Forman's book is out of print. Is there a good substitute? Thanks, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: python QT or python-GTK

2007-03-18 Thread Alan Franzoni
for their actual visual performance wherever they should be employed. Also, GTK+ seems to still need an X server on macosx (don't know about QT) Both have IDEs to create GUIs; take a look at Glade or Gazpacho for GTK+. Also, remember GTK+ is a community project while QT is a fully commercial p

design question: generator object with other attributes

2007-03-22 Thread Alan Isaac
the value the object get by calling the wrapped generator. A reasonable approach? Thanks, Alan Isaac PS Here is a useless class to illustrate the basic idea that you could have both attribute access and a generator-connected ``next`` method. class Start2Stop: def __init(start,stop

Re: tuples, index method, Python's design

2007-04-07 Thread Alan Isaac
e, where the fixed set p of players have a fixed order. A tuple is natural. Now for a player you want to construct the opponents. If I had the index i it wd be p[:i]+p[i+1:], but how to get the index? Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: tuples, index method, Python's design

2007-04-12 Thread Alan Isaac
at kind of a response is that?? This sounds to me like "I do not really see the point of immutability", which is no response at all. Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: tuples, index method, Python's design

2007-04-12 Thread Alan Isaac
;necessary"? The question is just whether we will be allowed to treat sequences that are naturally immutable as immutable or will be forced for no real reason (I believe the "code maintenance" issue has been dealt with) to treat them differently. Cheers, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

Re: tuples, index method, Python's design

2007-04-12 Thread Alan Isaac
"Terry Reedy" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > The main point of immutability is hashability by value (rather than by id). You are treating an effect as a cause. This is the main point *because* of an artifical constraint on tuples. Cheers, Al

Re: Several images onto one 2D-plot in matplotlib?

2007-04-12 Thread Alan Isaac
http://matplotlib.sourceforge.net/screenshots.html esp http://matplotlib.sourceforge.net/screenshots/axes_demo.py hth, Alan Isaac -- http://mail.python.org/mailman/listinfo/python-list

type compatibility warnings -- building python on windows 64-bit x64

2007-09-24 Thread nichols . alan
tsearch.h(57) : warning C4244: '=' : conversion from 'Py_ssize_t' to 'long', possible loss of data It's my understanding that the underlying type of the Py_ssize_t is 64- bit while ints and longs are 32-bit in VS 2005 -- hence the basis of the warnings. Can yo

Re: Top Programming Languages of 2013

2007-10-07 Thread Alan Gauld
given its not a programming language at all! Alan G. -- http://mail.python.org/mailman/listinfo/python-list

<    1   2   3   4   5   6   7   8   9   10   >