Fred Drake [Mon, 23 Aug 1999 20:12:11 +0000 (20:12 +0000)]
whrandom should come immediately after random, not before.
Fred Drake [Mon, 23 Aug 1999 18:57:25 +0000 (18:57 +0000)]
Clarified start parameter to Py_CompileString, documented
Py_eval_input, Py_file_input, and Py_single_input.
Problems reported by Aaron Brancotti <aaron@icona.it>.
Jack Jansen [Mon, 23 Aug 1999 11:45:40 +0000 (11:45 +0000)]
Removed availabe() method again: even on PPC it sometimes returns 1 while
quicktime isn't available. Use gestalt in stead for this functionality.
Jack Jansen [Mon, 23 Aug 1999 11:37:51 +0000 (11:37 +0000)]
Return MacOS.Error in stead of RuntimeError in case of failure so the user
gets a reasonable explanation in stead of a large negative number.
Guido van Rossum [Fri, 20 Aug 1999 19:11:27 +0000 (19:11 +0000)]
Port inet_ntoa and inet_aton to Windows:
- fix unescaped newline in string literal
- removed unused err variable
- Windows doesn't have inet_aton; use inet_addr instead
Guido van Rossum [Fri, 20 Aug 1999 18:26:06 +0000 (18:26 +0000)]
Add calls to self.protocol("WM_DELETE_WINDOW", self.destroy) to the Tk
and Toplevel class constructors. This means that if the window
manager closes the window, the Python-side Tkinter data structures
will be destroyed correctly. (Most apps do this anyway, and it's
recommended practice; I see no reason why making it the default
behavior could be bad.)
Guido van Rossum [Fri, 20 Aug 1999 18:21:51 +0000 (18:21 +0000)]
Patch by Ben Gertzfield to add inet_aton() and inet_ntoa() calls.
Fred Drake [Fri, 20 Aug 1999 14:28:29 +0000 (14:28 +0000)]
rewrite_descriptor(): Fix bug that dropped the first TEXT node from
<description> elements. Add another sanity
check to make sure a special case only becomes
involved for <opcodedesc> and <opcodedescni>
elements.
fixup_paras_helper(): Clean up control flow.
Everywhere that checks node.nodeType==ELEMENT and node.tagName now
just check node.nodeName (nodeName is guaranteed for all node types
and will be special values that don't conflict with GIs for
non-ELEMENT nodes). Simplifies a number of tests and improves
readability in a lot of places.
Fred Drake [Fri, 20 Aug 1999 13:30:49 +0000 (13:30 +0000)]
Oops, better update the date on the .TH line.
Fred Drake [Fri, 20 Aug 1999 13:10:20 +0000 (13:10 +0000)]
Various updates, mostly to add information to the SEE ALSO and
INTERNET RESOURCES sections based on c.l.py comments.
Barry Warsaw [Thu, 19 Aug 1999 21:17:08 +0000 (21:17 +0000)]
A nit to make Fred proud.
Greg Ward [Thu, 19 Aug 1999 20:02:10 +0000 (20:02 +0000)]
Oops, call 'os.path.join()'!
Fred Drake [Thu, 19 Aug 1999 17:00:38 +0000 (17:00 +0000)]
Tell what the result objects are (based on comment from the list).
Guido van Rossum [Thu, 19 Aug 1999 16:00:41 +0000 (16:00 +0000)]
Scrit by Marc-Andre Lemburg to generate htmlentitydefs.py.
Guido van Rossum [Thu, 19 Aug 1999 15:59:35 +0000 (15:59 +0000)]
New version by Mark-Andre Lemburg (generated by a script, parseentities.py).
Fred Drake [Thu, 19 Aug 1999 15:37:35 +0000 (15:37 +0000)]
Added item regarding random/whrandom.
Guido van Rossum [Thu, 19 Aug 1999 14:42:54 +0000 (14:42 +0000)]
Added disclaimer to the sleep() function.
Guido van Rossum [Thu, 19 Aug 1999 14:40:27 +0000 (14:40 +0000)]
In floatsleep(), when using select(), ignore EINTR error.
Guido van Rossum [Wed, 18 Aug 1999 21:51:10 +0000 (21:51 +0000)]
Patches by Michael Reilly to correctly deal with ftp URLs of the form
ftp://user@host//root/path: the double slash in the pathname means to
go to the root directory even if the initial directory isn't the root.
Barry Warsaw [Wed, 18 Aug 1999 20:18:20 +0000 (20:18 +0000)]
Bump to version 1.1
Barry Warsaw [Wed, 18 Aug 1999 20:17:42 +0000 (20:17 +0000)]
__update(): Jeremy Hylton reports occurances of sunaudiodev.error
(interrupted system call) when getting the device information. I've
never seen it, but this patch should take care of the problem.
If we get that exception and we're polling, just return since we'll
wake up again soon and get the right information. If we're not
polling, try 4 times and then give up.
Guido van Rossum [Wed, 18 Aug 1999 20:03:17 +0000 (20:03 +0000)]
Typo in comment (on Mac, it's the *resource* fork that's not copied,
the data fork *is* copied).
Guido van Rossum [Wed, 18 Aug 1999 17:40:33 +0000 (17:40 +0000)]
Patches by Michael Reilly to correctly deal with ftp URLs of the form
ftp://user@host//root/path: the double slash in the pathname means to
go to the root directory even if the initial directory isn't the root.
Guido van Rossum [Wed, 18 Aug 1999 13:53:28 +0000 (13:53 +0000)]
Add Tim Peters' shuffle() algorithm.
Greg Ward [Sat, 14 Aug 1999 23:57:49 +0000 (23:57 +0000)]
Implements the 'build_ext' command for building C/C++ extension modules.
Greg Ward [Sat, 14 Aug 1999 23:57:17 +0000 (23:57 +0000)]
Module to spawn sub-commands in a platform-independent way.
Initial revision only includes support for POSIX-style fork-and-exec.
Greg Ward [Sat, 14 Aug 1999 23:53:53 +0000 (23:53 +0000)]
Changed to use 'spawn()', now that it exists.
Added 'verbose' and 'dry_run' parameters to constructor.
Changed 'compile()', 'link_*()' to default lists arguments to None
rather than empty list.
Added implementations of the filename-mangling methods mandated by
the CCompiler interface.
Greg Ward [Sat, 14 Aug 1999 23:50:50 +0000 (23:50 +0000)]
Added 'verbose' and 'dry_run' flags to CCompiler constructor and
'new_compiler()' factory function.
Added 'runtime_library_dirs' list (for -R linker option) and methods
to manipulate it.
Deleted some obsolete comments.
Added all the filename manglign methods: 'object_filenames()',
'shared_object_filename()', 'library_filename()',
'shared_library_filename()'.
Added 'spawn()' method (front end to the "real" spawn).
Greg Ward [Sat, 14 Aug 1999 23:47:21 +0000 (23:47 +0000)]
Comment tweak.
Greg Ward [Sat, 14 Aug 1999 23:44:37 +0000 (23:44 +0000)]
Better detection of bad entries in option table.
Better error messages for bad entries in option table.
Greg Ward [Sat, 14 Aug 1999 23:43:45 +0000 (23:43 +0000)]
Added DistutilsExecError, DistutilsValueError.
Barry Warsaw [Fri, 13 Aug 1999 20:59:48 +0000 (20:59 +0000)]
Initial implementation
Fred Drake [Fri, 13 Aug 1999 13:36:33 +0000 (13:36 +0000)]
Explain the possible range of values for the pid parameter to
waitpid().
Barry Warsaw [Wed, 11 Aug 1999 21:40:38 +0000 (21:40 +0000)]
Initial revision
Guido van Rossum [Wed, 11 Aug 1999 14:55:43 +0000 (14:55 +0000)]
Moshe noticed an inconsistency in his comment, so I'm rephrasing it to
be clearer.
Guido van Rossum [Wed, 11 Aug 1999 02:01:00 +0000 (02:01 +0000)]
Patch inspired by Moshe Zadka to search for the Icons directory in the
same directory as __file__, rather than searching for it along sys.path.
This works better when idle is a package.
Guido van Rossum [Wed, 11 Aug 1999 01:54:05 +0000 (01:54 +0000)]
Patch by Paul Sokolovsky to support the get() method.
Barry Warsaw [Tue, 10 Aug 1999 21:49:00 +0000 (21:49 +0000)]
(py-shell): Set the default shell if not set yet. It's sometimes
convenient to call py-shell before the first Python file has been
visited.
Greg Ward [Tue, 10 Aug 1999 20:09:38 +0000 (20:09 +0000)]
Allow comment characters (#) to be escaped:
- did away with 'comment_re' option -- it's just not that simple anymore
- heavily revised the main logic in 'readline()' to accomodate this
Beefed up 'warn()': 'line' can be list or tuple, and 'msg' is
automatically converted to a string.
Andrew M. Kuchling [Tue, 10 Aug 1999 13:19:30 +0000 (13:19 +0000)]
Added __del__ method to GzipFile class that will flush and close the
object, if required.
Fred Drake [Mon, 9 Aug 1999 17:05:12 +0000 (17:05 +0000)]
In note mentioning [].remove()'s exception, tell what exception is
raised. Prompted by Barry's whining. ;-0
Guido van Rossum [Mon, 9 Aug 1999 14:40:40 +0000 (14:40 +0000)]
Patch by Marc-Andre Lemburg to add a bunch more symbols.
Guido van Rossum [Sat, 7 Aug 1999 14:01:05 +0000 (14:01 +0000)]
Ofir Reichenberg suggested to apply htonl() to grpaddr in openmcastsock().
Also got rid of unnecessary use of eval() and regsub.gsub().
Fred Drake [Thu, 5 Aug 1999 13:43:08 +0000 (13:43 +0000)]
Add index entries for open():
buffer size, I/O
I/O control, buffering
line-buffered I/O
unbuffered I/O
Fred Drake [Thu, 5 Aug 1999 13:41:31 +0000 (13:41 +0000)]
Add index entry "I/O control, buffering" for fdopen().
Fred Drake [Thu, 5 Aug 1999 13:41:04 +0000 (13:41 +0000)]
Add index entry "I/O control, buffering" for makefile().
Guido van Rossum [Wed, 4 Aug 1999 18:00:12 +0000 (18:00 +0000)]
Vladimir Marangozov fixes an AIX-specific problem, writing:
"""
Following up Robin Dunn's troubles with freeze, here's a patch that
fixes an oddity regarding the import logic of shared modules on AIX.
Symbol resolution of shared modules is now handled properly for the cases
when the python library is linked to a binary with an arbitrary name.
This includes the standard python[version] executable, but also applications
that are embedding the python core (i.e. linked with libpython[version].a,
the latter being static or shared).
"""
Fred Drake [Wed, 4 Aug 1999 13:13:24 +0000 (13:13 +0000)]
Started documentation on buffer objects & types. Very preliminary.
Greg Stein: Please help with this; it's your baby!
Fred Drake [Wed, 4 Aug 1999 13:08:19 +0000 (13:08 +0000)]
PyBuffer_New(): Raise ValueError if size is negative (the other
constructors didn't miss this).
Raise MemoryError if malloc() fails, instead of just
returning NULL.
Jack Jansen [Wed, 4 Aug 1999 12:07:09 +0000 (12:07 +0000)]
Added available() method, which checks whether quicktime is installed at all (by
testing whether EnterMovies points to an actual routine or is a null pointer).
Guido van Rossum [Tue, 3 Aug 1999 21:52:29 +0000 (21:52 +0000)]
Change the directory tree walking example to use clearer variable
names, some suggested by Joe Ellsworth.
Guido van Rossum [Tue, 3 Aug 1999 19:41:10 +0000 (19:41 +0000)]
It turns out that modifying the environment strings is not safe.
Treat them as read-only, and make a copy as appropriately. This was
first reported by Bill Janssend and later by Craig Rowland and Ron
Sedlmeyer. This fix is mine.
Fred Drake [Tue, 3 Aug 1999 17:54:39 +0000 (17:54 +0000)]
Re-write in Python for portability. About 30% slower, but who cares?!
Fred Drake [Tue, 3 Aug 1999 15:32:48 +0000 (15:32 +0000)]
remap_element_names(): Only used for things that the new conversion
engine in latex2esis.py can do, so discard it.
paragraph detection & markup: Handle some of the list-like
environments properly, picking up paragraphs inside
list items. (Only changed a few element-sets used for
recognition.)
fixup_refmodindexes_chunk(): Use the right attribute to determine the
module a <ref*modindex/> element is referring to.
convert(): Don't call remap_element_names(); it was removed.
Fred Drake [Tue, 3 Aug 1999 15:27:37 +0000 (15:27 +0000)]
The new conversion engine supports more of the table re-writing than
the old one, so use it.
Guido van Rossum [Mon, 2 Aug 1999 20:49:37 +0000 (20:49 +0000)]
Removed PyMapping_Clear() -- it was wishful thinking and serves no
great purpose.
Fred Drake [Mon, 2 Aug 1999 20:20:14 +0000 (20:20 +0000)]
Use the mksourcepgk script instead of mktarball.sh.
Fred Drake [Mon, 2 Aug 1999 20:19:42 +0000 (20:19 +0000)]
Remove obsolete version of script.
Fred Drake [Mon, 2 Aug 1999 20:19:17 +0000 (20:19 +0000)]
Re-implementation of mktarball.sh as a more portable Python script;
with a more descriptive name.
Allow creation of multiple archive formats with a single pass; useful
in this case since it uses a fresh export/checkout from CVS to ensure
that the tree is "clean" (no build turds, saved files, &c). Use --all
to create all supported formats.
Fred Drake [Mon, 2 Aug 1999 14:46:15 +0000 (14:46 +0000)]
bwrite(), ewrite(): Helpers for diagnostic output; essentially the
same as sys.stderr.write(), but bwrite() will make it
bold if stderr is a tty (for visibility).
Use these everywhere instead of accessing
sys.stderr.write() directly.
find_all_child_elements(): Find all elements by type name that are
immediate children of another.
cleanup_synopses(): Receive both the document and fragment objects as
parameters; if only the document is passed, synopsis
information is never found since it's in the fragment!
build_para(): Add a chunk of code to ensure that a newline always
follows the </para> end-tag. Not really important, but
makes presentation consistent for authoring/
maintenance.
fixup_bifuncindexes_chunk(): Use find_all_child_elements() instead of
find_all_elements() so we don't work with too many
levels at once; that could cause DOM exceptions with
the <elem>.removeChild() method.
Fred Drake [Mon, 2 Aug 1999 14:35:25 +0000 (14:35 +0000)]
Mostly minor changes.
Removed some obsolete commented-out code.
Merged BaseConversion into Conversion since there's only one
conversion process now.
Remove push/pop of output stream; it's no longer needed.
Fred Drake [Mon, 2 Aug 1999 14:32:46 +0000 (14:32 +0000)]
This doesn't need to do nearly as much for the new conversion, so
simplify.
Fred Drake [Mon, 2 Aug 1999 14:32:11 +0000 (14:32 +0000)]
A few small improvements to the conversion.
Fred Drake [Mon, 2 Aug 1999 14:30:52 +0000 (14:30 +0000)]
Markup nits.
Adjust examples to use the object interface instead of the function
interface.
Fred Drake [Mon, 2 Aug 1999 14:13:09 +0000 (14:13 +0000)]
Fixed hyperlink references to the __builtin__ and __main__ modules;
error reported by Dale Nagata <DNagata@creo.com>.
Guido van Rossum [Fri, 30 Jul 1999 17:48:20 +0000 (17:48 +0000)]
Mark Hammond writes:
"""
If the filename being complained about contains a space, enclose the
file-name in quotes.
The reason is simply that when I try and parse tabnanny's output, filenames
with spaces make it very difficult to determine where the filename stops
and the linenumber begins!
"""
Tim approves.
I slightly changed the patch (use 'in' instead of string.find()) and
arbitrarily bumped the __version__ variable up to 6.
Guido van Rossum [Fri, 30 Jul 1999 12:22:12 +0000 (12:22 +0000)]
Remove some redundant code from Canvas.tag_bind(), which added all
bindings to a dictionary _tagcommands which was otherwise unused.
(This was checked in accidentally with rev. 1.125 and not deleted with
rev. 1.127 when the other half of this code was removed -- although
even as originally checked in the _tagcommands variable was never
used.)
(PR#40, reported by Peter Stoehr)
Fred Drake [Thu, 29 Jul 1999 22:42:27 +0000 (22:42 +0000)]
Ripped out the old conversion.
Fred Drake [Thu, 29 Jul 1999 22:23:19 +0000 (22:23 +0000)]
Added a few more passes through the document fragment. Not actually
very interesting.
Fred Drake [Thu, 29 Jul 1999 22:22:13 +0000 (22:22 +0000)]
Massive changes.
Separate the Conversion class into a base and a subclass; the subclass
is pretty minimal but the separation is useful for....
NewConversion: New class that implements a somewhat different
approach to the conversion. This uses a table of
instances (rather than tuples) that have more
information than the tuples used for the older
conversion procedure. This allows a lot more control
over the conversion, and it seems to be pretty
stable.
TableEntry,
Parameter: New classes that are used to build the conversion
specification used by NewConversion.
TableParser: xmllib.XMLParser subclass that builds a conversion
specification from an XML document.
load_table(): Convenience function that loads a table from a file.
main(): Added flags --new and --old; these select which conversion is
used. The default is --new.
Several fixes have been made in the old conversion as well; these were
done before writing & switching to the new conversion, and should be
archived.
The next checkin of this file will discard the old conversion; is is
kept in this checkin to allow it to be retrieved if needed, and to
avoid lossing the bugfixes that have been made to it in the interim.
Fred Drake [Thu, 29 Jul 1999 22:14:09 +0000 (22:14 +0000)]
Minor updates.
Fred Drake [Thu, 29 Jul 1999 22:13:31 +0000 (22:13 +0000)]
Use the (new) buildFragment() method of the EsisBuilder rather than
implementing it all here.
Fred Drake [Thu, 29 Jul 1999 22:03:52 +0000 (22:03 +0000)]
Some minor cleanup.
Fred Drake [Thu, 29 Jul 1999 22:03:11 +0000 (22:03 +0000)]
Conversion specification, used by a new path through latex2esis.py.
The specific markup conversion is coded here instead of an even more
cryptic table in the code of latex2esis.py.
Fred Drake [Thu, 29 Jul 1999 22:01:39 +0000 (22:01 +0000)]
Minor update.
Fred Drake [Thu, 29 Jul 1999 13:56:41 +0000 (13:56 +0000)]
Change an {\em ...} to \var{...} and a {\bf ...} to \program{...} (the
new markup makes sense in context).
These allow the SGML/XML conversion updates to work, & should not have
still been in there anyway.
Barry Warsaw [Wed, 28 Jul 1999 22:06:06 +0000 (22:06 +0000)]
A few minor Customize changes:
(python): Set defgroup :prefix to "py-" to make variable names cleaner.
(py-jpython-command, py-jpython-command-args): Set :tag for proper
capitalization of JPython in variable name display.
Barry Warsaw [Wed, 28 Jul 1999 21:59:43 +0000 (21:59 +0000)]
(python-mode): Set which interpreter (CPython or JPython) to use the
first time a py buffer is visited during the Emacs session. This
ensures that py-which-shells is initialized and also guarantees that
the mode lines reflect the correct shell. First bug found by GvR,
second one has long bugged :) me.
(py-toggle-shells): Programmatically, arg can also take the symbols
`cpython' or `jpython', which makes it easy to call with the value of
py-default-interpreter.
(py-shell): Don't need to initialize py-which-* variables since these
will guarantee to be initialized by python-mode when the first py
buffer is visited.
(py-default-interpreter): Update docstring.
Guido van Rossum [Wed, 28 Jul 1999 21:39:28 +0000 (21:39 +0000)]
Another patch from Andy Dustman:
"""
Here's a patch for the ForkingMixIn which will prevent the server from
forking itself into the ground. Note: I've tested a very similar patch
(subclassed ForkingMixIn) but not actually tested this one. As you might
surmise, this was done out of necessity...
If the maximum number of children are already running, block while waiting
for a child to exit.
"""
(I added that last sentence as a comment to the code --GvR.)
Barry Warsaw [Tue, 27 Jul 1999 21:40:02 +0000 (21:40 +0000)]
(py-beginning-of-def-or-class): Only move to match-beginning if the
regex match actually succeeded!
Fred Drake [Tue, 27 Jul 1999 16:30:59 +0000 (16:30 +0000)]
Add support for bzip2 compression.
New target: distfiles, create all distribution archives, regardless of
archive format. (Individual targets remain for each archive format.)
Fred Drake [Tue, 27 Jul 1999 16:29:30 +0000 (16:29 +0000)]
Add support for bzip2 using --bzip2.
Fred Drake [Tue, 27 Jul 1999 14:23:25 +0000 (14:23 +0000)]
Ignore additional compressed formats.
Fred Drake [Mon, 26 Jul 1999 15:45:52 +0000 (15:45 +0000)]
Added description of optional parameter to UserDict constructor.
Omission reported by Barry Warsaw.
Fred Drake [Fri, 23 Jul 1999 16:11:36 +0000 (16:11 +0000)]
Add zip archive support for html, pdf, ps, and latex archives.
"zips" target produces all possible .zip files.
Fred Drake [Fri, 23 Jul 1999 16:09:11 +0000 (16:09 +0000)]
Add --zip parameter; make this able to produce .zip files as well as
.tgz files.
Fred Drake [Fri, 23 Jul 1999 15:04:05 +0000 (15:04 +0000)]
getsize(), getatime(), getmtime():
Constants from stat module were imported using "import *";
don't access them via stat.ST_*!
Reported by that other vR. ;-)
Fred Drake [Thu, 22 Jul 1999 19:21:45 +0000 (19:21 +0000)]
Update getattr() description to document the optional third
parameter. Thanks to Barry Warsaw for pointing out the oversight.
Fred Drake [Thu, 22 Jul 1999 13:57:12 +0000 (13:57 +0000)]
Make the default target xml instead of sgml.
Fred Drake [Thu, 22 Jul 1999 13:56:51 +0000 (13:56 +0000)]
Make the default target xml instead of sgml.
Use a temporary file to pass results from latex2esis.py to
docfixer.py; this makes for better error detection by make (if the
first pipeline stage fails, make wasn't catching it).
Fred Drake [Tue, 20 Jul 1999 13:21:42 +0000 (13:21 +0000)]
typo: privide --> provide
Reported by Nadim Ghaznavi <nadim@ghaznavi.com>.
Fred Drake [Mon, 19 Jul 1999 15:21:16 +0000 (15:21 +0000)]
Fixed order of parameters in slice() docstring. The Library Reference
had it right! Reported by Tim Hochberg <tim.hochberg@ieee.org>.
Guido van Rossum [Thu, 15 Jul 1999 13:11:02 +0000 (13:11 +0000)]
New wishes.
Guido van Rossum [Tue, 13 Jul 1999 15:23:42 +0000 (15:23 +0000)]
Add test case for bug just fixed by Stephen Turner.
Guido van Rossum [Tue, 13 Jul 1999 15:18:58 +0000 (15:18 +0000)]
Patch by Stephen Turner, who writes:
"""
It fixes a memory corruption error resulting from BadPickleGet
exceptions in load_get, load_binget and load_long_binget. This was
initially reported on c.l.py as a problem with Cookie.py; see the thread
titled "python core dump (SIGBUS) on Solaris" for more details.
If PyDict_GetItem(self->memo, py_key) call failed, then py_key was being
Py_DECREF'd out of existence before call was made to
PyErr_SetObject(BadPickleGet, py_key).
The bug can be duplicated as follows:
import cPickle
cPickle.loads('garyp')
This raises a BadPickleGet exception whose value is a freed object. A
core dump will soon follow.
"""
Jim Fulton approves of the patch.
Guido van Rossum [Tue, 13 Jul 1999 05:41:12 +0000 (05:41 +0000)]
Mark Favas was quick to note that the last checkin divides by zero
when n == 0... So divide by a->ob_size instead which was already
tested for 0.
Guido van Rossum [Mon, 12 Jul 1999 23:06:58 +0000 (23:06 +0000)]
Appropriate overflow checks so that things like sys.maxint*(1,) can't
dump core.
Barry Warsaw [Mon, 12 Jul 1999 18:47:00 +0000 (18:47 +0000)]
added a test for "To: :" patch
Barry Warsaw [Mon, 12 Jul 1999 18:37:02 +0000 (18:37 +0000)]
AddrlistClass.getaddress(): when parsing `:'s, in the loop, watch out
for gotonext() pushing self.pos past the end of the string. This can
happen if the message has a To field like "To: :" and you call
msg.getaddrlist('to').
Fred Drake [Mon, 12 Jul 1999 16:52:50 +0000 (16:52 +0000)]
Added comment clarifying that RELEASE is the documentation release
number, not the Python release.
Removed VERSION since it is not used.