You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What version of protobuf and what language are you using?
Version: any version, that uses the CPP extension module i.e. 3.7.1
Language: Stackless Python
What operating system (Linux, Windows, ...) and version?
Not relevant
What runtime / compiler are you using (e.g., python version or gcc version)
Not relevant
I recently encountered an error while using Protobuf Python extension module. tdryer/hangups#451 (comment)
Not sure it is relevant to this discussion, but I consider it necessary to inform you.
What version of protobuf and what language are you using?
Version: any version, that uses the CPP extension module i.e. 3.7.1
Language: Stackless Python
What operating system (Linux, Windows, ...) and version?
Not relevant
What runtime / compiler are you using (e.g., python version or gcc version)
Not relevant
What did you do?
Steps to reproduce the behavior:
$ python -m pip install protobuf
What did you expect to see
TypeError: Descriptors should not be created directly, but only retrieved from their parent.
What did you see instead?
Segmentation fault (core dumped)
Anything else we should know about your project / environment
The segmentation fault is caused by the following line of code:
protobuf/python/google/protobuf/pyext/descriptor.cc
Line 114 in 6973c3a
The problem is, that protobuf uses the structure PyFrameObject (
frame->f_code
) which is not part of the C-Python ABI and differs between C-Python and Stackless Python. See https://github.com/stackless-dev/stackless/wiki/Portable-usage-of-PyFrameObject for details.Merging pull request #5171 would fix the problem.
Another option is compute the offset of the field
f_code
at runtime. Use the macroPYFRAME_CODE(frame)
from https://github.com/stackless-dev/stackless/wiki/Portable-usage-of-PyFrameObject.Work arounds
The text was updated successfully, but these errors were encountered: