Error processing msg(799, 1, None)
Kos opened this issue · 5 comments
Error processing msg(799, 1, None)
I'm getting this WinAPI error for a hello world project, both calling python setup.py zen
and pyzen filewithtests.py
.
More detailed info:
For a simple pyzen filewithtests.py
the runner icon in the tray appears and says "Ran 0 tests in 0.004 seconds". (There are tests in the file.) The message I mentioned is the only one in the console.
For python setup.py zen
, this loops twice a second:
running zen
running egg_info
writing foo.egg-info\PKG-INFO
writing top-level names to foo.egg-info\top_level.txt
writing dependency_links to foo.egg-info\dependency_links.txt
reading manifest file 'foo.egg-info\SOURCES.txt'
writing manifest file 'foo.egg-info\SOURCES.txt'
running build_ext
Error processing msg(799, 1, None)
Icon in tray appears but stays silent.
python setup.py test
(Distribute) picks up tests correctly from test_suite
config option. (In case pyzen doesn't grok setuptools, I've also attempted to make a setup.py with distutils, but in turn it just said invalid command 'zen'
.
Python 2.7.2 32-bit on win7 x64.
Let me know how I can be of further assistance.
At least as far as the internet knows, 0x31F doesn't correspond to any documented WM_ message. I no longer have access to a Windows development environment so I can't check myself. As for the different test discovery options, I would need to know a lot more about project setup and what testing libraries you are using.
The test setup I tried was simply
from setuptools import setup
setup(name='foo',
py_modules=['foo'],
version='1.0',
test_suite='bar'
)
I'm also interested how to make pyzen go with nosetests runner. But let's not mix things for now.
PDB says that the exception is thrown from IsDialogMessage
, the exception is simply
WindowsError('exception: access violation writing 0x00000001',)
I'm not sure how that helps. Are the ctypes bindings trustworthy? Can we rule out some kind of binary layout mismatch that would make 0x31F pop out randomly?
It does happen from time to time that Windows sends weird internal messages, should be harmless I hope. It sounds like your problem is just that the zen runner isn't finding any tests. Is the code you are using this with anywhere I can see it? What I usually use is
zip_safe = False,
tests_require = ['unittest2', 'mock'],
test_suite = 'unittest2.collector',
I haven't had more success with unittest2 than with unittest or nose. Here's what I tried with unittest2.
python setup.py test
picks up the tests, but python setup.py zen
loops with output like:
running zen
running egg_info
writing foo.egg-info\PKG-INFO
writing top-level names to foo.egg-info\top_level.txt
writing dependency_links to foo.egg-info\dependency_links.txt
reading manifest file 'foo.egg-info\SOURCES.txt'
writing manifest file 'foo.egg-info\SOURCES.txt'
running build_ext
Error processing msg(799, 1, None)
running zen
running egg_info
I've also attempted running modules directly through pyzen testpackage/test.py
- the UI starts and notifies that "Ran 0 tests in 0.004 seconds", and the console shows the 799 message.
I've tried to modify wrappers.py
and throw in a simple
if msg.message == 799:
continue
to avoid the access violation with IsDialogMessage
, but this didn't change a thing safe for making the message go away.
Running on my machine:
1 [foo-0.0.0] [@oc] coderanger@tome ~/Downloads/foo-0.0.0
$ python setup.py zen
running zen
running egg_info
writing foo.egg-info/PKG-INFO
writing top-level names to foo.egg-info/top_level.txt
writing dependency_links to foo.egg-info/dependency_links.txt
reading manifest file 'foo.egg-info/SOURCES.txt'
writing manifest file 'foo.egg-info/SOURCES.txt'
running build_ext
testOne (testpackage.test.Test) ... ok
testTwo (testpackage.test.Test) ... FAIL
======================================================================
FAIL: testTwo (testpackage.test.Test)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/Users/coderanger/Downloads/foo-0.0.0/testpackage/test.py", line 10, in testTwo
assert False
AssertionError
----------------------------------------------------------------------
Ran 2 tests in 0.000s
FAILED (failures=1)
including the correct colors and whatnot.