boxsdk 1.x does not import in python 3.6.0
See original GitHub issueRunning a simple script in Python 3.6.0 fails to import the boxsdk module:
Traceback (most recent call last):
File "sources/box.py", line 1, in <module>
from boxsdk import OAuth2, Client
File "/usr/local/lib/python3.6/site-packages/boxsdk/__init__.py", line 6, in <module>
from .client import * # pylint:disable=wildcard-import,redefined-builtin
File "/usr/local/lib/python3.6/site-packages/boxsdk/client/__init__.py", line 5, in <module>
from .client import Client
File "/usr/local/lib/python3.6/site-packages/boxsdk/client/client.py", line 12, in <module>
from ..object.events import Events
File "/usr/local/lib/python3.6/site-packages/boxsdk/object/events.py", line 15, in <module>
class EventsStreamType(with_metaclass(ExtendableEnumMeta, TextEnum)):
File "/usr/local/Cellar/python3/3.6.0/Frameworks/Python.framework/Versions/3.6/lib/python3.6/enum.py", line 119, in __prepare__
member_type, first_enum = metacls._get_mixins_(bases)
File "/usr/local/Cellar/python3/3.6.0/Frameworks/Python.framework/Versions/3.6/lib/python3.6/enum.py", line 439, in _get_mixins_
raise TypeError("new enumerations must be created as "
TypeError: new enumerations must be created as `ClassName([mixin_type,] enum_type)`
This is on OS X Sierra, with the latest stable version (1.5.3). The script works fine in Python 3.5.2. Tox tests also fail on the 1.5.3 tag, but run cleanly on HEAD.
Issue Analytics
- State:
- Created 7 years ago
- Comments:7 (5 by maintainers)
Top Results From Across the Web
boxsdk demo/auth.py fails on from boxsdk import OAuth2
Tried to run authenticate() within boxsdk: demo/auth.py and get ... boxsdk 1.x does not import in python 3.6.0 · Issue #195 · box/box...
Read more >Python 3 boxsdk - Box Support
File "boxInit.py", line 1, in from boxsdk import OAuth2, Client ModuleNotFoundError: No module named 'boxsdk'.
Read more >What's New In Python 3.6 — Python 3.11.1 documentation
Import now raises the new exception ModuleNotFoundError (subclass of ImportError ) when it cannot find a module. Code that currently checks for ImportError...
Read more >Box SDK for Python - Morioh
Box SDK for Python, The current version of the SDK is v3.x --- With this release ... Or, if that doesn't work, file...
Read more >List of Packages - Anvil Docs
Due to running costs, Free Plan users can't enable the Full Python interpreter. You can still use any Python package you like on...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I think that would be wise, since this is an instant hard crash with the latest stable version. For now, specifying
boxsdk==2.0.0a4
in my pip requirements.txt does what I need it to do.The
boxsdk==2.0.0a4
workaround suggested by @incidentist works great, but this needs to be solved at priority.