Token file XXXXXX
==69239== Invalid read of size 4
==69239== at 0x10074D066: _PyObject_Free (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007AC49B: PyEval_EvalFrameEx (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007AF6DF: _PyEval_EvalCodeWithName (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007A6AC6: PyEval_EvalCodeEx (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x100731B9F: function_call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10071004D: PyObject_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x100722787: method_call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10071004D: PyObject_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10075A968: slot_tp_init (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x100757CED: type_call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10071004D: PyObject_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007ABFB6: PyEval_EvalFrameEx (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== Address 0x103845020 is 1,744 bytes inside a block of size 1,777 free'd
==69239== at 0x10000A920: realloc (in /opt/boxen/homebrew/Cellar/valgrind/3.11.0/lib/valgrind/vgpreload_memcheck-amd64-darwin.so)
==69239== by 0x100719BD1: _PyBytes_Resize (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10080DDA9: _io_FileIO_readall_impl (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007489C4: PyCFunction_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10071004D: PyObject_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007106DD: PyObject_CallMethodObjArgs (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x100811088: _io__Buffered_read (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007489C4: PyCFunction_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007AC25A: PyEval_EvalFrameEx (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007AF6DF: _PyEval_EvalCodeWithName (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007A6AC6: PyEval_EvalCodeEx (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x100731B9F: function_call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== Block was alloc'd at
==69239== at 0x100009EBB: malloc (in /opt/boxen/homebrew/Cellar/valgrind/3.11.0/lib/valgrind/vgpreload_memcheck-amd64-darwin.so)
==69239== by 0x10074D633: _PyObject_Alloc (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10071928E: _PyBytes_FromSize (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007191C9: PyBytes_FromStringAndSize (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10080DCBE: _io_FileIO_readall_impl (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007489C4: PyCFunction_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10071004D: PyObject_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007106DD: PyObject_CallMethodObjArgs (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x100811088: _io__Buffered_read (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007489C4: PyCFunction_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007AC25A: PyEval_EvalFrameEx (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007AF6DF: _PyEval_EvalCodeWithName (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239==
Encoded tag XXXX
Decrypted Token: XXXXX
line 164
Decoded token: {'user': 'jimmy'}
==69239== Warning: set address range perms: large range [0x2393dc040, 0xa711441e0) (undefined)
==69239== Invalid read of size 4
==69239== at 0x106F63119: general_invoke_callback (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/_cffi_backend.cpython-35m-darwin.so)
==69239== by 0x106F64366: cffi_call_python (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/_cffi_backend.cpython-35m-darwin.so)
==69239== by 0x1076C4A24: Cryptography_locking_cb (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/cryptography/hazmat/bindings/_openssl.cpython-35m-darwin.so)
==69239== by 0x107586776: CRYPTO_add_lock (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/cryptography/hazmat/bindings/_openssl.cpython-35m-darwin.so)
==69239== by 0x10762FB6F: EVP_PKEY_free (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/cryptography/hazmat/bindings/_openssl.cpython-35m-darwin.so)
==69239== by 0x1076DDC56: _cffi_f_EVP_PKEY_free (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/cryptography/hazmat/bindings/_openssl.cpython-35m-darwin.so)
==69239== by 0x1007489C4: PyCFunction_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10071004D: PyObject_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10070D0E3: PyObject_CallFunctionObjArgs (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x106F64B05: gcp_finalize (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/_cffi_backend.cpython-35m-darwin.so)
==69239== by 0x1007E0B03: collect (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007E0434: _PyGC_CollectNoFail (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== Address 0x50 is not stack'd, malloc'd or (recently) free'd
==69239==
==69239==
==69239== Process terminating with default action of signal 11 (SIGSEGV)
==69239== Access not within mapped region at address 0x50
==69239== at 0x106F63119: general_invoke_callback (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/_cffi_backend.cpython-35m-darwin.so)
==69239== by 0x106F64366: cffi_call_python (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/_cffi_backend.cpython-35m-darwin.so)
==69239== by 0x1076C4A24: Cryptography_locking_cb (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/cryptography/hazmat/bindings/_openssl.cpython-35m-darwin.so)
==69239== by 0x107586776: CRYPTO_add_lock (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/cryptography/hazmat/bindings/_openssl.cpython-35m-darwin.so)
==69239== by 0x10762FB6F: EVP_PKEY_free (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/cryptography/hazmat/bindings/_openssl.cpython-35m-darwin.so)
==69239== by 0x1076DDC56: _cffi_f_EVP_PKEY_free (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/cryptography/hazmat/bindings/_openssl.cpython-35m-darwin.so)
==69239== by 0x1007489C4: PyCFunction_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10071004D: PyObject_Call (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x10070D0E3: PyObject_CallFunctionObjArgs (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x106F64B05: gcp_finalize (in /Users/danhilton/.virtualenvs/eq-survey-runner/lib/python3.5/site-packages/_cffi_backend.cpython-35m-darwin.so)
==69239== by 0x1007E0B03: collect (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== by 0x1007E0434: _PyGC_CollectNoFail (in /opt/boxen/homebrew/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/Python)
==69239== If you believe this happened as a result of a stack
==69239== overflow in your program's main thread (unlikely but
==69239== possible), you can try to increase the size of the
==69239== main thread stack using the --main-stacksize= flag.
==69239== The main thread stack size used in this run was 16777216.
==69239==
==69239== HEAP SUMMARY:
==69239== in use at exit: 35,314,669,086 bytes in 16,212 blocks
==69239== total heap usage: 64,790 allocs, 48,578 frees, 35,476,247,282 bytes allocated
==69239==
^C
^D
exit
quit
^C
pause break
^[[21~^[[21~==69239== LEAK SUMMARY:
==69239== definitely lost: 146,641 bytes in 113 blocks
==69239== indirectly lost: 167,492 bytes in 5,364 blocks
==69239== possibly lost: 91,670 bytes in 205 blocks
==69239== still reachable: 35,314,204,190 bytes in 10,359 blocks
==69239== suppressed: 59,093 bytes in 171 blocks
==69239== Rerun with --leak-check=full to see details of leaked memory
==69239==
==69239== For counts of detected and suppressed errors, rerun with: -v
==69239== Use --track-origins=yes to see where uninitialised values come from
==69239== ERROR SUMMARY: 1617 errors from 113 contexts (suppressed: 0 from 0)
[1] 69239 segmentation fault valgrind python jwt_tester.py
We've run this on multiple different machines, and clean virtualenv environments. We're porting this code from python2.7 to python3.5, where we had no issues on python2.7.
Any ideas as to why this is happening? Anything else I can add to this bug report to help?
This code here: https://github.com/ONSdigital/eq-survey-runner/blob/jwt/jwt_tester.py
Runs fine under 1.1.2 but segfaults under 1.2.1 (valgrind details):
We've run this on multiple different machines, and clean virtualenv environments. We're porting this code from python2.7 to python3.5, where we had no issues on python2.7.
Any ideas as to why this is happening? Anything else I can add to this bug report to help?
Cheers for the help!