Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#54469 closed defect (invalid)

problem using python 3.6 in Sierra 10.12.5/Xcode 8.3.3

Reported by: lpagani91 Owned by: jyrkiwahlstedt
Priority: Normal Milestone:
Component: ports Version: 2.4.1
Keywords: Cc:
Port: python36

Description (last modified by mf2k (Frank Schima))

Python 3.5 + pip + setuptools now work on my Mac.

Lorenzo>python3.5
Python 3.5.3 (default, Apr 23 2017, 18:09:27) 
[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.42.1)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import pkg_resources
>>>

I uninstalled the 3.6 versions of all 3 packages (python, pip, setuptolls) and reinstalled them. Everything OK but when I try to use python 3.6 it crashes :

Lorenzo>python3.6
Python 3.6.1 (default, Apr 24 2017, 06:18:27) 
[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.42.1)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import pkg_resources
Python(96720,0x7fffcc2cc3c0) malloc: *** error for object 0x101789318: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug
Abort

Change History (6)

comment:1 Changed 7 years ago by mf2k (Frank Schima)

Cc: jwa@… removed
Owner: set to jyrkiwahlstedt
Status: newassigned

In the future, please use WikiFormatting.

comment:2 Changed 7 years ago by mf2k (Frank Schima)

Description: modified (diff)

comment:3 Changed 7 years ago by mf2k (Frank Schima)

Resolution: invalid
Status: assignedclosed

Here is what I see when I run it:

$ python3.6
Python 3.6.1 (default, May 31 2017, 15:24:41) 
[GCC 4.2.1 Compatible Apple LLVM 8.1.0 (clang-802.0.42)] on darwin

Both your python36 port and Xcode appear to be out of date. Based on this wiki page, you are running Xcode 8.2.1.

comment:4 Changed 7 years ago by mf2k (Frank Schima)

To clarify, your Xcode command line tools are out of date. Did you follow the wiki:Migration Instructions?

comment:5 Changed 7 years ago by bdbaddog

I'm seeing the same issue with python 3.6.2.

