This repository was archived by the owner on Mar 3, 2023. It is now read-only.
protocol buffer version mismatch on import opendp.smartnoise.core #117
Open
Description
In analysis/tutorial_mental_health_in_tech_survey.ipynb
I can't get beyond
import opendp.smartnoise.core as sn
I can provide the full logs, but the abbreviated version is
File [~/.pyenv/versions/3.10.6/lib/python3.10/site-packages/opendp/smartnoise/core/base.py:4](https://file+.vscode-resource.vscode-cdn.net/Users/jeffrey/src/github.com/opendp/smartnoise-samples/analysis/~/.pyenv/versions/3.10.6/lib/python3.10/site-packages/opendp/smartnoise/core/base.py:4)
1 import json
2 import warnings
----> 4 from .api import LibraryWrapper, format_error
5 from .value import *
7 import typing
File [~/.pyenv/versions/3.10.6/lib/python3.10/site-packages/opendp/smartnoise/core/api.py:8](https://file+.vscode-resource.vscode-cdn.net/Users/jeffrey/src/github.com/opendp/smartnoise-samples/analysis/~/.pyenv/versions/3.10.6/lib/python3.10/site-packages/opendp/smartnoise/core/api.py:8)
5 import re
...
If you cannot immediately regenerate your protos, some other possible workarounds are:
1. Downgrade the protobuf package to 3.20.x or lower.
2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).
More information: https://developers.google.com/protocol-buffers/docs/news/2022-05-06#python-updates
I should note that because I am working on. Apple arm64, I could not use the requirements.txt
file as provided. (See #116). So while I understand that the requirements are frozen for the samples and notebooks, it would be nice to freeze on a version that works for macOS arm64.
Metadata
Metadata
Assignees
Labels
No labels