if i use subprocess.Popen in any plugin i get this:
The easiest way to repro:
p = subprocess.Popen("echo", "1"], stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=True)
result, err = p.communicate()
print(result.decode("utf-8"))
print(err.decode("utf-8"))
The same code surely work with stock python 3.3
crash log:
Process: plugin_host [403]
Path: /Applications/Sublime Text.app/Contents/MacOS/plugin_host
Identifier: plugin_host
Version: ??? (???)
Code Type: X86-64 (Native)
Parent Process: plugin_host [393]
Date/Time: 2013-02-04 00:27:43.950 +0300
OS Version: Mac OS X 10.7.5 (11G63)
Report Version: 9
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Exception Codes: 0x0000000000000002, 0x0000000000000000
Application Specific Information:
objc[393]: garbage collection is OFF
Dyld Error Message:
Symbol not found: _dirfd
Referenced from: /Applications/Sublime Text.app/Contents/MacOS/plugin_host
Expected in: /usr/lib/libSystem.B.dylib
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 dyld 0x00007fff6b64606d dyld_fatal_error + 1
1 dyld 0x00007fff6b649948 dyld::fastBindLazySymbol(ImageLoader**, unsigned long) + 128
2 libdyld.dylib 0x00007fff8e563716 dyld_stub_binder_ + 13
3 ??? 0x000000010bd234c8 0 + 4493292744
4 plugin_host 0x000000010baff9cf PyEval_EvalFrameEx + 3237
5 plugin_host 0x000000010bafecef PyEval_EvalCodeEx + 1970
6 plugin_host 0x000000010bb07037 0x10ba45000 + 794679
7 plugin_host 0x000000010baffa80 PyEval_EvalFrameEx + 3414
8 plugin_host 0x000000010bafecef PyEval_EvalCodeEx + 1970
9 plugin_host 0x000000010ba991cd 0x10ba45000 + 344525
10 plugin_host 0x000000010ba7d661 PyObject_Call + 105
11 plugin_host 0x000000010ba8af44 0x10ba45000 + 286532
12 plugin_host 0x000000010ba7d661 PyObject_Call + 105
13 plugin_host 0x000000010babe38f 0x10ba45000 + 496527
14 plugin_host 0x000000010babaa4a 0x10ba45000 + 481866
15 plugin_host 0x000000010ba7d661 PyObject_Call + 105
16 plugin_host 0x000000010baffbbc PyEval_EvalFrameEx + 3730
17 plugin_host 0x000000010bb06fc7 0x10ba45000 + 794567
18 plugin_host 0x000000010baffa80 PyEval_EvalFrameEx + 3414
19 plugin_host 0x000000010bafecef PyEval_EvalCodeEx + 1970
20 plugin_host 0x000000010bb07037 0x10ba45000 + 794679
21 plugin_host 0x000000010baffa80 PyEval_EvalFrameEx + 3414
22 plugin_host 0x000000010bb06fc7 0x10ba45000 + 794567
23 plugin_host 0x000000010baffa80 PyEval_EvalFrameEx + 3414
24 plugin_host 0x000000010bafecef PyEval_EvalCodeEx + 1970
25 plugin_host 0x000000010ba991cd 0x10ba45000 + 344525
26 plugin_host 0x000000010ba7d661 PyObject_Call + 105
27 plugin_host 0x000000010ba8af44 0x10ba45000 + 286532
28 plugin_host 0x000000010ba7d661 PyObject_Call + 105
29 plugin_host 0x000000010bb0649f PyEval_CallObjectWithKeywords + 168
30 plugin_host 0x000000010ba508f8 void py_call<int, value>(_object*, char const*, int const&, value const&) + 138
31 plugin_host 0x000000010ba4a08c plugin_object_run(object_id, int, value const&) + 40
32 plugin_host 0x000000010ba5f3e3 void decode_message<int, object_id, int, value const&>(int ()(object_id, int, value const&), binary_input_stream&) + 174
33 plugin_host 0x000000010ba4a604 handle_protocol_message(string_buffer const&) + 520
34 plugin_host 0x000000010ba4a6fa run_shm_recv(void ) + 14
35 plugin_host 0x000000010ba6e353 basic_queue_runner::run() + 273
36 plugin_host 0x000000010ba4a905 main + 459
37 plugin_host 0x000000010ba45f04 start + 52