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
{{ message }}
Repository navigation
python CopyFrom segmentation fault on version 4.24.0 #13485
This is resulting on a segmentation fault on exactly the CopyFrom line.
This failure started with us picking up version 4.24.0 with yesterday's release. Reverting back to any version prior fixes the issue.
Unfortunately building the above example proto as an MVP did not repro the segmentation fault for me. If there are any diagnostics I can provide that would make root causing this easier, happy to help.
What did you expect to see
No seg fault, behavior as before.
What did you see instead?
Segmentation fault failure on CopyFrom
Make sure you include information that can help us debug (full error message, exception listing, stack trace, logs).
Anything else we should know about your project / environment
Just a thought, could it be that the protos that we're intending to use are "compiled" with a previous protoc version, and the issue is that this new version throws in that case? In our project, it was failing when trying to use some protos from a TensorFlow dependency (which was released before this new protobuf release from yesterday).
Can you help to verify:
1, Does the segment fault still raise if not depend on TensorFlow.
2, Does the segment fault still raise for the message that do not have map:
Just a thought, could it be that the protos that we're intending to use are "compiled" with a previous protoc version, and the issue is that this new version throws in that case? In our project, it was failing when trying to use some protos from a TensorFlow dependency (which was released before this new protobuf release from yesterday).
This might actually be possibly how it's happening, as I could not produce a simple repro outside of our internal product.
Can you help to verify: 1, Does the segment fault still raise if not depend on TensorFlow. 2, Does the segment fault still raise for the message that do not have map:
Can you help to verify: 1, Does the segment fault still raise if not depend on TensorFlow. 2, Does the segment fault still raise for the message that do not have map:
Thank you for these info. As both of you mentioned that the code is depending on old code gen, can you try if upgrade these gen files with newest protoc to see if it can resolve the issue?
Activity
arcra commentedon Aug 9, 2023
I've seen this issue with python 3.9 and 3.11 as well. It's blocking our project's CI runs.
Restricts protobuf dependency to < 4.24 due to protocolbuffers/protob…
Restricts protobuf dependency to < 4.24 due to protocolbuffers/protob…
anandolee commentedon Aug 9, 2023
Not sure why but I can NOT reproduce in google3 internal CL with
Nor opensource on my linux:
arcra commentedon Aug 9, 2023
Just a thought, could it be that the protos that we're intending to use are "compiled" with a previous protoc version, and the issue is that this new version throws in that case? In our project, it was failing when trying to use some protos from a TensorFlow dependency (which was released before this new protobuf release from yesterday).
python CopyFrom segmentation fault on version 4.24.0
anandolee commentedon Aug 9, 2023
Can you help to verify:
1, Does the segment fault still raise if not depend on TensorFlow.
2, Does the segment fault still raise for the message that do not have map:
3, Does the segment fault still raise for struct_pb2.Struct()
sfc-gh-mussakli commentedon Aug 10, 2023
This might actually be possibly how it's happening, as I could not produce a simple repro outside of our internal product.
I am working to answer your other questions, but I can confirm (1) that we do not depend on TensorFlow.
sfc-gh-mussakli commentedon Aug 10, 2023
Confirming for (3) that this does not fail with
struct_pb2.Struct()and removing for (2), the segmentation fault still occurs with no map.anandolee commentedon Aug 10, 2023
Thank you for these info. As both of you mentioned that the code is depending on old code gen, can you try if upgrade these gen files with newest protoc to see if it can resolve the issue?
22 remaining items
upb CopyFrom the default empty message should just clear instead of d…
upb CopyFrom the default empty message should just clear instead of d…
upb CopyFrom the default empty message should just clear instead of d…
upb CopyFrom the default empty message should just clear instead of d…
upb CopyFrom the default empty message should just clear instead of d…
upb CopyFrom the default empty message should just clear instead of d…
Test part: upb CopyFrom the default empty message should just clear i…
Test part: upb CopyFrom the default empty message should just clear i…
Test part: upb CopyFrom the default empty message should just clear i…
Test part: upb CopyFrom the default empty message should just clear i…
anandolee commentedon Aug 25, 2023
The issue should been fixed by #1514
25.0 will back to memory copy and no crash for copy the unsigned empty sub message
sfc-gh-mussakli commentedon Aug 25, 2023
@anandolee Thank you, this is great to hear!
Relaxes restriction on protobuf dep since issue was fixed. (#6660)
R-tensorflow: Autospec creation for update from version 2.14.0 to ver…