Skip to content
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

Feature request: use pip extras for kms integration dependencies #14

Closed
darkvertex opened this issue Sep 4, 2023 · 2 comments
Closed
Assignees
Labels
enhancement New feature or request

Comments

@darkvertex
Copy link

What sort of feature would you like to see?

tink 1.7.0 was relatively lightweight to install:
https://github.com/google/tink/blob/1.7/python/requirements.txt
but 1.8.0 with its integrations with GCP and AWS KMS brings a lot of dependencies along with it:
https://github.com/tink-crypto/tink-py/blob/5934f47df29666ccadaa5ff4cc2ba626f82bcdf5/requirements.in

Would be really nice if pip "extras" were used in the tink python package so that we could select those as optional dependencies only if we needed them, ie to install them all it'd be something like:

pip install tink tink[gcpkms] tink[awskms]

Have you considered any alternative solutions?

I considered staying in 1.7.0 but a vulnerable protobuf lib is used so I prefer not to.

@morambro morambro self-assigned this Sep 5, 2023
@morambro
Copy link
Contributor

morambro commented Sep 5, 2023

Hi @darkvertex, the reason for these dependencies is that we have stopped depending on tink-cc-awskms and tink-cc-gcpkms for implementing KMS integrations, and instead use native Python implementations.

Would be really nice if pip "extras" were used in the tink python package so that we could select those as optional dependencies only if we needed them, ie to install them all it'd be something like:

pip install tink tink[gcpkms] tink[awskms]

Thanks for the suggestions, I'll look into this.

@morambro morambro added the enhancement New feature or request label Sep 5, 2023
copybara-service bot pushed a commit that referenced this issue Sep 15, 2023
This allows users that `pip install tink` to avoid taking extra KMS dependencies if they don't need them. KMS deps will need to be explicitly installed with `pip install tink[EXTENSION]`. When the extensions are not installed `import tink.integration.gcpkms` will raise an `ImportError` exception.

This change adds two extra requirements files and generates `requirements.txt` and `requirements_all.txt` from setup.py.

#14

PiperOrigin-RevId: 565596390
Change-Id: Ieff34f9a53f455f52425b56871d3e22acedb5eb9
@morambro
Copy link
Contributor

This is now in 1.9.0

tholenst pushed a commit to tink-crypto/tink that referenced this issue Dec 4, 2023
This allows users that `pip install tink` to avoid taking extra KMS dependencies if they don't need them. KMS deps will need to be explicitly installed with `pip install tink[EXTENSION]`. When the extensions are not installed `import tink.integration.gcpkms` will raise an `ImportError` exception.

This change adds two extra requirements files and generates `requirements.txt` and `requirements_all.txt` from setup.py.

tink-crypto/tink-py#14

PiperOrigin-RevId: 565596390
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants