From d50c7e8a90427793fd3741566ad1bd862bc1d935 Mon Sep 17 00:00:00 2001 From: Chebrolu <bala-sai-harika.chebrolu@hpe.com> Date: Fri, 12 Nov 2021 11:51:32 +0530 Subject: [PATCH 1/6] Added support to additional APIs in SH --- endpoints-support.md | 11 ++- examples/server_hardware.py | 70 ++++++++++++++++ .../resources/servers/server_hardware.py | 79 ++++++++++++++++++- .../resources/servers/test_server_hardware.py | 58 +++++++++++++- 4 files changed, 214 insertions(+), 4 deletions(-) diff --git a/endpoints-support.md b/endpoints-support.md index 6e24ac24d..0a328fd1f 100755 --- a/endpoints-support.md +++ b/endpoints-support.md @@ -18,8 +18,8 @@ ## HPE OneView -| Endpoints | Verb | V800 | V1000 | V1200 | V1600 | V1800 | V2000 | V2200 | V2400 | V2600 | V2800 | V3000 | V3200 | -| --------------------------------------------------------------------------------------- | ------------------ | :------------------: | :------------------:| :------------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | +| Endpoints | Verb | V800 | V1000 | V1200 | V1600 | V1800 | V2000 | V2200 | V2400 | V2600 | V2800 | V3000 | V3200 | V3400 | +| --------------------------------------------------------------------------------------- | ------------------ | :------------------: | :------------------:| :------------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | :-----------------: | | **Appliance Configuration Timeconfig** |<sub>/rest/appliance/configuration/timeconfig/locales</sub> |GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | | **Appliance Node Information** @@ -360,6 +360,13 @@ |<sub>/rest/server-hardware/{id}/firmware</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | |<sub>/rest/server-hardware/discovery</sub> | POST | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | |<sub>/rest/server-hardware/{id}/localStorageV2</sub> | POST | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | +|<sub>/rest/server-hardware/{id}/chassis</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: | +|<sub>/rest/server-hardware/{id}/firmwareInventory</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: | +|<sub>/rest/server-hardware/{id}/networkAdapters</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: | +|<sub>/rest/server-hardware/{id}/powerSupplies</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: | +|<sub>/rest/server-hardware/{id}/processors</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: | +|<sub>/rest/server-hardware/{id}/softwareInventory</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: | +|<sub>/rest/server-hardware/{id}/thermal</sub> | GET | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :heavy_minus_sign: | :white_check_mark: | | **Server Hardware Types** |<sub>/rest/server-hardware-types</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | |<sub>/rest/server-hardware-types/{id}</sub> | GET | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | diff --git a/examples/server_hardware.py b/examples/server_hardware.py index 4b81fb656..f42806dff 100644 --- a/examples/server_hardware.py +++ b/examples/server_hardware.py @@ -219,3 +219,73 @@ print("Server removed successfully") except HPEOneViewException as e: print(e.msg) + +# This operation works from Oneview API Version 3400. +if oneview_client.api_version >= 3400 and server: + try: + # Gets the settings that describe about chasis configuration of server. + print("Get the settings that describe the chasis configuration of server") + server_chasisConf = server.get_chasis_configuration() + pprint(server_chasisConf) + except HPEOneViewException as e: + print(e.msg) + +# This operation works from Oneview API Version 3400. +if oneview_client.api_version >= 3400 and server: + try: + # Gets the settings that describe about firmwareInventory configuration of server. + print("Get the settings that describe the firmwareInventory configuration of server") + server_firmwareConf = server.get_firmware_configuration() + pprint(server_firmwareConf) + except HPEOneViewException as e: + print(e.msg) + +# This operation works from Oneview API Version 3400. +if oneview_client.api_version >= 3400 and server: + try: + # Gets the settings that describe about networkAdapters configuration of server. + print("Get the settings that describe the networkAdapters configuration of server") + server_networkAdaptersConf = server.get_network_adapters_configuration() + pprint(server_networkAdaptersConf) + except HPEOneViewException as e: + print(e.msg) + +# This operation works from Oneview API Version 3400. +if oneview_client.api_version >= 3400 and server: + try: + # Gets the settings that describe about powerSupplies configuration of server. + print("Get the settings that describe the powerSupplies configuration of server") + server_powerSuppliesConf = server.get_power_supplies_configuration() + pprint(server_powerSuppliesConf) + except HPEOneViewException as e: + print(e.msg) + +# This operation works from Oneview API Version 3400. +if oneview_client.api_version >= 3400 and server: + try: + # Gets the settings that describe about processors configuration of server. + print("Get the settings that describe the processors configuration of server") + server_processorsConf = server.get_processors_configuration() + pprint(server_processorsConf) + except HPEOneViewException as e: + print(e.msg) + +# This operation works from Oneview API Version 3400. +if oneview_client.api_version >= 3400 and server: + try: + # Gets the settings that describe about softwareInventory configuration of server. + print("Get the settings that describe the softwareInventory configuration of server") + server_softwareInventoryConf = server.get_software_inventory_configuration() + pprint(server_softwareInventoryConf) + except HPEOneViewException as e: + print(e.msg) + +# This operation works from Oneview API Version 3400. +if oneview_client.api_version >= 3400 and server: + try: + # Gets the settings that describe about thermal configuration of server. + print("Get the settings that describe the thermal configuration of server") + server_thermalConf = server.get_thermal_configuration() + pprint(server_thermalConf) + except HPEOneViewException as e: + print(e.msg) diff --git a/hpeOneView/resources/servers/server_hardware.py b/hpeOneView/resources/servers/server_hardware.py index e888acad4..88ccd7bc5 100644 --- a/hpeOneView/resources/servers/server_hardware.py +++ b/hpeOneView/resources/servers/server_hardware.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- ### -# (C) Copyright [2020] Hewlett Packard Enterprise Development LP +# (C) Copyright [2021] Hewlett Packard Enterprise Development LP # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -326,3 +326,80 @@ def get_local_storage(self, ip=None): uri = "{}?ip={}".format(uri, ip) return self._helper.do_get(uri) + + @ensure_resource_client + def get_chassis(self): + """ + Gets the list of chassis values currently set on the physical server. + + Returns: + dict: Dictionary of chassis values. + """ + uri = "{}/chassis".format(self.data["uri"]) + return self._helper.do_get(uri) + + @ensure_resource_client + def get_firmware_inventory(self): + """ + Gets the list of firmwareInventory values currently set on the physical server. + + Returns: + dict: Dictionary of firmwareInventory values. + """ + uri = "{}/firmwareInventory".format(self.data["uri"]) + return self._helper.do_get(uri) + + @ensure_resource_client + def get_network_adapters(self): + """ + Gets the list of networkAdapters values currently set on the physical server. + + Returns: + dict: Dictionary of networkAdapters values. + """ + uri = "{}/networkAdapters".format(self.data["uri"]) + return self._helper.do_get(uri) + + @ensure_resource_client + def get_power_supplies(self): + """ + Gets the list of powerSupplies values currently set on the physical server. + + Returns: + dict: Dictionary of powerSupplies values. + """ + uri = "{}/powerSupplies".format(self.data["uri"]) + return self._helper.do_get(uri) + + @ensure_resource_client + def get_processors(self): + """ + Gets the list of processors values currently set on the physical server. + + Returns: + dict: Dictionary of processors values. + """ + uri = "{}/processors".format(self.data["uri"]) + return self._helper.do_get(uri) + + @ensure_resource_client + def get_software_inventory(self): + """ + Gets the list of softwareInventory values currently set on the physical server. + + Returns: + dict: Dictionary of softwareInventory values. + """ + uri = "{}/softwareInventory".format(self.data["uri"]) + return self._helper.do_get(uri) + + @ensure_resource_client + def get_thermal(self): + """ + Gets the list of thermal values currently set on the physical server. + + Returns: + dict: Dictionary of thermal values. + """ + uri = "{}/thermal".format(self.data["uri"]) + return self._helper.do_get(uri) diff --git a/tests/unit/resources/servers/test_server_hardware.py b/tests/unit/resources/servers/test_server_hardware.py index 38aea7d0c..2fe1ddbd8 100644 --- a/tests/unit/resources/servers/test_server_hardware.py +++ b/tests/unit/resources/servers/test_server_hardware.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- ### -# (C) Copyright [2020] Hewlett Packard Enterprise Development LP +# (C) Copyright [2021] Hewlett Packard Enterprise Development LP # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -281,3 +281,59 @@ def test_get_local_storage_with_ip(self, mock_get): self._server_hardware.get_local_storage(ip='172.16.8.4') mock_get.assert_called_once_with(uri_rest_call) + + @mock.patch.object(ResourceHelper, 'do_get') + def test_get_chassis(self, mock_get): + uri_rest_call = '{}/chassis'.format(self.uri) + + self._server_hardware.get_chassis() + + mock_get.assert_called_once_with(uri_rest_call) + + @mock.patch.object(ResourceHelper, 'do_get') + def test_get_firmwareInventory(self, mock_get): + uri_rest_call = '{}/firmwareInventory'.format(self.uri) + + self._server_hardware.get_firmware_inventory() + + mock_get.assert_called_once_with(uri_rest_call) + + @mock.patch.object(ResourceHelper, 'do_get') + def test_get_networkAdapters(self, mock_get): + uri_rest_call = '{}/networkAdapters'.format(self.uri) + + self._server_hardware.get_network_adapters() + + mock_get.assert_called_once_with(uri_rest_call) + + @mock.patch.object(ResourceHelper, 'do_get') + def test_get_powerSupplies(self, mock_get): + uri_rest_call = '{}/powerSupplies'.format(self.uri) + + self._server_hardware.get_power_supplies() + + mock_get.assert_called_once_with(uri_rest_call) + + @mock.patch.object(ResourceHelper, 'do_get') + def test_get_processors(self, mock_get): + uri_rest_call = '{}/processors'.format(self.uri) + + self._server_hardware.get_processors() + + mock_get.assert_called_once_with(uri_rest_call) + + @mock.patch.object(ResourceHelper, 'do_get') + def test_get_thermal(self, mock_get): + uri_rest_call = '{}/thermal'.format(self.uri) + + self._server_hardware.get_thermal() + + mock_get.assert_called_once_with(uri_rest_call) + + @mock.patch.object(ResourceHelper, 'do_get') + def test_get_softwareInventory(self, mock_get): + uri_rest_call = '{}/softwareInventory'.format(self.uri) + + self._server_hardware.get_software_inventory() + + mock_get.assert_called_once_with(uri_rest_call) From c391fdf071b72eb55d7fbd117448349ad42e65a4 Mon Sep 17 00:00:00 2001 From: Chebrolu <bala-sai-harika.chebrolu@hpe.com> Date: Fri, 12 Nov 2021 12:27:56 +0530 Subject: [PATCH 2/6] fix docstrign errors --- hpeOneView/resources/resource.py | 33 ++++++++++++++++++++++---------- 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/hpeOneView/resources/resource.py b/hpeOneView/resources/resource.py index deeb962c4..93375a827 100755 --- a/hpeOneView/resources/resource.py +++ b/hpeOneView/resources/resource.py @@ -166,6 +166,7 @@ def create(self, data=None, uri=None, timeout=-1, custom_headers=None, force=Fal timeout: Timeout in seconds. Wait for task completion by default. The timeout does not abort the operation in OneView; it just stops waiting for its completion. custom_headers: Allows set specific HTTP headers. + Returns: Created resource. """ @@ -202,11 +203,15 @@ def update(self, data=None, timeout=-1, custom_headers=None, force=False): """Makes a PUT request to update a resource when a request body is required. Args: - data: Data to update the resource. - timeout: Timeout in seconds. Wait for task completion by default. The timeout does not abort the operation + data: + Data to update the resource. + timeout: + Timeout in seconds. Wait for task completion by default. The timeout does not abort the operation in OneView; it just stops waiting for its completion. - custom_headers: Allows to add custom HTTP headers. - force: Force the update operation. + custom_headers: + Allows to add custom HTTP headers. + force: + Force the update operation. Returns: A dict with the updated resource data. @@ -451,6 +456,7 @@ def create(self, data=None, uri=None, timeout=-1, custom_headers=None, force=Fal timeout: Timeout in seconds. Wait for task completion by default. The timeout does not abort the operation in OneView; it just stops waiting for its completion. custom_headers: Allows set specific HTTP headers. + Returns: Created resource. """ @@ -491,13 +497,18 @@ def update(self, resource, uri=None, force=False, timeout=-1, custom_headers=Non """Makes a PUT request to update a resource when a request body is required. Args: - resource: Data to update the resource. - uri: Resource uri - force: If set to true, the operation completes despite any problems + resource: + Data to update the resource. + uri: + Resource uri + force: + If set to true, the operation completes despite any problems with network connectivity or errors on the resource itself. The default is false. - timeout: Timeout in seconds. Wait for task completion by default. The timeout does not abort the operation + timeout: + Timeout in seconds. Wait for task completion by default. The timeout does not abort the operation in OneView; it just stops waiting for its completion. - custom_headers: Allows to add custom HTTP headers. + custom_headers: + Allows to add custom HTTP headers. Returns: A dict with the updated resource data. @@ -1849,9 +1860,11 @@ def merge_item(resource): def transform_list_to_dict(list): """ - Transforms a list into a dictionary, putting values as keys + Transforms a list into a dictionary, putting values as keys + Args: id: + Returns: dict: dictionary built """ From f3ec4f6b2a07083f7fed047afa3f33584eff4806 Mon Sep 17 00:00:00 2001 From: Chebrolu <bala-sai-harika.chebrolu@hpe.com> Date: Fri, 12 Nov 2021 12:36:43 +0530 Subject: [PATCH 3/6] fix docstrign errors --- hpeOneView/resources/resource.py | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/hpeOneView/resources/resource.py b/hpeOneView/resources/resource.py index 93375a827..935874740 100755 --- a/hpeOneView/resources/resource.py +++ b/hpeOneView/resources/resource.py @@ -203,14 +203,14 @@ def update(self, data=None, timeout=-1, custom_headers=None, force=False): """Makes a PUT request to update a resource when a request body is required. Args: - data: + data: Data to update the resource. - timeout: + timeout: Timeout in seconds. Wait for task completion by default. The timeout does not abort the operation in OneView; it just stops waiting for its completion. - custom_headers: + custom_headers: Allows to add custom HTTP headers. - force: + force: Force the update operation. Returns: @@ -497,17 +497,17 @@ def update(self, resource, uri=None, force=False, timeout=-1, custom_headers=Non """Makes a PUT request to update a resource when a request body is required. Args: - resource: + resource: Data to update the resource. - uri: + uri: Resource uri - force: + force: If set to true, the operation completes despite any problems with network connectivity or errors on the resource itself. The default is false. - timeout: + timeout: Timeout in seconds. Wait for task completion by default. The timeout does not abort the operation in OneView; it just stops waiting for its completion. - custom_headers: + custom_headers: Allows to add custom HTTP headers. Returns: @@ -1375,8 +1375,7 @@ def update(self, resource, uri=None, force=False, timeout=-1, custom_headers=Non '300': {"type": "logical-switch-groupV300"} } - Returns: - Updated resource. + Returns: Updated resource. """ if not resource: logger.exception(RESOURCE_CLIENT_RESOURCE_WAS_NOT_PROVIDED) From 3a4cb2247d990d0891207d35ce585d6784160c4e Mon Sep 17 00:00:00 2001 From: Chebrolu <bala-sai-harika.chebrolu@hpe.com> Date: Fri, 12 Nov 2021 13:06:51 +0530 Subject: [PATCH 4/6] fix docstring errors --- requirements.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/requirements.txt b/requirements.txt index 2c333cdee..9fdce220b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,2 +1,3 @@ ###### Requirements with Version Specifiers ###### future >= 0.15.2 +docutils < 0.18 From b8fc69605c059acd573d20f6b3ca5dbd13913588 Mon Sep 17 00:00:00 2001 From: Chebrolu <bala-sai-harika.chebrolu@hpe.com> Date: Fri, 12 Nov 2021 13:21:33 +0530 Subject: [PATCH 5/6] fix docstring errors --- .github/workflows/run_tests.yml | 24 ------------------------ .readthedocs.yaml | 29 +++++++++++++++++++++++++++++ docs/requirements.txt | 2 ++ 3 files changed, 31 insertions(+), 24 deletions(-) create mode 100644 .readthedocs.yaml create mode 100644 docs/requirements.txt diff --git a/.github/workflows/run_tests.yml b/.github/workflows/run_tests.yml index 629c215d6..2b428501b 100644 --- a/.github/workflows/run_tests.yml +++ b/.github/workflows/run_tests.yml @@ -5,30 +5,6 @@ on: jobs: tox_test: - name: Run tox (${{ matrix.python_version }}) - strategy: - matrix: - python_version: - - 2.7 - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - - name: Set up Python ${{ matrix.python_version }} - uses: actions/setup-python@v1 - with: - python-version: ${{ matrix.python_version }} - - - name: Install dependencies - run: | - python -m pip install --upgrade pip - pip install tox - - - name: Run tox tests - run: tox - - Build_and_publish: name: Run tox (${{ matrix.python_version }}) strategy: matrix: diff --git a/.readthedocs.yaml b/.readthedocs.yaml new file mode 100644 index 000000000..a92bea6fd --- /dev/null +++ b/.readthedocs.yaml @@ -0,0 +1,29 @@ +# .readthedocs.yaml +# Read the Docs configuration file +# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details + +# Required +version: 2 + +# Set the version of Python and other tools you might need +build: + os: ubuntu-20.04 + tools: + python: "3.6" + # You can also specify other tool versions: + # nodejs: "16" + # rust: "1.55" + # golang: "1.17" + +# Build documentation in the docs/ directory with Sphinx +sphinx: + configuration: docs/conf.py + +# If using Sphinx, optionally build your docs in additional formats such as PDF +# formats: +# - pdf + +# Optionally declare the Python requirements required to build your docs +python: + install: + - requirements: docs/requirements.txt \ No newline at end of file diff --git a/docs/requirements.txt b/docs/requirements.txt new file mode 100644 index 000000000..58993fd17 --- /dev/null +++ b/docs/requirements.txt @@ -0,0 +1,2 @@ +docutils<0.18 +sphinx==1.8.5 \ No newline at end of file From 5a16ec8b5462f744c1696a25d95a0da6fc45a4e5 Mon Sep 17 00:00:00 2001 From: Chebrolu <bala-sai-harika.chebrolu@hpe.com> Date: Fri, 12 Nov 2021 13:31:40 +0530 Subject: [PATCH 6/6] fix docstring errors --- .readthedocs.yaml | 29 ----------------------------- setup.py | 2 +- tox.ini | 1 + 3 files changed, 2 insertions(+), 30 deletions(-) delete mode 100644 .readthedocs.yaml diff --git a/.readthedocs.yaml b/.readthedocs.yaml deleted file mode 100644 index a92bea6fd..000000000 --- a/.readthedocs.yaml +++ /dev/null @@ -1,29 +0,0 @@ -# .readthedocs.yaml -# Read the Docs configuration file -# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details - -# Required -version: 2 - -# Set the version of Python and other tools you might need -build: - os: ubuntu-20.04 - tools: - python: "3.6" - # You can also specify other tool versions: - # nodejs: "16" - # rust: "1.55" - # golang: "1.17" - -# Build documentation in the docs/ directory with Sphinx -sphinx: - configuration: docs/conf.py - -# If using Sphinx, optionally build your docs in additional formats such as PDF -# formats: -# - pdf - -# Optionally declare the Python requirements required to build your docs -python: - install: - - requirements: docs/requirements.txt \ No newline at end of file diff --git a/setup.py b/setup.py index aea922b47..3482d88ee 100644 --- a/setup.py +++ b/setup.py @@ -30,4 +30,4 @@ packages=find_packages(exclude=['examples*', 'tests*']), keywords=['oneview', 'hpe'], long_description_content_type="text/markdown", - install_requires=['future>=0.15.2']) + install_requires=['future>=0.15.2', 'docutils<0.18']) diff --git a/tox.ini b/tox.ini index 8478e486b..ad72ea52e 100644 --- a/tox.ini +++ b/tox.ini @@ -49,6 +49,7 @@ basepython=python2.7 deps= sphinx sphinx_rtd_theme + -r{toxinidir}/requirements.txt commands= sphinx-apidoc -f -o docs/source hpeOneView \ hpeOneView/common.py \