Raymond Hettinger
c8b6d1bd8c
Make functional.partial() more closely match the spec by emulating
...
some useful features of regular functions:
* Made weak referencable.
* Allow attribute access so a user can set __name__, __doc__, etc.
2005-03-08 06:14:50 +00:00
Greg Ward
50682d0f78
SF #818006 : merge from release24-maint branch: add useful read-only
...
attributes to oss_audio_device object: 'closed', 'name', and 'mode'.
2005-03-07 01:41:11 +00:00
Martin v. Löwis
78be7df9e4
Patch #918101 : Add tarfile open mode r|* for auto-detection of the
...
stream compression; add, for symmetry reasons, r:* as a synonym of r.
2005-03-05 12:47:42 +00:00
Brett Cannon
653a5adcca
Tweak test_communicate_stderr so that it works when run under a pydebug build.
2005-03-05 06:40:52 +00:00
Brett Cannon
1bfd85b612
Remove some more tab usage to prevent an error when run as ``python -tt``.
2005-03-05 05:32:14 +00:00
Brett Cannon
3304a14148
Remove a tab so that whitespace usage is consistent.
2005-03-05 05:28:45 +00:00
Greg Ward
40407943b7
SF #1149508 : ensure textwrap handles hyphenated numbers correctly,
...
eg. "2004-03-04" is not broken across lines. (Merged from 2.4 branch.)
2005-03-05 02:53:17 +00:00
Martin v. Löwis
00a73e7715
Patch #1043890 : tarfile: add extractall() method.
2005-03-04 19:40:34 +00:00
Martin v. Löwis
c72dd38f30
Patch #1075887 : Don't require MSVC in distutils if there is nothing
...
to build. Will backport to 2.4
2005-03-04 13:50:17 +00:00
Martin v. Löwis
637431bf14
Patch #1103407 : Properly deal with tarfile iterators when untarring
...
symbolic links on Windows. Fixes #1100429 . Will backport to 2.4.
2005-03-03 23:12:42 +00:00
Peter Astrand
7e78ade6f9
Corrected bug in list2cmdline wrt backslashes. Fixes #1083306 .
2005-03-03 21:10:23 +00:00
Peter Astrand
f7f1bb7ff5
Only run extensive subprocess tests if -usubprocess to regrtest is specified. Fixes #1124637
2005-03-03 20:47:37 +00:00
Peter Astrand
23109f0009
Optimization for communicate(): If only one of stdin/stdout/stderr is
...
redirected, using select() or threads is unnecessary.
2005-03-03 20:28:59 +00:00
Peter Astrand
cbac93c229
Added three more testcases: Using communicate with only one of
...
stdin/stdout/stderr redirected.
2005-03-03 20:24:28 +00:00
Raymond Hettinger
b67cc80bb9
SF bug #1155938 : Missing None check for __init__().
2005-03-03 16:45:19 +00:00
Martin v. Löwis
6ce7ed23d0
Revert previous checkin on getargs 'L' code. Try to convert all
...
numbers in PyLong_AsLongLong, and update test suite accordingly.
Backported to 2.4.
2005-03-03 12:26:35 +00:00
Martin v. Löwis
a4dac4094a
Patch #645894 : Use getrusage for computing the time consumption in
...
profile.py if available.
2005-03-03 11:39:45 +00:00
Martin v. Löwis
7fe60c0a0a
Patches #749830 , #1144555 : allow UNIX mmap size to default to current
...
file size.
2005-03-03 11:22:44 +00:00
Martin v. Löwis
df37c8c1ad
Patch #1046831 : Use get_python_version where appropriate in sysconfig.py.
2005-03-03 11:08:03 +00:00
Martin v. Löwis
c5574e809b
Patch #1117454 : Remove code to special-case cookies without values
...
in LWPCookieJar. Backported to 2.4.
2005-03-03 10:57:37 +00:00
Martin v. Löwis
4ea3eade51
Patch #1117339 : Add cookielib special name tests.
...
Backported to 2.4.
2005-03-03 10:48:12 +00:00
Martin v. Löwis
e869eb1953
Patch #1112812 : Make bsddb/__init__.py more friendly for modulefinder.
...
Backported to 2.4.
2005-03-03 09:46:07 +00:00
Martin v. Löwis
ff232d7230
Clear internal call error in 'L' format. Fixes #723201 .
...
Backported to 2.4.
2005-03-03 09:24:38 +00:00
Martin v. Löwis
f2a8d63e4f
Patch #1110248 : SYNC_FLUSH the zlib buffer for GZipFile.flush.
...
Partially fixes #1110242 .
2005-03-03 08:35:22 +00:00
Martin v. Löwis
df24153f65
Patch #1107973 : tarfile.ExFileObject iterators.
2005-03-03 08:17:42 +00:00
Martin v. Löwis
8ed338ab44
Patch #1104111 : Alter setup.py --help and --help-commands.
2005-03-03 08:12:27 +00:00
Piers Lauder
8659d909d3
Fix bug in InternalDate regexp that failed to allow leading 0 in day - courtesy of Rimon Barr <rimon.barr@cornell.edu>
2005-03-02 09:13:45 +00:00
Martin v. Löwis
4afe154369
Patch #1121234 : Properly cleanup _exit and tkerror commands.
...
Will backport to 2.4.
2005-03-01 08:09:28 +00:00
Brett Cannon
e94e74a8e1
Make test__locale more fine-grained. Now test localeconv and nl_langinfo
...
individually as tests.
Also improved output when the test fails.
2005-03-01 03:15:50 +00:00
Brett Cannon
46b0802ccd
Fix small grammatical error in a docstring.
2005-03-01 03:12:26 +00:00
Raymond Hettinger
9c323f8de4
SF patch #941881 : PEP 309 Implementation (Partial Function Application).
...
Combined efforts of many including Peter Harris, Hye-Shik Chang,
Martin v. Löwis, Nick Coghlan, Paul Moore, and Raymond Hettinger.
2005-02-28 19:39:44 +00:00
Raymond Hettinger
049ade2997
Complete the previous effort to factor out constant expressions
...
and improve the speed of the if/elif/else blocks.
2005-02-28 19:27:52 +00:00
Martin v. Löwis
c2a0ac20b7
Patch #1049151 : adding bool support to xdrlib.py.
...
Also add xdrlib._test into the test suite.
2005-02-24 20:22:10 +00:00
Peter Astrand
c26516b29d
Made the module compatible with Python 2.2 again.
2005-02-21 08:13:02 +00:00
Raymond Hettinger
afd842f5b2
Teach the peepholer to fold unary operations on constants.
...
Afterwards, -0.5 loads in a single step and no longer requires a runtime
UNARY_NEGATIVE operation.
2005-02-20 12:46:54 +00:00
Raymond Hettinger
57e7447c44
* Beef-up tests for str.count().
...
* Speed-up str.count() by using memchr() to fly between first char matches.
2005-02-20 09:54:53 +00:00
Raymond Hettinger
7cbf1bcb3e
* Beef-up testing of str.__contains__() and str.find().
...
* Speed-up "x in y" where x has more than one character.
The existing code made excessive calls to the expensive memcmp() function.
The new code uses memchr() to rapidly find a start point for memcmp().
In addition to knowing that the first character is a match, the new code
also checks that the last character is a match. This significantly reduces
the incidence of false starts (saving memcmp() calls and making quadratic
behavior less likely).
Improves the timings on:
python -m timeit -r7 -s"x='a'*1000" "'ab' in x"
python -m timeit -r7 -s"x='a'*1000" "'bc' in x"
Once this code has proven itself, then string_find_internal() should refer
to it rather than running its own version. Also, something similar may
apply to unicode objects.
2005-02-20 04:07:08 +00:00
Ka-Ping Yee
bba6acc714
Use getdoc(object) instead of object.__doc__ to fix indentation problems.
...
Thanks to Robert Dick <dickrp@ece.northwestern.edu> for reporting this bug
and submitting a patch.
Adjust doc(object) to display useful documentation for plain values (e.g.
help([]) now shows the methods on the list instead of just printing "[]").
(This change has been tested interactively, by generating docs for the
standard library, and by running the module documentation webserver.)
2005-02-19 22:58:26 +00:00
Walter Dörwald
af3b39a182
Add support for negative indices in UserString.MutableString.__setitem__
...
and UserString.MutableString.__delitem__.
2005-02-18 13:22:43 +00:00
Vinay Sajip
612df8e21d
Handle errors in imports of thread, threading
2005-02-18 11:54:46 +00:00
Vinay Sajip
829dc51a05
Improved frame handling for 1.5.2, and now return func from findCaller (not actually used yet)
2005-02-18 11:53:32 +00:00
Walter Dörwald
1fd4db9c6c
Fix copy & paste error.
2005-02-17 22:31:28 +00:00
Walter Dörwald
7f79152929
Add tests for the methods added by UserString.MutableString.
2005-02-17 22:03:31 +00:00
Martin v. Löwis
5510f65f5a
Avoid using items() in environ.update(). Fixes #1124513 .
...
Will backport to 2.4.
2005-02-17 21:23:20 +00:00
Walter Dörwald
3040b19976
Add a basic test for UserString.MutableString.
2005-02-17 18:51:48 +00:00
Michael W. Hudson
ee319f66ab
Fix
...
[ 1124295 ] Function's __name__ no longer accessible in restricted mode
which I introduced with a bit of mindless copy-paste when making
__name__ writable. You can't assign to __name__ in restricted mode,
which I'm going to pretend was intentional :)
2005-02-17 10:37:21 +00:00
Raymond Hettinger
2ca7c190b6
Remove dependency on order of mode flags
2005-02-16 09:27:49 +00:00
Tim Peters
f0db38dbf8
Whitespace normalization.
2005-02-15 21:50:12 +00:00
Tim Peters
90718a4eb5
An instance of class PicklingError was used here simply as an example of
...
_some_ user-defined class instance. That it was also an exception isn't
interesting, but does interfere with Michael Hudson's new-style exception
patch. This just changes the doctest example, to use an instance of a
non-exception class.
2005-02-15 16:22:34 +00:00
Michael W. Hudson
f058858347
Test that SystemExits are handled properly by the exit machinery. I
...
broke the "raise SystemExit(46)" case when doing new-style exceptions,
but I'd much rather have found out here than in test_tempfile (growl).
2005-02-15 15:26:11 +00:00
Michael W. Hudson
a1fb4c891f
Exceedingly minor tweak.
2005-02-15 15:22:37 +00:00
Peter Astrand
69bf13f1e8
Added copyright notice:
...
Licensed to PSF under a Contributor Agreement.
2005-02-14 08:56:32 +00:00
Fred Drake
22c0706a58
fix decoding in _stringify to not depend on the default encoding
...
(closes SF bug #1115989 )
2005-02-11 17:59:08 +00:00
Brett Cannon
64d904b715
Remove set conversion optimization test (backed out of Python/compile.c in rev.
...
2.344).
2005-02-10 20:40:29 +00:00
Fred Drake
ba613c3410
accept datetime.datetime instances when marshalling;
...
dateTime.iso8601 elements still unmarshal into xmlrpclib.DateTime objects
2005-02-10 18:33:30 +00:00
Andrew M. Kuchling
bfd7d6a0ea
Fix typo
2005-02-10 13:24:50 +00:00
Peter Astrand
d38ddf4ca2
Patch from Leandro Lucarella: replaced:
...
var == None and var != None
with
var is None and var is not None
and type(var) == int
with
instanceof(var, int)
...as recomended in PEP 8 [1].
2005-02-10 08:32:50 +00:00
Raymond Hettinger
508e81eda0
Convert splitlines to for-loop (handles case where input does not have a trailing newline).
2005-02-08 15:39:11 +00:00
Walter Dörwald
a9620d1e2b
Fix stupid typo: Don't read from a writer.
2005-02-08 10:10:01 +00:00
Raymond Hettinger
bb5fbc4af9
Wholistic code cleanup / modernization:
...
* Use +=
* Replace loop logic with str.splitlines equivalent
* Don't use variable names that shadow tuple, list, and str
* Use dict.get instead of equivalent try/except
* Minor loop logic simplications
2005-02-08 08:05:13 +00:00
Raymond Hettinger
7fcb7869ba
Adopt Skip's idea to optimize lists of constants in the context
...
of a "in" or "not in" test.
2005-02-07 19:32:38 +00:00
Raymond Hettinger
fe59dc1bd8
Revert previous checkin.
2005-02-07 15:28:45 +00:00
Raymond Hettinger
f715366f23
Reduce the usage of the types module.
2005-02-07 14:16:21 +00:00
Raymond Hettinger
a164574937
Transform "x in (1,2,3)" to "x in frozenset([1,2,3])".
...
Inspired by Skip's idea to recognize the throw-away nature of sequences
in this context and to transform their type to one with better performance.
2005-02-06 22:05:42 +00:00
Raymond Hettinger
dbecd93b72
Replace list of constants with tuples of constants.
2005-02-06 06:57:08 +00:00
Raymond Hettinger
f7bf02ded5
SF patch #1028908
...
(John J Lee)
Minor code clarification and simplification.
2005-02-05 14:37:06 +00:00
Raymond Hettinger
bab4143348
SF patch #1116583 : NameError in cookielib domain check
2005-02-05 01:31:19 +00:00
Walter Dörwald
1f1d252f51
Add a test for UTF-16 reading where the byte sequence doesn't start with
...
a BOM.
2005-02-04 14:15:34 +00:00
Thomas Heller
07561b3b8e
Recompiled after source changes.
2005-02-03 20:48:26 +00:00
Fred Drake
e4772f3ada
fix XMLFilterBase.resolveEntity() so the caller gets the result
...
(PyXML bug #1112052 )
2005-02-03 17:31:39 +00:00
Guido van Rossum
d064142579
Security fix PSF-2005-001 for SimpleXMLRPCServer.py.
2005-02-03 15:01:24 +00:00
Kurt B. Kaiser
0676dfdce0
Add config-main.def option to make the 'history' feature non-cyclic.
...
Default remains cyclic. Python Patch 914546 Noam Raphael.
M IdleHistory.py
M NEWS.txt
M config-main.def
2005-02-03 01:37:14 +00:00
Steve Holden
69b8caa23a
Simplify string comparison using startswith()
2005-02-02 18:47:18 +00:00
Kurt B. Kaiser
acdef858a5
Removed ability to configure tabs indent from Options dialog. This 'feature'
...
has never worked and no one has complained. It is still possible to set a
default tabs (v. spaces) indent 'manually' via config-main.def (or to turn on
tabs for the current EditorWindow via the Format menu) but IDLE will encourage
indentation via spaces.
Enable setting the indentation width using the Options dialog.
Bug # 783877
Remove some commented out old code from configDialog.py (related to old
methods for invoking the HelpBrowser).
M EditorWindow.py
M NEWS.txt
M configHandler.py
2005-01-31 03:34:26 +00:00
Martin v. Löwis
1d11de6dbd
Revert os.py 1.75, and directly implement update.
...
Fixes #1110478 and #1100235 .
2005-01-29 13:29:23 +00:00
Kurt B. Kaiser
3069dbb8ec
Add keybindings for del-word-left and del-word-right.
...
M EditorWindow.py
M NEWS.txt
M config-keys.def
M configHandler.py
2005-01-28 00:16:16 +00:00
Brett Cannon
90cece7f89
Fixed typo in verbose output.
...
Closes bug #1110998 . Thanks Matthew Bogosian.
2005-01-27 22:48:30 +00:00
Raymond Hettinger
9feb267caf
Do not fold a constant if a large sequence will result.
...
Saves space in the presence of code like: (None,)*10000
2005-01-26 12:50:05 +00:00
Johannes Gijsbers
926d45bb4e
shutil.copytree: move copystat call for the directory after the loop
...
copying files inside the directory, as that loop changes the atime and
mtime.
2005-01-23 12:20:15 +00:00
Martin v. Löwis
4d394dfebb
Truncate st_?time before comparing it with ST_?TIME in the tests.
2005-01-23 09:19:22 +00:00
Walter Dörwald
1083c248df
Add a slice test with high < low.
2005-01-21 21:16:51 +00:00
Thomas Heller
1d1eac3ce8
Fix [ 1103844 ] fix distutils.install.dump_dirs() with negated options.
...
Will backport myself.
2005-01-20 19:14:17 +00:00
Kurt B. Kaiser
6af4498602
1. Polish tabbing code.
...
2. Restore use of set_indentation_params(), was dead code since
Autoindent.py was merged into EditorWindow.py.
3. Make usetabs, indentwidth, tabwidth, context_use_ps1 instance vars
and set in EditorWindow.__init__()
4. In PyShell.__init__() set usetabs, indentwidth and context_use_ps1
explicitly (config() is eliminated).
5. Add Tabnanny check when Module is Run/F5, not just when Checked.
6. Discourage using an indent width other than 8 when using tabs to
indent Python code.
M EditorWindow.py
M NEWS.txt
M PyShell.py
M ScriptBinding.py
2005-01-19 00:22:59 +00:00
Kurt B. Kaiser
b00e89faab
If an extension can't be loaded, print warning and skip it instead of
...
erroring out.
2005-01-18 00:54:58 +00:00
Skip Montanaro
891a1ba3b2
allow triple-quoted string output from reconvert.quote()
2005-01-16 19:31:40 +00:00
Johannes Gijsbers
5954623bc0
Patch #1100140 : improved smtp connect debugging
...
Don't print the same (host, port) tuple thrice when debugging, but first print
(host, port), then (ip, port) and then the error message.
2005-01-16 13:04:30 +00:00
Martin v. Löwis
22b457e03b
Added SEEK_* constants. Fixes #711830 .
2005-01-16 08:40:58 +00:00
Guido van Rossum
5a8a03784e
Use descriptors.
2005-01-16 00:25:31 +00:00
Guido van Rossum
fee7b93c60
Use decorators.
2005-01-16 00:21:28 +00:00
Guido van Rossum
75b64e65f1
Use decorators.
2005-01-16 00:16:11 +00:00
Tim Peters
608c2fff69
Whitespace normalization.
2005-01-13 17:37:38 +00:00
Vinay Sajip
a1974c1459
Improved SysLogHandler error recovery (patch by Erik Forsberg)
2005-01-13 08:23:56 +00:00
Skip Montanaro
0af3ade6aa
Add strptime() constructor to datetime class. Thanks to Josh Spoerri for
...
the changes.
2005-01-13 04:12:31 +00:00
Andrew McNamara
7f2053eff3
Add counting of source iterator lines to the reader object - handy for
...
user error messages (otherwise difficult to do without instrumenting
the source).
2005-01-12 11:17:16 +00:00
Andrew McNamara
0f0599ddc1
When quoting=QUOTE_NONNUMERIC, the reader now casts unquoted fields
...
to floats.
2005-01-12 09:45:18 +00:00
Andrew McNamara
5d45a8dc22
Fix logic problem in quoting=csv.QUOTE_ALL, quotechar=None check, add test.
2005-01-12 08:16:17 +00:00
Andrew McNamara
c89f284df8
When using QUOTE_NONNUMERIC, we now test for "numericness" with
...
PyNumber_Check, rather than trying to convert to a float. Reimplemented
writer - now raises exceptions when it sees a quotechar but neither
doublequote or escapechar are set. Doublequote results are now more
consistent (eg, single quote should generate """", rather than "",
which is ambiguous).
2005-01-12 07:44:42 +00:00
Andrew McNamara
31d8896ee2
Rename csv.set_field_limit to csv.field_size_limit (since it both sets and
...
gets).
2005-01-12 03:45:10 +00:00
Andrew McNamara
af1e312b3b
Improve test coverage fractionally.
2005-01-12 01:55:21 +00:00
Kurt B. Kaiser
1b6f398c98
Improve error handling when .idlerc can't be created.
2005-01-11 19:29:39 +00:00
Raymond Hettinger
faa10ebdd0
SF bug #1099516 : tempfile files not types.FileType
...
Clarified that the returned object is file-like rather than an actual file.
2005-01-11 15:33:03 +00:00
Andrew McNamara
e4d05c4f93
Set an upper limit on the size of the field buffer, raise an exception
...
when this limit is reached. Limit defaults to 128k, and is changed
by module set_field_limit() method. Previously, an unmatched quote
character could result in the entire file being read into the field
buffer, potentially exhausting virtual memory.
2005-01-11 07:32:02 +00:00
Raymond Hettinger
a422c34b70
SF 1098985: set objects cannot be marshalled
2005-01-11 03:03:27 +00:00
Andrew McNamara
7130ff5eb9
Replace python-coded validation of csv dialect with a call to the C
...
dialect type (which has a better idea of what is and isn't valid).
2005-01-11 02:22:47 +00:00
Andrew McNamara
8c94b42f31
No longer attempt to instantiate python classes describing dialects. This
...
was done because we were previously performing validation of the dialect
from python, but this is now down within the C module. Also, the method
we were using to detect classes did not work with new-style classes.
2005-01-11 02:18:36 +00:00
Andrew McNamara
86625972a1
Allow dialect-describing keywords to be supplied to register_dialect,
...
record objects of internal dialect type, rather than instances of
python objects.
2005-01-11 01:28:33 +00:00
Tim Peters
b497c106d5
Whitespace normalization.
2005-01-10 16:48:37 +00:00
Walter Dörwald
9fa0946771
Fix and test for SF bug #1098990 : codec readline() splits lines apart.
2005-01-10 12:01:39 +00:00
Johannes Gijsbers
c0b194a770
Bug #489256 : remove out of date and out of place profile.doc, and let
...
profile.help() point at the library reference instead of profile.doc.
2005-01-10 09:07:22 +00:00
Andrew McNamara
36a7691c2d
Fix parsing of csv files with escapes (escape character previously would be
...
left in stream).
2005-01-10 01:04:40 +00:00
Johannes Gijsbers
41e4faa82b
Patch #712317 : In URLs such as http://www.example.com?query=spam , treat '?' as
...
a delimiter. Previously, the 'network location' (<authority> in RFC 2396) would
become 'www.example.com?query=spam', while RFC 2396 does not allow a '?' in
<authority>. See bug #548176 for further discussion.
2005-01-09 15:29:10 +00:00
Johannes Gijsbers
cdd625a770
Patch #1095362 : replace hardcoded test for POST/GET with call to get_method,
...
removing some duplication and gaining some flexibility in the process.
2005-01-09 05:51:49 +00:00
Johannes Gijsbers
2abe785fee
Move code in __name__ == '__main__' block into main() function, rewrite code so
...
there's no need to subclass OptionParser.
2005-01-09 01:58:02 +00:00
Johannes Gijsbers
9ddb300598
Patch #936774 : unify the display of data descriptors, including slots,
...
properties, and custom descriptors.
* removed special handling of properties
* added special handling of data descriptors - All data descriptors are grouped
together in a section. For each item, the attribute name and doc string, if
present, is displayed.
* disabled display of __slots__ attribute - since slots are descriptors, they
are listed in the section described above
Thanks to John Belmonte for the patch!
2005-01-08 20:16:43 +00:00
Johannes Gijsbers
9a98364ba3
Replace rfc822.parseaddr with email.Utils.parseaddr. The implementation is
...
still the same, so there should be no backwards-compatibility problems.
2005-01-08 14:12:27 +00:00
Johannes Gijsbers
c7fc10a418
Patch #1079734 : remove dependencies on (deprecated) rfc822 and mimetools
...
modules, replacing with email. Thanks to Josh Hoyt for the patch!
2005-01-08 13:56:36 +00:00
Johannes Gijsbers
a3beee185c
Clean up tests by reusing functions from other modules:
...
* replace deltree with shutil.rmtree()
* replace mkdirs with os.makedirs()
* fold touchfile into GlobTests.mktemp()
2005-01-08 13:28:54 +00:00
Johannes Gijsbers
836f5433f7
Patch #943206 :
...
`glob.glob()` currently calls itself recursively to build a list of matches of
the dirname part of the pattern and then filters by the basename part. This is
effectively BFS. ``glob.glob('*/*/*/*/*/foo')`` will build a huge list of all
directories 5 levels deep even if only a handful of them contain a ``foo``
entry. A generator-based recusion would never have to store these list at once
by implementing DFS. This patch converts the `glob` function to an `iglob`
recursive generator . `glob()` now just returns ``list(iglob(pattern))``.
I also cleaned up the code a bit (reduced duplicate `has_magic()` checks and
created a second `glob0` helper func so that the main loop need not be
duplicated).
Thanks to Cherniavsky Beni for the patch!
2005-01-08 13:13:19 +00:00
Johannes Gijsbers
e4172eadf3
Patch #1094015 :
...
* Use os.makedirs() instead os.mkdir(). (bug #975763 )
* Use copystat() to copy directory bits (bug #1048878 )
2005-01-08 12:31:29 +00:00
Tim Peters
711906e0c2
threading._DummyThread.__init__(): document obscure new code.
...
test_threading.test_foreign_thread(): new test does a basic check that
"foreign" threads can using the threading module, and that they create
a _DummyThread instance in at least one use case. This isn't a very
good test, since a thread created by thread.start_new_thread() isn't
particularly "foreign".
2005-01-08 07:30:42 +00:00
Tim Peters
84d548994e
Converted to a unittest. Added checks that the bounded semaphore actually
...
does what it's supposed to do.
2005-01-08 06:03:17 +00:00
Brett Cannon
e6539c4401
In _DummyThread objects the lock stored in __block (allocated thanks to
...
_Thread.__init__) was never used. This is a waste since locks use OS
primitives that are in limited supply. So the lock is deleted in
_DummyThread.__init__ .
Closes bug #1089632 .
2005-01-08 02:43:53 +00:00
Raymond Hettinger
922b3e2098
Remove test for BINARY_DIVIDE.
2005-01-07 18:34:56 +00:00
Tim Peters
5a9fb3c415
Whitespace normalization.
2005-01-07 16:01:32 +00:00
Jack Jansen
1dd087cbad
Allow relative URLs for included databases and packages.
2005-01-07 13:43:31 +00:00
Raymond Hettinger
97db05de3e
SF #75103 : imghdr -- identify JPEGs in EXIF format
2005-01-07 08:15:41 +00:00
Andrew McNamara
1196cf185c
Improved the implementation of the internal "dialect" type. The new
...
implementation features better error reporting, and better compliance
with the PEP.
2005-01-07 04:42:45 +00:00
Skip Montanaro
f26285ce0b
add a couple missing docstrings
2005-01-05 06:54:58 +00:00
Jack Jansen
af304a6c16
- Added an "installer" flavor, which uses the "open" command to install
...
something (overridable through Install-command entry)
- Hidden status is now determined by flavor == hidden, not by
missing Download-URL. Hidden packages behave like installer packages.
- Made some error messages a bit more understandable.
Because there's new functionality the version has been upped to 0.5.
2005-01-03 15:44:18 +00:00
Raymond Hettinger
362b929222
Removed unused line.
2005-01-03 07:33:16 +00:00
Raymond Hettinger
0c26ab02e6
Removed unused line.
2005-01-03 07:14:12 +00:00
Raymond Hettinger
c34f8673a1
Teach the peephole optimizer to fold simple constant expressions.
2005-01-02 06:17:33 +00:00
Peter Astrand
f791d7a278
On UNIX, when the execution of the child fails, we must waitpid() to
...
prevent leaving zombies.
2005-01-01 09:38:57 +00:00
Peter Astrand
454f76711c
New subprocess utility function: check_call. Closes #1071764 .
2005-01-01 09:36:35 +00:00
Raymond Hettinger
ed2dbe3f33
SF patch #1094007 : Remove witty comment in pydoc.py
...
(Removed at Ping's request.)
2005-01-01 07:51:01 +00:00
Raymond Hettinger
346e67f805
SF patch #1051395 : locale.getdefaultlocale does not return tuple in some OS
...
(Contributed by Jiwon Seo.)
2005-01-01 06:10:26 +00:00
Raymond Hettinger
f871d833dd
Remove some lambdas.
2004-12-31 21:59:02 +00:00
Raymond Hettinger
a617271dbd
Use cStringIO where available.
2004-12-31 19:15:26 +00:00
Walter Dörwald
ee1d24703f
Add a test that checks the basic functionality of every encoding.
2004-12-29 16:04:38 +00:00
Walter Dörwald
6cea693362
Fix wrong variable name.
2004-12-29 15:28:09 +00:00
Walter Dörwald
e1a0391b49
Fix wrong variable name.
2004-12-29 13:11:10 +00:00
Jack Jansen
702af67d47
- getDefaultDatabase wasn't listed in __all__.
...
- using a different database for non-final releases should only be done
for X.Y.0. Non-final micro releases can use the default database just fine,
as they are required to be backward compatible.
2004-12-28 21:33:27 +00:00
Andrew M. Kuchling
3b585b30c0
[Bug #1083110 ] calling .flush() on decompress objects causes a segfault due to an uninitialized pointer: fixes the problem and adds a test case
2004-12-28 20:10:48 +00:00
Jack Jansen
c77f6dfd92
Fix for #1091468 : DESTROOTed frameworkinstalls fail. Added a --destroot
...
option to various tools, and do the right thing when we're doing a destroot
install.
Will backport to 2.4 and 2.3.
2004-12-27 15:51:03 +00:00
Jack Jansen
be95462c1c
After discussion on the PythonMac-SIG it was decided that it is better
...
to make using "-undefined dynamic_lookup" for linking extensions more
automatic on 10.3 and later. So if we're on that platform and
MACOSX_DEPLOYMENT_TARGET is not set we now set it to the current OSX
version during configure. Additionally, distutils will pick up the
configure-time value by default.
Will backport.
2004-12-26 23:07:48 +00:00
Armin Rigo
a174813113
Dima Dorfman's patch for coercion/comparison of C types (patch #995939 ), with
...
a minor change after the coercion, to accept two objects not necessarily of
the same type but with the same tp_compare.
2004-12-23 22:13:13 +00:00
Kurt B. Kaiser
e852c194e3
Improve error message if rpc'l localcall() fails with unexpected
...
exception.
2004-12-23 04:39:55 +00:00
Kurt B. Kaiser
5c3df35b6b
The GUI was hanging if the shell window was closed while a raw_input()
...
was pending. Restored the quit() of the readline() mainloop().
http://mail.python.org/pipermail/idle-dev/2004-December/002307.html
M NEWS.txt
M PyShell.py
2004-12-23 04:20:59 +00:00
Thomas Heller
ee4bb6612a
Recompiled after source changes.
2004-12-22 17:24:36 +00:00
Jeremy Hylton
b300ae3a79
Two small changes, SF bug #974757 and SF patch #1037974 .
...
Pass the full URL to find_user_password(), in particular so that hosts
with port numbers can be looked up.
Also specify the digest algorithm, even if it's MD5. Titus Brown
verified that this fixes a problem with LiveJournal.
2004-12-22 14:27:19 +00:00