makepy crashing

M

markscottwright

Has anyone sucessfully run makepy and Microsoft Word Object Library
(9.0)? Mine crashes under XP Pro and Python 2.4.

It only seems to be word that has the problem, though.

I get a dialog that says that pythonwin.exe has crashed:
AppName: pythonwin.exe AppVer: 0.0.0.0 ModName: ntdll.dll
ModVer: 5.1.2600.1217 Offset: 000096f9
 
R

Roger Upole

Looks like the makepy step creates the generated file successfully,
but python is choking with an assertion failure on lines longer than
512 when it tries to import it.

This is the line it was processing when it died:
def GetSpellingSuggestions(self, Word=defaultNamedNotOptArg,
CustomDictionary=defaultNamedOptArg, IgnoreUppercase=defaultNamedOptArg,
MainDictionary=defaultNamedOptArg, SuggestionMode=defaultNamedOptArg,
CustomDictionary2=defaultNamedOptArg, CustomDictionary3=defaultNamedOptArg,
CustomDictionary4=defaultNamedOptArg, CustomDictionary5=defaultNamedOptArg,
CustomDictionary6=defaultNamedOptArg, CustomDictionary7=defaultNamedOptArg,
CustomDictionary8=defaultNamedOptArg, CustomDictionary9=defaultNamedOptArg,
CustomDictionary10=defaultNamedOptArg):

You might be able to do a workaround by hacking genpy.py and replacing the
default....Arg names with something shorter.
....Nope, there are a few other lines that exceed 512.

I think it's a problem with the encoding. If you remove the mbcs tag
(# -*- coding: mbcs -*-) from the top of the generated file, the import
succeeds.

Roger
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,777
Messages
2,569,604
Members
45,218
Latest member
JolieDenha

Latest Threads

Top