- 19 Mar, 2018 40 commits
-
-
David Wilson authored
Doesn't yet implement the rules in the docs, but I think the doc rules could maybe change to match this. Needs lots of cleanup work and thorough testing, but this is a great start.
-
David Wilson authored
-
David Wilson authored
-
David Wilson authored
-
David Wilson authored
-
David Wilson authored
* Don't implement the rules for when preloading occurs yet * Don't attempt to streamily preload modules downstream while this context hasn't yet received the final module. There is quite significant latency buried in here, but for now it's a lot of work to fix. This works well enough to handle at least the mitogen package, but it's likely broken for anything bigger.
-
David Wilson authored
-
David Wilson authored
-
David Wilson authored
-
David Wilson authored
For gevent, just as in 5f7633cd569f671750ea7f35f6ca79118b345205
-
David Wilson authored
It seems gevent automatically sets blocking behaviour on fds produced by the socket module, which causes the Python process we fork to fail horribly. So in the child, always reset the blocking flag.
-
David Wilson authored
-
David Wilson authored
..and enable privileged=True since that's needed for ptrace()
-
David Wilson authored
-
David Wilson authored
Closes #70
-
David Wilson authored
Either execvp succeeds, in which case the process image is replaced, or execvp throws an exception, in which case control flow exits the frame anyway.
-
David Wilson authored
-
David Wilson authored
-
David Wilson authored
-
David Wilson authored
-
David Wilson authored
-
David Wilson authored
-
Alex Willmer authored
-
Alex Willmer authored
e.g. assert x == y -> self.assertEqual(x, y); self.assertTrue(isinstance(x, y)) -> self.assertIsInstance(x, y) These specific methods give more useful errors in the case of a test failure.
-
Alex Willmer authored
-
Alex Willmer authored
This allows using features such as TestCase,assertIsInstance on Python 2.6 and earlier.
-
Alex Willmer authored
-
David Wilson authored
-
Alex Willmer authored
Although these are synonyms in Python 2.x, when using MyPy to typecheck code use of file() causes spurious errors. This commit also serves as one small step to Python 3.x compatibility, since 3.x removes the file() builtin.
-
Taihsiang Ho (tai271828) authored
We use test.sh to consolidate test cases in one file so the README would not be outdated easier rather than the hard-coded test commands in a code block.
-
R W H Bricheno authored
-
R W H Bricheno authored
-
David Wilson authored
-
Alex Willmer authored
On my laptop (Ubuntu 17.10, Python 2.7.14 in a virtualenv), `test_regular_mod` fails with ``` AssertionError: "\nimport sys\n\n\ndef say_hi():\n print 'hi'\n" != '\x03\xf3\r\n\xbbW\xd5Yc\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x00\x00@\x00\x00\x00s\x19\x00\x00\x00d\x00\x00d\x01\x00l\x00\x00Z\x00\x00d\x02\x00\x84\x00\x00Z\x01\x00d\x01\x00S(\x03\x00\x00\x00i\xff\xff\xff\xffNc\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00C\x00\x00\x00s\t\x00\x00\x00d\x01\x00GHd\x00\x00S(\x02\x00\x00\x00Nt\x02\x00\x00\x00hi(\x00\x00\x00\x00(\x00\x00\x00\x00(\x00\x00\x00\x00(\x00\x00\x00\x00sF\x00\x00\x00/home/alex/src/mitogen/tests/data/module_finder_testmod/regular_mod.pyt\x06\x00\x00\x00say_hi\x05\x00\x00\x00s\x02\x00\x00\x00\x00\x01(\x02\x00\x00\x00t\x03\x00\x00\x00sysR\x01\x00\x00\x00(\x00\x00\x00\x00(\x00\x00\x00\x00(\x00\x00\x00\x00sF\x00\x00\x00/home/alex/src/mitogen/tests/data/module_finder_testmod/regular_mod.pyt\x08\x00\x00\x00<module>\x02\x00\x00\x00s\x02\x00\x00\x00\x0c\x03' ``` `__file__` contains the path of the compiled `.pyc`, not the `.py` source file.
-
Alex Willmer authored
fixes #58
-
David Wilson authored
-
David Wilson authored
-
Alex Willmer authored
Since the above if block ends in a call to os.execv() this block will only ever run when the if condition was false. Hence putting it in an else clause is unnecessary.
-
Alex Willmer authored
-
Alex Willmer authored
-