New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upgrade oauth2client dependency to >2 to be compatible with google-api-python-client #355
Comments
oauth2client >= 2 introduced some backwards-incompatible changes, which is why gsutil didn't migrate immediately. The eventual plan is to migrate to oauthclient >= 2, but we don't have a timeline for that yet. |
Is it not possible to support both at the same time? for example, replace: from oauth2client.client import SignedJwtAssertionCredentials with from oauth2client.service_account import ServiceAccountCredentials (and change the credential creation calls to match the slightly different API) and elsewhere (the change required to enable version agnosticism from google-api-python-client): try:
from oauth2client.contrib.locked_file import LockedFile
except ImportError:
# oauth2client < 2.0.0
from oauth2client.locked_file import LockedFile I guess I should really be railing at the oauth2client folks for: |
We can try this approach, but there's no guarantee that the changes needed to support both versions in google-api-python-client are sufficient to cover all of gsutil's use cases. So it requires development and testing effort. |
Fair enough (super impressive reply speed btw) - you may find some useful pointers (amidst the grumbling at breakage) at googleapis/oauth2client#401 I was only trying to imply that it appears to be possible (seemingly they're not that different) rather than suggesting no work was required! |
Is there any workaround for this? As for now, it seems to be impossible to use both libraries in the same project? |
I'll be looking into the work required to bump the oauth2client version dependency to 4.X.X at some point in the near future, but I don't have any solid ETA to give at the moment. Just letting you know that it's on my radar :) |
can we close this now since 114fc88 updated things to 4.1.2 ? |
In
setup.py
gsutil
requiresoauth2client==1.5.2
. The latest version of google-api-python-client on pypi (version 1.5.0 at the time of reporting) requires oauth2client > 2.While it does look like this restriction has been removed in the latest version of setup.py - relevant commit it feels like it would be better to allow
gsutil
to work with later versions of oauth2client rather than force google-api-client to work with earlier ones.The text was updated successfully, but these errors were encountered: