Skip to content
This repository was archived by the owner on May 21, 2025. It is now read-only.

Pin protobuf version to 3.20.3 to fix an import error #366

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

james47
Copy link

@james47 james47 commented Oct 29, 2024

As title. This fixes the following:

ImportError                               Traceback (most recent call last)
[<ipython-input-1-84f0d6543138>](https://localhost:8080/#) in <cell line: 6>()
      4 import tensorflow_ranking as tfr
      5 import tensorflow_text as tf_text
----> 6 from tensorflow_serving.apis import input_pb2
      7 from google.protobuf import text_format

[/usr/local/lib/python3.10/dist-packages/tensorflow_serving/apis/input_pb2.py](https://localhost:8080/#) in <module>
      3 # source: tensorflow_serving/apis/input.proto
      4 """Generated protocol buffer code."""
----> 5 from google.protobuf.internal import builder as _builder
      6 from google.protobuf import descriptor as _descriptor
      7 from google.protobuf import descriptor_pool as _descriptor_pool

ImportError: cannot import name 'builder' from 'google.protobuf.internal' (/usr/local/lib/python3.10/dist-packages/google/protobuf/internal/__init__.py)```

Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant