summaryrefslogtreecommitdiffstats
path: root/Lib
Commit message (Collapse)AuthorAgeFilesLines
* test_pickle works on sizeof(long)==8 boxes again.Tim Peters2001-04-101-11/+18
| | | | | | | | | | pickle.py The code implicitly assumed that all ints fit in 4 bytes, causing all sorts of mischief (from nonsense results to corrupted pickles). Repaired that. marshal.c The int marshaling code assumed that right shifts of signed longs sign-extend. Repaired that.
* Test full range of native ints. This exposes two more binary pickleTim Peters2001-04-101-0/+19
| | | | | | | | | bugs on sizeof(long)==8 machines. pickle.py has no idea what it's doing with very large ints, and variously gets things right by accident, computes nonsense, or generates corrupt pickles. cPickle fails on cases 2**31 <= i < 2**32: since it *thinks* those are 4-byte ints (the "high 4 bytes" are all zeroes), it stores them in the (signed!) BININT format, so they get unpickled as negative values.
* Mechanical fiddling for easier reading: every "if" test was enclosed inTim Peters2001-04-101-35/+35
| | | | parens, but no "while" test. Removed the former.
* Add globals to list of names returned by get_names().Jeremy Hylton2001-04-091-7/+13
| | | | | Fix func arg processing to handle args in tuples. In test code, skip names beginning with '.'.
* Pickles have a number of storage formats for various sizes and kinds ofTim Peters2001-04-091-13/+40
| | | | | | | | | integers, but the std tests don't exercise most of them. Repair that. CAUTION: I expect this to fail on boxes with sizeof(long)==8, in the part of test_cpickle (but not test_pickle) trying to do a binary mode (not text mode) load of the embedded BINDATA pickle string. Once that hypothesized failure is confirmed, I'll fix cPickle.c.
* No functional change -- just added whitespace in places so I could followTim Peters2001-04-091-11/+30
| | | | the logic better. Will be adding some additional tests later today.
* * Remove exc_info() kludge -- it actually messed up the Jython outputSteve Purcell2001-04-091-17/+13
| | | | | * Fixed TestLoader.loadTestsFromName() for nested packages * Corrected the command-line usage summary
* fixing 408085 - redirect from https becomes httpMoshe Zadka2001-04-091-1/+1
| | | | | | | | Even though relative redirects are illegal, they are common urllib treated every relative redirect as though it was to http, even if the original was https:// As long as we're compensating for server bugs, might as well do it properly.
* Add two arguments to Scope constructor, module scope and class nameJeremy Hylton2001-04-091-24/+92
| | | | | | | Add mangling support Add get_children() and add_child() methods to Scope Skip nodes when If test is a false constant Add test code that checks results against symtable module
* Add preliminary module symbol table constructorJeremy Hylton2001-04-091-0/+193
|
* remove global decl about unused variableJeremy Hylton2001-04-091-1/+0
|
* Add support for future statementsJeremy Hylton2001-04-092-6/+98
|
* Fix "import as" (has always skipping the as name)Jeremy Hylton2001-04-091-9/+15
| | | | | | Fix com_NEWLINE() so that is accepts arguments, which occurs for lines like: stmt; # note trailing semicolon Add XXX about checking for assignment to list comps
* typoJeremy Hylton2001-04-091-1/+1
|
* Make it clear that a bdb subclass must implement do_clear().Guido van Rossum2001-04-081-0/+3
| | | | This was found by Neal Norwitz's PyChecker.
* Whitespace normalization.Tim Peters2001-04-081-2/+2
|
* Fix from the Madusa mailing list:Tim Peters2001-04-081-1/+1
| | | | | | | | | | | | | | | | | http://groups.yahoo.com/group/medusa/message/333 It's clear that Medusa should not be checking for an empty buffer via "buf is ''". The patch merely changes "is" to "==". However, there's a mystery here all the same: Python attempts to store null strings uniquely, so it's unclear why "buf is ''" ever returned false when buf actually was empty. *Some* string operations produce non-unique null strings, e.g. >>> "abc"*0 is "abc"*0 0 >>> but they're rare, and I don't see any such operations in asynchat.
* Remove useless imports, as reported by PyChecker.Tim Peters2001-04-081-3/+0
|
* Get rid of useless string import, as reported by Neal Norwitz's PyChecker.pyTim Peters2001-04-081-1/+0
| | | | on c.l.py.
* Add an uninstall method to the ImportManager.Greg Stein2001-04-071-1/+9
| | | | This is the accepted portion of patch #402498.
* Since Guido fiddled Cookie.py to work with doctest, it's a Good Thing toTim Peters2001-04-062-0/+5
| | | | have the std test suite exercise the Cookie doctests too.
* Since this module already uses doctest-style examples, I figured I'dGuido van Rossum2001-04-061-4/+10
| | | | | | | | | | | | | | | add a self-test using doctest. Results: - The docstring needs to be a raw string because it uses \"...\". - The oreo example was broken: the Set-Cookie output doesn't add quotes around "doublestuff". - I had to change the example that prints the class of a Cookie.Cookie instance to avoid incorporating an arbitrary object address in the test output. Pretty good score for both doctest and the doc string, I'd say!
* Remove lines for asynchat & asyncore, as they've now got their own test.Tim Peters2001-04-061-2/+0
|
* After testing the test on Unix, several improvements:Guido van Rossum2001-04-061-3/+4
| | | | | | - Use push() instead of send(), and make these calls in main(). - Sleep a second to give the server thread time to initialize itself.
* Add test for asynchat. This also tests asyncore.Guido van Rossum2001-04-062-0/+58
|
* Make the docstring a raw string, for pydoc.Guido van Rossum2001-04-061-1/+1
| | | | (How many opre of these will we need? :-( )
* Fix the fix (my error -- hasty pasty).Tim Peters2001-04-051-1/+1
|
* One-liner critical fix from Jim Fulton: Eric's string-method crusadeTim Peters2001-04-051-1/+1
| | | | got the order backwards in a line (for .find()).
* Bug #412086, reported by Peter Wilson: The _curses module doesn'tAndrew M. Kuchling2001-04-051-0/+13
| | | | | | define COLORS or COLOR_PAIRS until after start_color() is called, but they were never added to the curses module. Fixed by adding a wrapper around start_color(), similar to the wrapper around initscr().
* Patch #413912 from Steve Majewski: Add .m to the list of extensionsAndrew M. Kuchling2001-04-051-1/+1
| | | | in order to support Objective-C.
* Corrected default value of the DocumentType.internalSubset attribute basedFred Drake2001-04-051-1/+1
| | | | on a clarification sent to the www-dom list.
* Sf bug [ #412214 ] ZipFile constructor leaves files open.Tim Peters2001-04-042-0/+30
| | | | | | This applies the patch Fred Drake created to fix it. I'm checking it in since I had to apply the patch anyway in order to test its behavior on Windows.
* CharacterData methods: Update self.length on changes instead of extendedFred Drake2001-04-041-4/+7
| | | | | | the __getattr__() handler. Text.splitText(): Update the length and nodeValue attributes.
* Add support for the CharacterData methods, CDATASection.Fred Drake2001-04-041-7/+73
|
* SF bug [#410708] Condition.wait() and KeyboardInterrupt.Tim Peters2001-04-021-23/+25
| | | | | | http://sourceforge.net/tracker/?func=detail&aid=410708&group_id=5470&atid=105470 Added try/finally around Condition.wait() guts, so that the lock state gets restored at the end no matter what happens.
* Initialize Attr.value with empty string in createAttribute*, as per DOMMartin v. Löwis2001-03-311-5/+7
| | | | | spec. Closes bug #412036. Also reindent toprettyxml.
* Back out the requirement to supply a version numberAndrew M. Kuchling2001-03-311-4/+0
|
* Fixes a fatal bug when the module has computed alternatives containing %s.Eric S. Raymond2001-03-311-1/+1
|
* Whitespace normalization.Tim Peters2001-03-297-23/+23
|
* Based on info from Jens@digicool.com, add 'darwin1' to the list ofGuido van Rossum2001-03-281-1/+1
| | | | BSD-style OS'es. Makes sense, really.
* Arghh. Fix typo.Martin v. Löwis2001-03-271-1/+1
|
* Use Guido's trick for always extracting the version number from aMartin v. Löwis2001-03-271-1/+4
| | | | CVS Revision string correctly, even under -kv.
* Fix some reloading problems (still more work needed).Ka-Ping Yee2001-03-271-6/+16
| | | | | Add hyperlinks to PEPs at http://www.python.org/peps/pep-%04d.html Remove script directory (dirname of sys.argv[0]) from sys.path.
* Itamar Shtull-Trauring <itamar@maxnm.com>:Fred Drake2001-03-262-18/+58
| | | | | Add support to zipfile to support opening an archive represented by an open file rather than a file name.
* Update auto-detection for Konqueror to include KDE 2 -- the kfm command isFred Drake2001-03-261-2/+5
| | | | | gone; "konqueror" is the new name, and the command-line args are different. kfmclient has not changed, though.
* main(): Application of SF patch #405851, which allows this test to beBarry Warsaw2001-03-231-0/+12
| | | | | | | used by Jython. The tests in this module expect C locale, so be explicit about setting that (for CPython). However, in Jython, there is no C locale, so instead be explicit about setting the US locale. Closes the patch.
* In Jython, `@' is not allowed in module names. Extend the TESTFN testBarry Warsaw2001-03-231-3/+7
| | | | to use "$test" when in Jython. Closes SF patch #403668.
* Two minor changes for better Jython compatibility. Finn Bock says:Barry Warsaw2001-03-231-3/+3
| | | | | | | | | | | | | Change 1: Not all 'modules' in sys.modules have a sensible __file__ attribute. Some of our java package can have the __file__ attribute set to None. Change 2: In jython we have the jython license file in <root> and the CPython license file in <root>/Lib. By reversing the search sequence jython will find and show the jython license file before the CPython file. Closes SF patch #405853.
* Make socket.getservbyname test optional on socket module having thatBarry Warsaw2001-03-231-5/+6
| | | | | | attribute. Jython does not have this function. Closes SF patch #403667.
* Change rfc822_escape() to ensure there's a consistent amount of whitespaceAndrew M. Kuchling2001-03-231-3/+4
| | | | | after each newline, instead of just blindly inserting a space at the start of each line. (Improvement suggested by Thomas Wouters)