Walter Dörwald [Wed, 2 Apr 2003 16:37:24 +0000 (16:37 +0000)]
Change formatchar(), so that u"%c" % 0xffffffff now raises
an OverflowError instead of a TypeError to be consistent
with "%c" % 256. See SF patch #710127.
Jack Jansen [Tue, 1 Apr 2003 22:27:18 +0000 (22:27 +0000)]
Sigh... The get() and set() commands are not declared in the aete for
the Standard_Suite, but various other suites do expect it (the Finder
implements get() without declaring it itself). It is probably another
case of OSA magic. Adding them to the global base class.
Jack Jansen [Tue, 1 Apr 2003 22:01:58 +0000 (22:01 +0000)]
Properties (like enums) are not in the global namespace but only valid
within a certain context. Give them an _Prop_ prefix, so they don't
accidentally obscure an element from another suite (as happened with
the Finder). Comparisons I'm not sure about, so I left them as global
names.
Also got rid of the lists if declarations, they serve no useful purpose.
Jack Jansen [Tue, 1 Apr 2003 13:32:17 +0000 (13:32 +0000)]
- All messages are now dependent on the --verbose option.
- Added a --dump option that doesn't generate the module but dumps
the pretty-printed aete resource(s) on stdout.
Jack Jansen [Mon, 31 Mar 2003 13:32:59 +0000 (13:32 +0000)]
Subclasses of ObjectSpecifier can now be packed and unpacked. This allows
you to say something like "talker.count(want=Address_Book.people)" in
stead of having to manually create the aetypes.Type(Address_Book.people.want)
OSA type.
Jack Jansen [Mon, 31 Mar 2003 13:29:32 +0000 (13:29 +0000)]
In TalkTo.send(), check that we have access to the window manager,
and initialize the event loop (if not done previously) to work around
a bug (IMHO) in MacOSX 10.2.
Jack Jansen [Sun, 30 Mar 2003 22:39:39 +0000 (22:39 +0000)]
Classes have to be sorted by code, not name, and synonyms have to
be sorted after the main name, otherwise filling of properties and
elements messes up.
Skip Montanaro [Sun, 30 Mar 2003 04:54:24 +0000 (04:54 +0000)]
The socket module now always uses the _socketobject wrapper class, even on
platforms which have dup(2). The makefile() method is built directly on top
of the socket without duplicating the file descriptor, allowing timeouts to
work properly. Includes a new test case (urllibnet) which requires the
network resource.
Jack Jansen [Sat, 29 Mar 2003 22:54:00 +0000 (22:54 +0000)]
- Added an is_scriptable method to test applications for having
a scripting dictionary. Made up by me, not guaranteed to be correct
(and, indeed, Internet Explorer does not seem to play by the book).
- Added the interactive main program as a separate routine, so it
can be called from the IDE later. Also made it less interactive by
default: only the input app and output package folder are asked for.
Jack Jansen [Sat, 29 Mar 2003 22:07:47 +0000 (22:07 +0000)]
The test for setpgrp having two arguments didn't actually test anything.
For reasons unknown this suddenly started to matter (since Martin's 1.396
checkin? But why?), at least on MacOSX. Added a real test similar to the
getpgrp argument test.
Neal Norwitz [Sat, 29 Mar 2003 22:01:17 +0000 (22:01 +0000)]
Move Mac/Windows specific expected skips from each platform list
to the ExpectedSkips class. Add test_scriptpackages to Mac only list.
Add test_unicode_file to Windows only list.
Jack Jansen [Sat, 29 Mar 2003 00:13:17 +0000 (00:13 +0000)]
Regenerated with the new way to get terminology (through AppleEvents),
which sometimes seems to result in different terminology. It does
seem to be mostly compatible, though.
Jack Jansen [Sat, 29 Mar 2003 00:11:32 +0000 (00:11 +0000)]
- Prefer using events (in stead of poking around in resource files) to
get terminology resources. Unfortunately there doesn't seem to be any
application I can ask for the basic StdSuites terminology (?).
- Prefer OSX-native versions of applications over OS9 versions.
Jack Jansen [Fri, 28 Mar 2003 23:42:37 +0000 (23:42 +0000)]
On OSX the finder will return from an open() event before the application
has actually entered its event loop. As a stopgap, allow for a 10 second
grace period.
Jack Jansen [Fri, 28 Mar 2003 22:07:22 +0000 (22:07 +0000)]
Regenerated (from resource files) with sorting version of gensuitemodule.
This is a first step towards regenerating the modules with newer, MacOSX,
versions of these programs, and using the programmatic interface to
get at the terminology in stead of poking in resource files.
Jack Jansen [Fri, 28 Mar 2003 22:04:22 +0000 (22:04 +0000)]
- Sort various lists (list of events, OSA-classes, etc) before generating
code. This makes it a lot easier to compare the generated code for two
different versions of the suite.
- Various tweaks to the code to generate suites without looking at resource
files manually.
Jack Jansen [Fri, 28 Mar 2003 22:01:41 +0000 (22:01 +0000)]
Minimal test suite of the generated packages in plat-mac/lib-scriptpackages.
At the moment does little more than testing that the modules import
correctly and some classes can be instantiated.
Ka-Ping Yee [Fri, 28 Mar 2003 16:35:51 +0000 (16:35 +0000)]
Hide private names beginning with _ (but don't hide __special__ names).
Clean up section headings; make the bars on the left less fat.
Adjust the display of properties slightly.
Don't show stuff inherited from the base 'object' type.
Jack Jansen [Wed, 26 Mar 2003 23:14:44 +0000 (23:14 +0000)]
If GetAppTerminology fails (which seems to be the usual case on OSX?)
we try to manually launch the application and send it an ascr/gdte
event to get its terminology.
Adds a single function to improve generated bytecode. Has a single line
attachment point, so it is completely de-coupled from both the compiler
and ceval.c.
Makes three simple transforms that do not require a basic block analysis
or re-ordering of code. Gives improved timings on pystone, pybench,
and any code using either "while 1" or "x,y=y,x".
Jack Jansen [Tue, 25 Mar 2003 10:20:55 +0000 (10:20 +0000)]
Frank Vercruesse gave an okay on removing the copyright notice:
"Hereby I make the script in question available under the terms and
conditions of the latest Python License."
Guido van Rossum [Mon, 24 Mar 2003 23:49:49 +0000 (23:49 +0000)]
Refactoring: rename update_these_slots() into update_subclasses() and
generalize to take a callback function and a void * data argument.
This might come in handy later... :-)
Tim Peters [Sun, 23 Mar 2003 17:52:28 +0000 (17:52 +0000)]
Improved new Py_TRACE_REFS gimmicks.
Arranged that all the objects exposed by __builtin__ appear in the list
of all objects. I basically peed away two days tracking down a mystery
leak in sys.gettotalrefcount() in a ZODB app (== tons of code), because
the object leaking the references didn't appear in the sys.getobjects(0)
list. The object happened to be False. Now False is in the list, along
with other popular & previously missing leak candidates (like None).
Alas, we still don't have a choke point covering *all* Python objects,
so the list of all objects may still be incomplete.
Tim Peters [Sun, 23 Mar 2003 03:33:13 +0000 (03:33 +0000)]
Refactored some of the Py_TRACE_REFS code. New private API function
_Py_AddToAllObjects() that simply inserts an object at the front of
the doubly-linked list of all objects. Changed PyType_Ready() (the
closest thing we've got to a choke point for type objects) to call
that.
Tim Peters [Sun, 23 Mar 2003 02:51:01 +0000 (02:51 +0000)]
When Py_TRACE_REFS is defined, a list of all live objects is maintained in
a doubly-linked list, exposed by sys.getobjects(). Unfortunately, it's not
really all live objects, and it seems my fate to bump into programs where
sys.gettotalrefcount() keeps going up but where the reference leaks aren't
accounted for by anything in the list of all objects.
This patch helps a little: if COUNT_ALLOCS is also defined, from now on
type objects will also appear in this list, provided at least one object
of a type has been allocated.
Kurt B. Kaiser [Sat, 22 Mar 2003 19:40:19 +0000 (19:40 +0000)]
M PyShell.py
M run.py
1. Move subprocess socket handling to a subthread - "SockThread".
2. In the subprocess, implement a queue and global completion and exit
flags. Execute code after it is passed through the queue. (Currently,
user code is executed in SockThread. The next phase of development will
move the tail of the queue to MainThread.)
3. Implement an RPC message used to shut down the execution server.
4. Improve normal and exception subprocess exits.
(At this checkin a "pass loop" interrupt doesn't work on any platform. It
will be restored for all platforms once user code execution is moved to
MainThread.)
Neal Norwitz [Sat, 22 Mar 2003 16:35:37 +0000 (16:35 +0000)]
Include Python.h first which defines _XOPEN_SOURCE
which allows the file to compile and removes a warning about _XOPEN_SOURCE
being redefined (works on AIX 4.3 and 5.1 at least).