python - ImportError: No module named cryptography.hazmat.backends - boxsdk on Mac -
i'm trying automate upload of single file (for now) box python automation.
i'm using code box developers website supposed "super easy use" getting error (see title above) when try run simple program found on page: https://www.box.com/blog/introducing-box-python-sdk/ . i've added client id, client secret, , developer token, , added path zip file upload, , keep getting above error. havent changed beyond that.
code dont want click link :)
from boxsdk import client, oauth2 oauth = oauth2( client_id="your_client_id", client_secret="your_client_secret", access_token="your_developer_token", ) client = client(oauth) shared_folder = client.folder( folder_id='0', ).create_subfolder('shared_folder') uploaded_file = shared_folder.upload('/path/to/file') shared_link = shared_folder.get_shared_link()
i've installed cryptography program using pip , easy_install sure, along libffi , openssl , oauth2 safe , nothing works. can me?
thanks, gary
this error has nothing boxsdk
library 1 of dependency: cryptography
.
most of time, happens because cryptography
library install failed. of time, failed because libffi not installed default on computers.
if you're using brew, go in terminal , type brew install libffi
then reinstall cryptography
or boxsdk
pip
:
pip install cryptography --force-reinstall
Comments
Post a Comment