Skip to content
Snippets Groups Projects
Commit 7e7d452c authored by Martin Blanchard's avatar Martin Blanchard
Browse files

setup.py: Introduce pyjwt dependency

Hosted at: https://github.com/jpadilla/pyjwt

The dependency is declared as part of a new 'auth' extra target so that
it is not installed by default, but only if requested.

#144
parent 8f5d71c5
Branches
No related tags found
Loading
...@@ -186,7 +186,8 @@ ignore-on-opaque-inference=yes ...@@ -186,7 +186,8 @@ ignore-on-opaque-inference=yes
# qualified names. # qualified names.
ignored-classes=google.protobuf.any_pb2.Any, ignored-classes=google.protobuf.any_pb2.Any,
google.protobuf.duration_pb2.Duration, google.protobuf.duration_pb2.Duration,
google.protobuf.timestamp_pb2.Timestamp google.protobuf.timestamp_pb2.Timestamp,
jwt
# List of module names for which member attributes should not be checked # List of module names for which member attributes should not be checked
# (useful for modules/projects where namespaces are manipulated during runtime # (useful for modules/projects where namespaces are manipulated during runtime
...@@ -462,6 +463,7 @@ known-third-party=boto3, ...@@ -462,6 +463,7 @@ known-third-party=boto3,
google, google,
grpc, grpc,
janus, janus,
jwt,
moto, moto,
yaml yaml
......
...@@ -59,20 +59,20 @@ have to adjust your ``PATH``, in ``~/.bashrc``, with: ...@@ -59,20 +59,20 @@ have to adjust your ``PATH``, in ``~/.bashrc``, with:
.. note:: .. note::
The ``setup.py`` script defines two extra targets, ``docs`` and ``tests``, The ``setup.py`` script defines three extra targets, ``auth``, ``docs`` and
that declare required dependency for, respectively, generating documentation ``tests``. They declare required dependency for, respectively, authentication
and running unit-tests. They can be use as helpers for setting up a and authorization management, generating documentation and running
development environment. To use them simply run: unit-tests. They can be use as helpers for setting up a development
environment. To use them simply run:
.. code-block:: sh .. code-block:: sh
pip3 install --user --editable ".[docs,tests]" pip3 install --user --editable ".[auth,docs,tests]"
.. install-docker: .. install-docker:
Installation through docker Installation through Docker
--------------------------- ---------------------------
How to build a Docker image that runs BuildGrid. How to build a Docker image that runs BuildGrid.
......
...@@ -85,6 +85,11 @@ def get_cmdclass(): ...@@ -85,6 +85,11 @@ def get_cmdclass():
} }
return cmdclass return cmdclass
auth_require = [
'cryptography >= 1.8.0', # Required by pyjwt for RSA
'pyjwt >= 1.5.0',
]
tests_require = [ tests_require = [
'coverage >= 4.5.0', 'coverage >= 4.5.0',
'moto < 1.3.7', 'moto < 1.3.7',
...@@ -130,6 +135,7 @@ setup( ...@@ -130,6 +135,7 @@ setup(
setup_requires=['pytest-runner'], setup_requires=['pytest-runner'],
tests_require=tests_require, tests_require=tests_require,
extras_require={ extras_require={
'auth': auth_require,
'docs': docs_require, 'docs': docs_require,
'tests': tests_require, 'tests': tests_require,
}, },
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment