[Python-Dev] pychecker warnings in Lib/encodings

2006-06-13 Thread Neal Norwitz
All are missing parameters. I'm not sure of the proper signature, so I didn't fix these: Lib/encodings/punycode.py:217: No global (errors) found Lib/encodings/utf_8_sig.py:33: No global (errors) found Lib/encodings/uu_codec.py:109: No global (errors) found IIUC (and I probably don't), mbcs is on

Re: [Python-Dev] crash in dict on gc collect

2006-06-13 Thread Neal Norwitz
On 6/13/06, Thomas Wouters <[EMAIL PROTECTED]> wrote: > > > The source fo the crash is the EncodingMap type (defined in > unicodeobject.c); it has an invalid type: > > Breakpoint 2, PyUnicode_BuildEncodingMap (string=0x2b97d44dbf40) > at Objects/unicodeobject.c:3213 > (gdb) print EncodingMapTyp

Re: [Python-Dev] pychecker warnings in Lib/encodings

2006-06-14 Thread Neal Norwitz
On 6/13/06, Walter Dörwald <[EMAIL PROTECTED]> wrote: > > > IIUC (and I probably don't), mbcs is on windows only. But should I be > > able to import encodings.mbcs on Linux or is this expected? > > > import encodings.mbcs > > Traceback (most recent call last): > > File "", line 1, in > >

Re: [Python-Dev] Keeping interned strings in a set

2006-06-15 Thread Neal Norwitz
On 6/15/06, Alexander Belopolsky <[EMAIL PROTECTED]> wrote: > As an exercise in using the new set C API, I've replaced the > "interned" dictionary in stringobject.c with a set. > > If there is any interest, I will submit a patch, but it does not seem > to affect performance in any meaningful way.

Re: [Python-Dev] Beta 1 schedule ? (Bug in stringobject?)

2006-06-16 Thread Neal Norwitz
On 6/16/06, M.-A. Lemburg <[EMAIL PROTECTED]> wrote: > Fredrik Lundh wrote: > > > > what's the beta 1 status ? fixing this should be trivial, but I don't have > > any > > cycles to spare today. > > Good question. PEP 356 says beta 1 was planned two days > ago... > > http://www.python.org/dev/peps

Re: [Python-Dev] Adding winerror module (Beta 1 schedule ?)

2006-06-18 Thread Neal Norwitz
On 6/18/06, M.-A. Lemburg <[EMAIL PROTECTED]> wrote: > Anthony Baxter wrote: > >> I'd also like to get the new winerror module in before > >> beta1 is released - documentation will follow next week: > > > > Hm. A new python module should be OK - but I was under the impression > > that then large pi

Re: [Python-Dev] Numerical robustness, IEEE etc.

2006-06-18 Thread Neal Norwitz
You should be aware of PEP 754 and address it. http://www.python.org/dev/peps/pep-0754/ Also note that Python conforms to C89, not C99. Any solution should work on all Python platforms. Some of those platforms are here: http://www.python.org/dev/buildbot/all/ n -- On 6/18/06, Brett Cannon <[E

Re: [Python-Dev] Dropping externally maintained packages (Was: Please stop changing wsgiref on the trunk)

2006-06-18 Thread Neal Norwitz
On 6/12/06, Greg Ward <[EMAIL PROTECTED]> wrote: > [Guido] > > While I am an enthusiastic supporter of several of those additions, I > > am *not* in favor of the special status granted to software > > contributed by certain developers, since it is a burden for all other > > developers. > > [Martin]

Re: [Python-Dev] setobject code

2006-06-18 Thread Neal Norwitz
On 6/16/06, Alexander Belopolsky <[EMAIL PROTECTED]> wrote: > I would like to share a couple of observations that I made as I > studied the latest setobject implementation. ... > 2. Type of several data members in dict-object and dict-entry structs > were recently changed to Py_ssize_t . Whatever

[Python-Dev] current 2.5 issues

2006-06-18 Thread Neal Norwitz
valgrind reports a problem when running test_doctest. I haven't spotted a problem with the code, but the report is consistent (hmm, I thought there were 3 warnings, but now there's only 1): ==19291== Conditional jump or move depends on uninitialised value(s) ==19291==at 0x49D8B5: maybe_call_l

Re: [Python-Dev] beta1 coming real soon

2006-06-19 Thread Neal Norwitz
On 6/19/06, Trent Mick <[EMAIL PROTECTED]> wrote: > Trent Mick wrote: > > Trent Mick wrote: > >> * [ 1462338 ] upgrade pyexpat to expat 2.0.0 > >>http://python.org/sf/1462338 > >> > >> * [ 1295808 ] expat symbols should be namespaced in pyexpat > >>http://python.org/sf/1295808 > > > > These

[Python-Dev] Things to remember when adding *packages* to stdlib

2006-06-21 Thread Neal Norwitz
I believe this change is all that's necessary on the Unix side to install wsgiref. Can someone please update the Windows build files to ensure wsgiref is installed in b2? Don't forget to update the NEWS entry too. Also, all committers and reviewers, try to remember that when a package (meaning d

Re: [Python-Dev] Numerical robustness, IEEE etc.

2006-06-22 Thread Neal Norwitz
On 6/22/06, Aahz <[EMAIL PROTECTED]> wrote: > On Thu, Jun 22, 2006, Nick Maclaren wrote: > > > > Sigh. What I am trying to get is floating-point support of the form > > that, when a programmer makes a numerical error (see above), he gets > > EITHER an exception value returned OR an exception raise

Re: [Python-Dev] [Python-checkins] Things to remember when adding *packages* to stdlib

2006-06-26 Thread Neal Norwitz
On 6/25/06, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > Neal Norwitz wrote: > > I believe this change is all that's necessary on the Unix side to > > install wsgiref. Can someone please update the Windows build files to > > ensure wsgiref is install

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-27 Thread Neal Norwitz
On 6/27/06, Brett Cannon <[EMAIL PROTECTED]> wrote: > > > (5) I think file creation/writing should be capped rather than > > binary; it is reasonable to say "You can create a single temp file up > > to 4K" or "You can create files, but not more than 20Meg total". > > That has been suggested before

[Python-Dev] 2.5 and beyond

2006-06-30 Thread Neal Norwitz
I'm glad to see Anthony ratcheting down. At this point, we need to be fixing bugs and improving doc. Maybe Anthony and I should have a contest to see who can revert the most changes. :-) There are at least 6 bugs that really, really need to be fixed before release. Several of these are AST bugs

Re: [Python-Dev] Pickle implementation questions

2006-06-30 Thread Neal Norwitz
Please do help us improve the docs. Patches are the best (most likely to be applied the fastest), bug reports are welcome too. Especially when they contain your preferred wording in the text. n -- On 6/30/06, Bruce Christensen <[EMAIL PROTECTED]> wrote: > Fredrik Lundh wrote: > > on the other h

Re: [Python-Dev] zlib module build failure on Mac OSX 10.4.7

2006-06-30 Thread Neal Norwitz
Maybe do a make distclean. There was a problem where old versions of zlib (those without inflateCopy) weren't supported. They are now, but it's a configure check. That coupled with the upgrade and the 10.3 in the pathname, seems like it's just something didn't get cleaned up properly. You could

Re: [Python-Dev] zlib module build failure on Mac OSX 10.4.7

2006-07-04 Thread Neal Norwitz
Ronald, Bob, I know Skip found and fixed his problem, however, is this problem likely to affect other users? Is there anything we can do to help alleviate/diagnose this problem? n -- On 7/1/06, Ronald Oussoren <[EMAIL PROTECTED]> wrote: > > On Jul 1, 2006, at 8:46 PM, Martin v. Löwis wrote: > >

[Python-Dev] User's complaints

2006-07-04 Thread Neal Norwitz
On 7/4/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > From actual users of > the language I get more complaints about the breakneck speed of > Python's evolution than about the brokenness of the current language. Guido, I'm really interested in your perspective here. I assume you hear far

Re: [Python-Dev] 2.5 and beyond

2006-07-05 Thread Neal Norwitz
On 7/4/06, Thomas Heller <[EMAIL PROTECTED]> wrote: > > I would like to ask about the possibility to add some improvements to ctypes > in Python 2.5, although the feature freeze is now in effect. Hopefully former > third-party libraries can have the freeze relaxed somewhat;-). Ok, former third-pa

[Python-Dev] import screwiness

2006-07-05 Thread Neal Norwitz
In import.c starting around line 1210 (I removed a bunch of code that doesn't matter for the problem): if (PyUnicode_Check(v)) { copy = PyUnicode_Encode(PyUnicode_AS_UNICODE(v), PyUnicode_GET_SIZE(v), Py_FileSystemDefaultEncod

Re: [Python-Dev] import screwiness

2006-07-05 Thread Neal Norwitz
On 7/5/06, Tim Peters <[EMAIL PROTECTED]> wrote: > > > Then later on we do PyString_GET_SIZE and PyString_AS_STRING. That doesn't > > work, does it? What am I missing? > > The conceptual type of the object returned by PyUnicode_Encode(). Phew, I sure am glad I was missing that. :-) I saw as th

Re: [Python-Dev] 2.5 and beyond

2006-07-07 Thread Neal Norwitz
On 6/30/06, Jean-Paul Calderone <[EMAIL PROTECTED]> wrote: > > > >There are at least 6 bugs that really, really need to be fixed before > >release. Several of these are AST bugs. Jeremy knows about them and > >plans to fix them once he's back from vacation. Anyone else wanna > >help out? One is

Re: [Python-Dev] Python 3 design principles

2005-08-31 Thread Neal Norwitz
On 8/31/05, Oren Tirosh <[EMAIL PROTECTED]> wrote: > > Writing programs that run on both 2.x and 3 may require ugly > version-dependent tricks like: > > try: > compile > except NameError: > from sys import compile Note we can ease this process a little by making a copy without removing,

[Python-Dev] import exceptions

2005-08-31 Thread Neal Norwitz
Is there any reason to import exceptions? It's only done in 4 places: Lib/asyncore.py, Lib/shutil.py, Lib/idlelib/PyShell.py, and Lib/test/test_exceptions.py. I can understand the one in test, but should the other 3 be removed since exceptions are builtin? n _

Re: [Python-Dev] Replacement for print in Python 3.0

2005-09-02 Thread Neal Norwitz
On 9/2/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > Nope, but there is a large body of code out there that does use print > statements already. Again, I know you're prepared for breakage, but that > doesn't necessarily mean a completely blank sheet of paper. Ideally I very much prefer th

[Python-Dev] gdbinit problem

2005-09-04 Thread Neal Norwitz
break in gdbinit is apparently does not break a loop, but rather sets a break point. I don't know how to hit the break within lineno with a simple test case. Debugging pychecker with a C extension (matplotlib) triggers it. The only way I could see to fix it was by setting a continue flag and tes

[Python-Dev] speeding up list append calls

2005-09-13 Thread Neal Norwitz
Tim made me do it! http://groups.google.com/group/comp.lang.python/msg/9075a3bc59c334c9 For whatever reason, I was just curious how his code could be sped up. I kept seeing this append method being called and I thought, "there's an opcode for that." What happens if you replace var.append() wi

Re: [Python-Dev] [Python-checkins] python/dist/src/Lib/test regrtest.py, 1.171, 1.172 test_ioctl.py, 1.2, 1.3

2005-09-14 Thread Neal Norwitz
> Index: test_ioctl.py > === > RCS file: /cvsroot/python/python/dist/src/Lib/test/test_ioctl.py,v > retrieving revision 1.2 > retrieving revision 1.3 > diff -u -d -r1.2 -r1.3 > --- test_ioctl.py 20 Mar 2003 04:33:16 - 1.

Re: [Python-Dev] Compatibility between Python 2.3.x and Python 2.4.x

2005-09-15 Thread Neal Norwitz
On 9/15/05, Rich Burridge <[EMAIL PROTECTED]> wrote: > > Hi, > > I'm involved with the team that's working towards installing Python 2.4.x > as part of a future release of the Solaris O/S. Cool. I would like to hear more about what you are doing. > We currently have Python 2.3.x installed. We

Re: [Python-Dev] IMPORTANT: 2.4.2c1 Wednesday, 21st September - branch will be closed for a week.

2005-09-15 Thread Neal Norwitz
On 9/15/05, Anthony Baxter <[EMAIL PROTECTED]> wrote: > So we'll be cutting the 2.4.2 release candidate on Wednesday the 21st > (next week). Can people please make sure they are running the test > suite fully for any checkins between now and then? Also, please > consider the release24-maint branch

[Python-Dev] possible memory leak on windows (valgrind report)

2005-09-19 Thread Neal Norwitz
I ran 2.4.x through valgrind and found two small problems on Linux that have been fixed. There may be some other issues which could benefit from more eyes (small, probably one time memory leaks). The entire run is here: http://python.org/valgrind-2.4.2.out (I need to write a lot more suppressio

Re: [Python-Dev] possible memory leak on windows (valgrind report)

2005-09-19 Thread Neal Norwitz
On 9/19/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > That patch doesn't make sense to me -- the "s" code to > PyArg_ParseTuple doesn't return newly allocated memory, it just > returns a pointer into a string object that is owned by the caller > (really by the call machinery I suppose). Comp

Re: [Python-Dev] possible memory leak on windows (valgrind report)

2005-09-21 Thread Neal Norwitz
On 9/21/05, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > Neal Norwitz wrote: > > (I need to write a lot more suppression rules for gentoo.) > > This could be due to your using GCC 4. Apparently, gcc 4 > is willing to inline Py_ADDRESS_IN_RANGE even though it &g

Re: [Python-Dev] Conditional Expression Resolution

2005-09-29 Thread Neal Norwitz
On 9/29/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > Flames, pleas to reconsider, etc., to /dev/null. > > Congratulations gracefully accepted. > > It's still my language! :-) I don't like those options. :-) How about this: Can someone update the PEP on conditional expressions to point to

Re: [Python-Dev] [PATCH][BUG] Segmentation Fault in xml.dom.minidom.parse

2005-09-29 Thread Neal Norwitz
On 9/29/05, Evan Jones <[EMAIL PROTECTED]> wrote: > > Any chance that someone wants to commit this tiny two line fix? That's reallly not the question you *want* to be asking. :-) > This might be the kind of fix that might be elegible to be backported to > Python 2.4 as well. It passes "make test

Re: [Python-Dev] Removing the block stack (was Re: PEP 343 and __with__)

2005-10-05 Thread Neal Norwitz
On 10/5/05, Phillip J. Eby <[EMAIL PROTECTED]> wrote: > At 09:50 AM 10/4/2005 +0100, Michael Hudson wrote: > >(anyone still thinking about removing the block stack?). > > I'm not any more. My thought was that it would be good for performance, by > reducing the memory allocation overhead for frames

Re: [Python-Dev] test_cmd_line failure on Kubuntu 5.10 with GCC 4.0

2005-10-08 Thread Neal Norwitz
On 10/8/05, Nick Coghlan <[EMAIL PROTECTED]> wrote: > Hye-Shik Chang wrote: > > On 10/8/05, Nick Coghlan <[EMAIL PROTECTED]> wrote: > > > >>Anyone else seeing any problems with test_cmd_line? I've got a few failures > >>in > >>test_cmd_line on Kubuntu 5.10 with GCC 4.0 relating to a missing "\n" l

[Python-Dev] problem with genexp

2005-10-10 Thread Neal Norwitz
There's a problem with genexp's that I think really needs to get fixed. See http://python.org/sf/1167751 the details are below. This code: >>> foo(a = i for i in range(10)) generates "NameError: name 'i' is not defined" when run because: 2 0 LOAD_GLOBAL 0 (foo)

Re: [Python-Dev] problem with genexp

2005-10-10 Thread Neal Norwitz
On 10/10/05, Brett Cannon <[EMAIL PROTECTED]> wrote: > On 10/10/05, Neal Norwitz <[EMAIL PROTECTED]> wrote: > > There's a problem with genexp's that I think really needs to get > > fixed. See http://python.org/sf/1167751 the details are below. This > >

Re: [Python-Dev] AST branch update

2005-10-14 Thread Neal Norwitz
On 10/13/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > Indeed. I should've threatened to kill the AST branch long ago! :) :-) I decreased a lot of the memory leaks. Here are some more to work on. I doubt this list is complete, but it's a start: PyObject_Malloc (obmalloc.c:717) _PyObject_

Re: [Python-Dev] AST branch update

2005-10-14 Thread Neal Norwitz
On 10/14/05, Neal Norwitz <[EMAIL PROTECTED]> wrote: > > I decreased a lot of the memory leaks. Here are some more to work on. > I doubt this list is complete, but it's a start: Oh and since I fixed the memory leaks in a generated file Python/Python-ast.c, the chan

[Python-Dev] Guido v. Python, Round 1

2005-10-16 Thread Neal Norwitz
We all know Guido likes Python. But the real question is do pythons like Guido? http://python.org/neal/ n ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailma

Re: [Python-Dev] problem with genexp

2005-10-16 Thread Neal Norwitz
On 10/10/05, Neal Norwitz <[EMAIL PROTECTED]> wrote: > There's a problem with genexp's that I think really needs to get > fixed. See http://python.org/sf/1167751 the details are below. This > code: > > >>> foo(a = i for i in range(10)) > > I agree w

Re: [Python-Dev] Guido v. Python, Round 1

2005-10-17 Thread Neal Norwitz
On 10/17/05, Tim Peters <[EMAIL PROTECTED]> wrote: [Skip]> Like Steve (and unlike Oleg), I get 404s for this page.  I also tried> "www.python.org" and "~neal".The original http://python.org/neal/ worked fine for me, and still does.  OTOH, http://www.python.org/neal/gets a 404, and (the orig

Re: [Python-Dev] AST branch is in?

2005-10-20 Thread Neal Norwitz
On 10/20/05, Anthony Baxter <[EMAIL PROTECTED]> wrote: > > Could someone involved give a short email laying out what concrete (no > pun intended) advantages this new compiler gives us? Does it just > allow us to do new and interesting manipulations of the code during > compilation? Cleaner, easier

[Python-Dev] Questionable AST wibbles

2005-10-20 Thread Neal Norwitz
Jeremy, There are a bunch of mods from the AST branch that got integrated into head. Hopefully, by doing this on python-dev more people will get involved. I'll describe high level things first, but there will be a ton of details later on. If people don't want to see this crap on python-dev, I

Re: [Python-Dev] problem with genexp

2005-10-20 Thread Neal Norwitz
On 10/16/05, Neal Norwitz <[EMAIL PROTECTED]> wrote: > On 10/10/05, Neal Norwitz <[EMAIL PROTECTED]> wrote: > > There's a problem with genexp's that I think really needs to get > > fixed. See http://python.org/sf/1167751 the details are below. This > >

Re: [Python-Dev] python-dev sprint at PyCon

2005-11-01 Thread Neal Norwitz
On 11/1/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > On 11/1/05, Phillip J. Eby <[EMAIL PROTECTED]> wrote: > > At 09:35 AM 11/1/2005 -0500, A.M. Kuchling wrote: > > >Every PyCon has featured a python-dev sprint. For the past few years, > > >hacking on the AST branch has been a tradition, but

Re: [Python-Dev] python-dev sprint at PyCon

2005-11-01 Thread Neal Norwitz
On 11/1/05, Phillip J. Eby <[EMAIL PROTECTED]> wrote: > At 11:14 AM 11/1/2005 -0700, Guido van Rossum wrote: > >I guess this ought to be recorded. :-( > > > >The issue has been beaten to death and my position remains firm: > >rather than playing namespace games, consistent renaming is the right > >

Re: [Python-Dev] python-dev sprint at PyCon

2005-11-02 Thread Neal Norwitz
On 11/1/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > This is just a comment from the peanut gallery, as it's highly unlikely I'll > be in attendance, but why not continue with the AST theme? Instead of > working on the AST branch, you could start to propagate the AST > representation aroun

[Python-Dev] cross-compiling

2005-11-07 Thread Neal Norwitz
We've been having some issues and discussions at work about cross compiling. There are various people that have tried (are) cross compiling python. Right now the support kinda sucks due to a couple of reasons. First, distutils is required to build all the modules. This means that python must be

[Python-Dev] ast status, memory leaks, etc

2005-11-13 Thread Neal Norwitz
There's still more clean up work to go, but the current AST is hopefully much closer to the behaviour before it was checked in. There are still a few small memory leaks. After running the test suite, the total references were around 380k (down from over 1,000k). I'm not sure exactly what the tot

Re: [Python-Dev] Memory management in the AST parser & compiler

2005-11-15 Thread Neal Norwitz
On 11/15/05, Jeremy Hylton <[EMAIL PROTECTED]> wrote: > > Thanks for the message. I was going to suggest the same thing. I > think it's primarily a question of how to add an arena layer. The AST > phase has a mixture of malloc/free and Python object allocation. It > should be straightforward to

Re: [Python-Dev] Problems with the Python Memory Manager

2005-11-16 Thread Neal Norwitz
On 11/16/05, Travis Oliphant <[EMAIL PROTECTED]> wrote: > > As verified by removing usage of the Python PyObject_MALLOC function, it > was the Python memory manager that was performing poorly. Even though > the array-scalar objects were deleted, the memory manager would not > re-use their memory

Re: [Python-Dev] ast status, memory leaks, etc

2005-11-19 Thread Neal Norwitz
I lied a bit in my previous status. I said that the refs used at the end of a regression test run from a clean state (*) were down to 380k. Well if I had remembered to remove all the .pyc's this would have been true. Here's the numbers now: Before AST: r39757 [362766 refs] Before AST: svn up [3

Re: [Python-Dev] ast status, memory leaks, etc

2005-11-20 Thread Neal Norwitz
On 11/20/05, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > > Can somebody please give a quick explanation how valgrind can give > *any* reasonable leak analysis when obmalloc is used? In the current > implementation, obmalloc never ever calls free(3), so all pool memory > should appear to have lea

Re: [Python-Dev] ast status, memory leaks, etc

2005-11-20 Thread Neal Norwitz
I would really like it if someone could run Purify (or another memory tool) on Windows. Purify on any another (unix) platform would be nice, but I doubt it will show much more. By using different tools, problems not found by one tool may be found by the other. Plus there is windows specific code

Re: [Python-Dev] ast status, memory leaks, etc

2005-11-21 Thread Neal Norwitz
On 11/21/05, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > > sounds like the PSF should buy you some more RAM. I think I still have some allocation from the PSF. Wanna have a party. ;-) Seriously, I don't know that more RAM would help too much. I didn't notice much swapping, but maybe if I had run

Re: [Python-Dev] ast status, memory leaks, etc

2005-11-21 Thread Neal Norwitz
On 11/21/05, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > > I don't think there's a shortage of Windows boxes among the python-dev > crowd (I have plenty). Does anyone knows that kind of box you need to > run purify these days ? Dunno, but it would probably be fine on a reasonably new box with at l

[Python-Dev] Fwd: [Python-checkins] commit of r41497 - python/trunk/Lib/test

2005-11-21 Thread Neal Norwitz
I just checked in the modification below. I'm not sure if this behaviour is on purpose or by accident. Do we want to support hex values in floats? Do we want to support p, similar to e in floats? Here are the lines from the test: +self.assertEqual(float(" 0x3.1 "), 3.0625) +

Re: [Python-Dev] ast status, memory leaks, etc

2005-11-22 Thread Neal Norwitz
On 11/22/05, Amaury Forgeot d'Arc <[EMAIL PROTECTED]> wrote: > Hello, > > Purify is not so difficult to use: just run and learn to read the output ;-) Amaury, Thank you for running Purify. > 1 - Memory error in test_coding, while importing bad_coding.py : > IPR: Invalid pointer read in tok_nextc

Re: [Python-Dev] a Python interface for the AST (WAS: DRAFT: python-dev...)

2005-11-22 Thread Neal Norwitz
On 11/22/05, Brett Cannon <[EMAIL PROTECTED]> wrote: > > But if I had my way I think that having all AST objects be PyObjects > and then providing support for all three ways of getting access to the > AST (command-line, sys iterable, function for specific code object) > would be fantastic. There n

[Python-Dev] registering unicode codecs

2005-11-24 Thread Neal Norwitz
While running regrtest with -R to find reference leaks I found a usage issue. When a codec is registered it is stored in the interpreter state and cannot be removed. Since it is stored as a list, if you repeated add the same search function, you will get duplicates in the list and they can't be r

Re: [Python-Dev] registering unicode codecs

2005-11-24 Thread Neal Norwitz
On 11/24/05, M.-A. Lemburg <[EMAIL PROTECTED]> wrote: > > > Should users have access to the search path (through a > > codecs.unregister())? > > Maybe, but why would you want to unregister a search function ? > > > If so, should it search from the end of the > > list to the beginning to remove an i

[Python-Dev] reference leaks

2005-11-24 Thread Neal Norwitz
There are still a few reference leaks I've been able to identify. I didn't see an obvious solution to these (well, I saw one obvious solution which crashed, so obviously I was wrong). When running regrtest with -R here are the ref leaks reported: test_codeccallbacks leaked [2, 2, 2, 2] reference

Re: [Python-Dev] reference leaks

2005-11-25 Thread Neal Norwitz
On 11/25/05, Walter Dörwald <[EMAIL PROTECTED]> wrote: > > Can you move the call to codecs.register_error() out of test_callbacks() > and retry? It then leaks 3 refs on each call to test_callbacks(). n -- >>> import codecs [24540 refs] >>> [24541 refs] >>> def handler(exc): ... l = [u"<%d>" %

Re: [Python-Dev] Memory management in the AST parser & compiler

2005-11-28 Thread Neal Norwitz
On 11/28/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > I guess I don't understand the AST compiler code enough to participate > in this discussion. I hope everyone while chime in here. This is important to improve and learn from others. Let me try to describe the current situation with a s

Re: [Python-Dev] Memory management in the AST parser & compiler

2005-11-28 Thread Neal Norwitz
On 11/28/05, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > Neal Norwitz wrote: > > Hope this helps explain a bit. Please speak up with how this can be > > improved. Gotta run. > > I would rewrite it as [code snipped] For those watching, Greg's

Re: [Python-Dev] Memory management in the AST parser & compiler

2005-11-29 Thread Neal Norwitz
On 11/29/05, Nick Coghlan <[EMAIL PROTECTED]> wrote: > > When working on the CST->AST parser, there were only a few things I found to > be seriously painful about the memory management: > >1. Remembering which free_* variant to call for AST nodes >2. Remembering which asdl_seq_*_free varian

Re: [Python-Dev] Memory management in the AST parser & compiler

2005-11-29 Thread Neal Norwitz
On 11/28/05, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > Neal Norwitz wrote: > > For those watching, Greg's and Martin's version were almost the same. > > However, Greg's version left in the memory leak, while Martin fixed it > > by lett

Re: [Python-Dev] Memory management in the AST parser & compiler

2005-11-30 Thread Neal Norwitz
On 11/30/05, Thomas Lee <[EMAIL PROTECTED]> wrote: > > Quick semi-related question: where are the marshal_* functions called? > They're all static in Python-ast.c and don't seem to be actually called > anywhere. Can we ditch them? I *think* they are not necessary. My guess is that they were there

Re: [Python-Dev] Memory management in the AST parser & compiler

2005-11-30 Thread Neal Norwitz
On 11/30/05, Neil Schemenauer <[EMAIL PROTECTED]> wrote: > Thomas Lee <[EMAIL PROTECTED]> wrote: > > Quick semi-related question: where are the marshal_* functions called? > > They're all static in Python-ast.c and don't seem to be actually called > > anywhere. Can we ditch them? > > They are inten

Re: [Python-Dev] ast-objects branch created

2005-11-30 Thread Neal Norwitz
On 11/30/05, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > > The bigger chunk of necessary changes is in using these, starting > with ast.c. I got a few more files to compile. The following files (all under Python/) need some loving care and are looking for a kind soul to adopt them: ast.c, c

Re: [Python-Dev] PyAST_FromNode returning PyTypeObject* ?

2005-12-01 Thread Neal Norwitz
On 12/1/05, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > Neal, > > Why did you suggest that PyAST_FromNode returns PyTypeObject*? > I can't see why type objects are much used in the AST, unless > I'm missing something essential. It was late and I was trying to make progress. Assume it was a mis

Re: [Python-Dev] ast-objects branch created

2005-12-01 Thread Neal Norwitz
On 12/1/05, Jeremy Hylton <[EMAIL PROTECTED]> wrote: > Martin, > > I'm not sure what your intent for this work is, but I'd like to create > a parallel arena branch and compare the results. I'll start work on > that tomorrow. I think this is a good thing. It will be much easier to compare impleme

Re: [Python-Dev] ast-objects branch created

2005-12-05 Thread Neal Norwitz
On 12/5/05, Jeremy Hylton <[EMAIL PROTECTED]> wrote: > On 12/5/05, James Y Knight <[EMAIL PROTECTED]> wrote: > > > > ISTM that having to remember which pointers are arena-allocated and > > which are normally-refcounted-allocated removes the major gain that > > an arena method is supposed to bring:

Re: [Python-Dev] Deprecate __ private (was Re: PEP 8 updates/clarifications)

2005-12-11 Thread Neal Norwitz
On 12/11/05, Jim Fulton <[EMAIL PROTECTED]> wrote: > > Can we officially mark __private as a mistake. Perhaps: > > - Strongly discourage it in the style guide This may be acceptable. > - Mark it in the language reference as a deprecated feature > > - Generate deprecation warnings when it is used?

[Python-Dev] __builtin__ vs __builtins__

2005-12-12 Thread Neal Norwitz
Below is Guido's response to my question: Can we start getting rid of __builtins__ (or __builtin__) at least for py3k? Having both builtin versions is confusing, how can we improve the situation? n -- Forwarded message -- From: Guido van Rossum <[EMAIL PROTECTED]> Couple of loo

Re: [Python-Dev] [Python-checkins] commit of r41497 -python/trunk/Lib/test

2005-12-17 Thread Neal Norwitz
On 11/21/05, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > Neal Norwitz wrote: > > > I just checked in the modification below. I'm not sure if this > > behaviour is on purpose or by accident. [ /f shows diff on linux and windows ] I checked in a fix for this so float(

[Python-Dev] ref leak in element tree/pyexpat

2005-12-17 Thread Neal Norwitz
I'm not sure where the problem is, but this code leaks a reference: parser = ET.XMLParser() ; parser.feed('text') You need this to set it up: from xmlcore.etree import cElementTree as ET This isn't a memory leak according to valgrind. Also, I noticed several places where errors where being

[Python-Dev] [OT] Fwd: a new python port: iPod

2005-12-20 Thread Neal Norwitz
I know this is OT, but I thought y'all might find this interesting. -- n -- Forwarded message -- From: jack <[EMAIL PROTECTED]> To: [EMAIL PROTECTED] Hi, I saw in http://www.python.org/download/download_other.html that people notify python ports to other platforms/devices. I po

Re: [Python-Dev] documentation comments

2005-12-22 Thread Neal Norwitz
On 12/22/05, A.M. Kuchling <[EMAIL PROTECTED]> wrote: > > I had lunch with Fred the other day, and he was worried about whether > anyone would garden the comments to remove spam. I would help assuming this is easy--meaning a single click to remove a comment. n

Re: [Python-Dev] Patch reviews & request for patch review

2005-12-23 Thread Neal Norwitz
On 12/5/05, John J Lee <[EMAIL PROTECTED]> wrote: > > I'm hoping one of those nice people who offered 'review 5 get 1 free' > might look at a patch of mine. Oooh, ooh, do I count?!? (Well, you can drop the nice part. :-) > http://python.org/sf/1157027 Checked in to 2.5. > http://python.org/sf/

Re: [Python-Dev] status of development documentation

2005-12-23 Thread Neal Norwitz
On 12/23/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > So for at least the time being they go up nightly > (http://www.trentm.com/python). I don't know what Trent did to make that > happen, but he did it fairly quickly. I doubt it would be hard to replicate > on the docs server. I couldn'

Re: [Python-Dev] status of development documentation

2005-12-23 Thread Neal Norwitz
On 12/23/05, Tim Peters <[EMAIL PROTECTED]> wrote: > > > > http://docs.python.org/dev/results/ > > Wow! You get no test failures! I guess nobody tests on Windows > anymore. I've been getting test failures for months, and just Hmmm, I thought others were running the tests on Windows too. Th

Re: [Python-Dev] status of development documentation

2005-12-24 Thread Neal Norwitz
On 12/24/05, Tim Peters <[EMAIL PROTECTED]> wrote: > You're asking a Windows guy about make: bad career move ;-) :-) > -uall is helpful in finding bugs. One thing in particular here is > that test_compiler runs only a tiny subset of its full test unless an > appropriate -u flag is given. Not

Re: [Python-Dev] [Python-checkins] commit of r41880 - python/trunk/Python/Python-ast.c

2006-01-02 Thread Neal Norwitz
On 1/2/06, Barry Warsaw <[EMAIL PROTECTED]> wrote: > I think we have a fundamental problem with Python-ast.c and > Python-ast.h. These files should not be both auto-generated and checked > into Subversion. I agree with the problem statement. > The general rule should be that no file that is ever

[Python-Dev] buildbot

2006-01-02 Thread Neal Norwitz
Here's some info on setting up buildbot . These instructions should be cleaned up and put in the developers faq. Right now, the only person that can generate/assign buildbot names/passwords is Martin AFAIK. We currently have 4 slaves setup: Linux: x86 and a

[Python-Dev] current test problems

2006-01-02 Thread Neal Norwitz
test_bsddb3 fails for me with BSD DB 4.1 and 4.2 on gentoo Linux. I think it has for a long time. Is anyone else seeing these failures? You must use -u bsddb when running regrtest. 4.2 has 2 failures: test02_associateAfterDB (bsddb.test.test_associate.ShelveAssociateRecnoTestCase) test02_a

[Python-Dev] automated builds and tests

2006-01-02 Thread Neal Norwitz
I've updated the script that builds python and the docs, runs the tests, and copies everything up to docs.python.org. Currently, this only works for the trunk. I'm not sure if there's much of a benefit to set this up for branch(es) also. The docs are here: http://docs.python.org/dev/ The resu

Re: [Python-Dev] buildbot

2006-01-02 Thread Neal Norwitz
On 1/2/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > The G5 *was* working. I changed nothing at my end. Got a mail yesterday > from Martin. It looks like PATH lost /usr/local/bin (where the Metissian > installer puts the svn executable). I added a /usr/bin/svn symlink, but > would really

[Python-Dev] mac memory leaks

2006-01-02 Thread Neal Norwitz
I had a friend run regrtest -L on Mac OSX a while ago. There are several memory leaks which still appear to be an issue. There are a bunch of leaks reported from putenv which I'm not sure how to fix The attached patch should correct one of the problems. Can someone with a Mac test it? I'll ad

Re: [Python-Dev] Including zlib...

2006-01-03 Thread Neal Norwitz
Hear, hear. Er On 1/3/06, Tim Peters <[EMAIL PROTECTED]> wrote: > [Guido] > > OK. As long a typical Unix build still links with whatever shared zlib > > is present on the box I'm fine with this. > > [Guido] > >>> Hear, hear. > > [Skip] > ... > > [Tim] > ... > I figure that if we keep this con

Re: [Python-Dev] slight inconsistency in svn checkin email subject lines

2006-01-03 Thread Neal Norwitz
On 1/3/06, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > > I tried to, but couldn't. I'll be sending the mailer.py and mailer.conf > files in a private mail. I can't see anything wrong in that code. > > Perhaps mailman is adding the spaces? I looked into this briefly. I saw something like: if p

[Python-Dev] bsddb broken

2006-01-05 Thread Neal Norwitz
Anyone wanna give bsddb some tlc? Head and 2.4 work with 4.2 on amd64 and x86. Neither python version works when using BSD db 4.1 or 3.2. I don't know anything about bsddb, so any help fixing this would be appreciated. In 4.1 it seems associate doesn't work. http://python.org/sf/1332873 3.2

Re: [Python-Dev] New PEP: Using ssize_t as the index type

2006-01-06 Thread Neal Norwitz
On 1/6/06, Michael Urman <[EMAIL PROTECTED]> wrote: > > I put together a non-parsing checker last month to help me feel more > secure after http://python.org/sf/1365916. It's awful code, but the > simple things are easy to change or extend. Fixing the false positives > and other misinterpretations

[Python-Dev] Checking in a broken test was: Re: [Python-checkins] r41940 - python/trunk/Lib/test/test_compiler.py

2006-01-07 Thread Neal Norwitz
[moving to python-dev] > On 1/7/06, Reinhold Birkenfeld <[EMAIL PROTECTED]> wrote: > > Well, it is not the test that's broken... it's compiler. [In reference to: http://mail.python.org/pipermail/python-checkins/2006-January/048715.html] In the past, we haven't checked in tests which are known to

Re: [Python-Dev] Compiler warnings for 64-bit portability problems

2006-01-07 Thread Neal Norwitz
On 1/6/06, von Löwis Martin <[EMAIL PROTECTED]> wrote: > I just found that the intel compiler (icc 9.0) > also supports compiler warnings for portability > problems. Cool. Thanks for the info. It would be nice if Intel would provide Python developers with a permanent icc license for Python. Can

<    1   2   3   4   5   6   >