$ python3.6
Python 3.6.2 (default, Jul 22 2017, 21:38:57)
[GCC 4.2.1 Compatible Apple LLVM 8.1.0 (clang-802.0.42)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> Python(18886,0x7fffa17c33c0) malloc: *** error for object 0x109891640: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug
Abort trap: 6

$ xcode-select --install
xcode-select: error: command line tools are already installed, use "Software Update" to install updates

$ python3.6
Python 3.6.2 (default, Jul 22 2017, 21:38:57)
[GCC 4.2.1 Compatible Apple LLVM 8.1.0 (clang-802.0.42)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import pkg_resources
Python(18913,0x7fffa17c33c0) malloc: *** error for object 0x1056b0300: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug
Abort trap: 6


Stacktrace from problem report dialog

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   libsystem_kernel.dylib        	0x00007fff989ddd42 __pthread_kill + 10
1   libsystem_pthread.dylib       	0x00007fff98acb457 pthread_kill + 90
2   libsystem_c.dylib             	0x00007fff98943420 abort + 129
3   libsystem_malloc.dylib        	0x00007fff98a32fe7 free + 530
4   org.python.python             	0x000000010cef2152 PyOS_Readline + 285
5   org.python.python             	0x000000010cf8a6a4 builtin_input + 1232
6   org.python.python             	0x000000010cf30099 _PyCFunction_FastCallDict + 166
7   org.python.python             	0x000000010cf942fb call_function + 489
8   org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
9   org.python.python             	0x000000010cf94acb _PyEval_EvalCodeWithName + 1829
10  org.python.python             	0x000000010cf951b7 fast_function + 227
11  org.python.python             	0x000000010cf942d2 call_function + 448
12  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
13  org.python.python             	0x000000010cf95452 _PyFunction_FastCall + 121
14  org.python.python             	0x000000010cf942d2 call_function + 448
15  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
16  org.python.python             	0x000000010cf95452 _PyFunction_FastCall + 121
17  org.python.python             	0x000000010cf942d2 call_function + 448
18  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
19  org.python.python             	0x000000010cf95452 _PyFunction_FastCall + 121
20  org.python.python             	0x000000010cf942d2 call_function + 448
21  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
22  org.python.python             	0x000000010cf95452 _PyFunction_FastCall + 121
23  org.python.python             	0x000000010cf942d2 call_function + 448
24  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
25  org.python.python             	0x000000010cf95452 _PyFunction_FastCall + 121
26  org.python.python             	0x000000010cef84b9 _PyObject_FastCallDict + 196
27  org.python.python             	0x000000010cef85dc _PyObject_Call_Prepend + 156
28  org.python.python             	0x000000010cef8484 _PyObject_FastCallDict + 143
29  org.python.python             	0x000000010cfbbd23 call_trampoline + 108
30  org.python.python             	0x000000010cfbbd89 trace_trampoline + 34
31  org.python.python             	0x000000010cf92144 _PyEval_EvalFrameDefault + 23554
32  org.python.python             	0x000000010cf95452 _PyFunction_FastCall + 121
33  org.python.python             	0x000000010cf942d2 call_function + 448
34  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
35  org.python.python             	0x000000010cf94acb _PyEval_EvalCodeWithName + 1829
36  org.python.python             	0x000000010cf95382 _PyFunction_FastCallDict + 444
37  org.python.python             	0x000000010cef84b9 _PyObject_FastCallDict + 196
38  org.python.python             	0x000000010cef85dc _PyObject_Call_Prepend + 156
39  org.python.python             	0x000000010cef833a PyObject_Call + 101
40  org.python.python             	0x000000010cf8d931 _PyEval_EvalFrameDefault + 5103
41  org.python.python             	0x000000010cf94acb _PyEval_EvalCodeWithName + 1829
42  org.python.python             	0x000000010cf95382 _PyFunction_FastCallDict + 444
43  org.python.python             	0x000000010cef84b9 _PyObject_FastCallDict + 196
44  org.python.python             	0x000000010cef85dc _PyObject_Call_Prepend + 156
45  org.python.python             	0x000000010cef833a PyObject_Call + 101
46  org.python.python             	0x000000010cf429a2 slot_tp_call + 50
47  org.python.python             	0x000000010cef8484 _PyObject_FastCallDict + 143
48  org.python.python             	0x000000010cf942cb call_function + 441
49  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
50  org.python.python             	0x000000010cf94acb _PyEval_EvalCodeWithName + 1829
51  org.python.python             	0x000000010cf95382 _PyFunction_FastCallDict + 444
52  org.python.python             	0x000000010cef84b9 _PyObject_FastCallDict + 196
53  org.python.python             	0x000000010cef85dc _PyObject_Call_Prepend + 156
54  org.python.python             	0x000000010cef833a PyObject_Call + 101
55  org.python.python             	0x000000010cf8d931 _PyEval_EvalFrameDefault + 5103
56  org.python.python             	0x000000010cf94acb _PyEval_EvalCodeWithName + 1829
57  org.python.python             	0x000000010cf95382 _PyFunction_FastCallDict + 444
58  org.python.python             	0x000000010cef84b9 _PyObject_FastCallDict + 196
59  org.python.python             	0x000000010cef85dc _PyObject_Call_Prepend + 156
60  org.python.python             	0x000000010cef833a PyObject_Call + 101
61  org.python.python             	0x000000010cf429a2 slot_tp_call + 50
62  org.python.python             	0x000000010cef8484 _PyObject_FastCallDict + 143
63  org.python.python             	0x000000010cf942cb call_function + 441
64  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
65  org.python.python             	0x000000010cf94acb _PyEval_EvalCodeWithName + 1829
66  org.python.python             	0x000000010cf95382 _PyFunction_FastCallDict + 444
67  org.python.python             	0x000000010cef84b9 _PyObject_FastCallDict + 196
68  org.python.python             	0x000000010cef85dc _PyObject_Call_Prepend + 156
69  org.python.python             	0x000000010cef833a PyObject_Call + 101
70  org.python.python             	0x000000010cf8d931 _PyEval_EvalFrameDefault + 5103
71  org.python.python             	0x000000010cf94acb _PyEval_EvalCodeWithName + 1829
72  org.python.python             	0x000000010cf95382 _PyFunction_FastCallDict + 444
73  org.python.python             	0x000000010cef84b9 _PyObject_FastCallDict + 196
74  org.python.python             	0x000000010cef85dc _PyObject_Call_Prepend + 156
75  org.python.python             	0x000000010cef833a PyObject_Call + 101
76  org.python.python             	0x000000010cf429a2 slot_tp_call + 50
77  org.python.python             	0x000000010cef8484 _PyObject_FastCallDict + 143
78  org.python.python             	0x000000010cf942cb call_function + 441
79  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
80  org.python.python             	0x000000010cf95452 _PyFunction_FastCall + 121
81  org.python.python             	0x000000010cf942d2 call_function + 448
82  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
83  org.python.python             	0x000000010cf95452 _PyFunction_FastCall + 121
84  org.python.python             	0x000000010cf942d2 call_function + 448
85  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
86  org.python.python             	0x000000010cf94acb _PyEval_EvalCodeWithName + 1829
87  org.python.python             	0x000000010cf95382 _PyFunction_FastCallDict + 444
88  org.python.python             	0x000000010cef84b9 _PyObject_FastCallDict + 196
89  org.python.python             	0x000000010cef85dc _PyObject_Call_Prepend + 156
90  org.python.python             	0x000000010cef833a PyObject_Call + 101
91  org.python.python             	0x000000010cf432ce slot_tp_init + 57
92  org.python.python             	0x000000010cf4021a type_call + 184
93  org.python.python             	0x000000010cef8484 _PyObject_FastCallDict + 143
94  org.python.python             	0x000000010cf942cb call_function + 441
95  org.python.python             	0x000000010cf8d6d4 _PyEval_EvalFrameDefault + 4498
96  org.python.python             	0x000000010cf94acb _PyEval_EvalCodeWithName + 1829
97  org.python.python             	0x000000010cf8c4cd PyEval_EvalCode + 43
98  org.python.python             	0x000000010cfb3546 run_mod + 54
99  org.python.python             	0x000000010cfb3826 PyRun_FileExFlags + 180
100 org.python.python             	0x000000010cfb2db3 PyRun_SimpleFileExFlags + 280
101 org.python.python             	0x000000010cfc6b64 Py_Main + 3268
102 org.python.python             	0x000000010ceeae1d 0x10cee9000 + 7709
103 libdyld.dylib                 	0x00007fff988af235 start + 1

comment:6 Changed 7 years ago by raimue (Rainer Müller)

Uninstall the py36-readline port and install python36 +readline if you need it, see #48807. There is a long-standing bug in Python that makes it crash in that configuration.

Note: See TracTickets for help on using tickets.