Fred Drake [Tue, 30 Jul 2002 17:51:20 +0000 (17:51 +0000)]
SF patch #581414: info reader bug
The "Matching vs. Searching" Info node is unreachable from the Info
program (but is fine in Emacs's Info mode). This patch seems to fix
it. This is the only occurrence where the info reader fails, so
probably it could be addressed in the python docs as a workaround.
Forwarded the report to the info maintainer.
Jack Jansen [Mon, 29 Jul 2002 21:36:35 +0000 (21:36 +0000)]
First stab at the launcher application. This will be run when the user
doubleclicks a .py, .pyw or .pyc file. It runs the file by invoking the
relevant interpreter (either the command line Python in a terminal window
or a Python.app for GUI-based scripts). Interpreter to use and the options
to pass are settable through preferences.
If PythonLauncher wasn't running it does its thing for one script and exits.
If it was manually started before a dialog is presented where the user
can set the options to use, etc.
To be done:
- option-drag/doubleclick should always open the interactive dialog
- Terminal-window isn't done yet
- Should be reimplemented in Python, but pyobjc isn't part of the core.
- Various menu entries should be disabled.
Jason Tishler [Mon, 29 Jul 2002 16:18:23 +0000 (16:18 +0000)]
Patch #553702: Cygwin make install patch
This patch fixes make install for Cygwin. Specifically,
it reverts to the previous behavior:
o install libpython$(VERSION)$(SO) in $(BINDIR)
o install $(LDLIBRARY) in $(LIBPL)
It also begins to remove Cygwin's dependency on
$(DLLLIBRARY) which I hope to take advantage of
when I attempt to make Cygwin as similar as possible
to the other Unix platforms (in other patches).
I tested this patch under Red Hat Linux 7.1 without
any ill effects.
BTW, I'm not the happiest using the following
test for Cygwin:
Thomas Heller [Mon, 29 Jul 2002 14:27:41 +0000 (14:27 +0000)]
New functions for extension writers on Windows:
PyErr_SetExcFromWindowsErr(), PyErr_SetExcFromWindowsErrWithFilename().
Similar to PyErr_SetFromWindowsErrWithFilename() and
PyErr_SetFromWindowsErr(), but they allow to specify
the exception type to raise. Available on Windows.
Mark Hammond [Mon, 29 Jul 2002 13:42:14 +0000 (13:42 +0000)]
Excise DL_IMPORT/EXPORT from object.h, and related files. This patch
also adds 'extern' to PyAPI_DATA rather than at each declaration, as
discussed with Tim and Guido.
Kurt B. Kaiser [Fri, 26 Jul 2002 00:06:42 +0000 (00:06 +0000)]
Reverse the RPC socket connection: Python execution server connects to
Idle client and localhost origin of connection is verified by client.
M PyShell.py
M rpc.py
M run.py
Fred Drake [Thu, 25 Jul 2002 21:11:23 +0000 (21:11 +0000)]
Small clarifications when referring to the sys.exc_* variables so that
readers are not given the wrong impression that they should be using those
on a regualar basis.
This closes SF bug #585598.
Fred Drake [Thu, 25 Jul 2002 16:23:21 +0000 (16:23 +0000)]
- Make number in comment match the targets in that section of the
Makefile.
- Update the Python version number so we're using the library built
from the current working sources.
* runctx - fix a couple typos
* globaltrace_lt - handle case where inspect.getmodulename doesn't return
anything useful
* localtrace_trace - handle case where inspect.getframeinfo doesn't return
any context info
I think both of the last two are caused by exec'd or eval'd code
remove spurious SET_LINENO from com_list_for and com_list_if. All they do
is slow things down unnecessarily and make tracing much more verbose.
Something like
def f(n):
return [i for i in range(n) if i%2]
should have at most two SET_LINENO instructions, not four. When tracing,
the current line number should be printed once, not 2*n+1 times.
The test for re.engine was misfiring because re.engine is no longer
defined and the default was "pre" instead of "sre". Give up on 1.5.2
compatibility, hardcode the sre solution. However, this XXX comment
still applies, AFAIK:
# XXX This code depends on internals of the regular expression
# engine! There's no standard API to do a substitution when you
# have already found the match. One should be added.
Barry Warsaw [Tue, 23 Jul 2002 19:04:11 +0000 (19:04 +0000)]
Get rid of relative imports in all unittests. Now anything that
imports e.g. test_support must do so using an absolute package name
such as "import test.test_support" or "from test import test_support".
This also updates the README in Lib/test, and gets rid of the
duplicate data dirctory in Lib/test/data (replaced by
Lib/email/test/data).
Mark Hammond [Tue, 23 Jul 2002 06:31:15 +0000 (06:31 +0000)]
Replace DL_IMPORT with PyMODINIT_FUNC and remove "/export:init..." link
command line for Windows builds. This should allow MSVC to import and
build the Python MSVC6 project files without error.
Tim Peters [Sun, 21 Jul 2002 17:37:03 +0000 (17:37 +0000)]
New test "+sort", tacking 10 random floats on to the end of a sorted
array. Our samplesort special-cases the snot out of this, running about
12x faster than *sort. The experimental mergesort runs it about 8x
faster than *sort without special-casing, but should really do better
than that (when merging runs of different lengths, right now it only
does something clever about finding where the second run begins in
the first and where the first run ends in the second, and that's more
of a temp-memory optimization).
it's looking for, and reports the skip as a crash failure instead of
as a skipped test.
I suppose this will make it harder to run this test outside of
regrtest, but under the assumption only Barry does that, better to
make it skip cleanly for everyone else.
Barry Warsaw [Fri, 19 Jul 2002 22:31:10 +0000 (22:31 +0000)]
The email package's tests live much better in a subpackage
(i.e. email.test), so move the guts of them here from Lib/test. The
latter directory will retain stubs to run the email.test tests using
Python's standard regression test.
test_email_torture.py is a torture tester which will not run under
Python's test suite because I don't want to commit megs of data to
that project (it will fail cleanly there). When run under the mimelib
project it'll stress test the package with megs of message samples
collected from various locations in the wild.
Barry Warsaw [Fri, 19 Jul 2002 22:29:49 +0000 (22:29 +0000)]
The email package's tests live much better in a subpackage
(i.e. email.test), so move the guts of them here from Lib/test. The
latter directory will retain stubs to run the email.test tests using
Python's standard regression test.
test_email_torture.py is a torture tester which will not run under
Python's test suite because I don't want to commit megs of data to
that project (it will fail cleanly there). When run under the mimelib
project it'll stress test the package with megs of message samples
collected from various locations in the wild.
email/test/data is a copy of Lib/test/data. The fate of the latter is
still undecided.
Barry Warsaw [Fri, 19 Jul 2002 22:24:55 +0000 (22:24 +0000)]
To better support default content types, fix an API wart, and preserve
backwards compatibility, we're silently deprecating get_type(),
get_subtype() and get_main_type(). We may eventually noisily
deprecate these. For now, we'll just fix a bug in the splitting of
the main and subtypes.
get_content_type(), get_content_maintype(), get_content_subtype(): New
methods which replace the above. These /always/ return a content type
string and do not take a failobj, because an email message always at
least has a default content type.
set_default_type(): Someday there may be additional default content
types, so don't hard code an assertion about the value of the ctype
argument.