diff --git a/.github/workflows/cicd.yml b/.github/workflows/cicd.yml index cd3f431..23529d8 100644 --- a/.github/workflows/cicd.yml +++ b/.github/workflows/cicd.yml @@ -9,7 +9,7 @@ concurrency: jobs: run-linter: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest strategy: matrix: python-version: [3.10.13] @@ -33,7 +33,7 @@ jobs: python-version: ${{ matrix.python-version }} run-tests: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest strategy: matrix: python-version: [3.10.13] diff --git a/exabyte_api_client/endpoints/entity.py b/exabyte_api_client/endpoints/entity.py index 1da3d1d..05d8c07 100644 --- a/exabyte_api_client/endpoints/entity.py +++ b/exabyte_api_client/endpoints/entity.py @@ -63,18 +63,20 @@ def delete(self, id_): """ return self.request("DELETE", "/".join((self.name, id_)), headers=self.headers) - def update(self, id_, modifier): + def update(self, id_, modifier, parameters=None): """ Updates a entity with given ID. Args: id_ (str): entity ID. modifier (dict): a dictionary of key-values to update entity with. + parameters (dict): additional request parameters. Returns: dict: updated entity. """ - return self.request("PATCH", "/".join((self.name, id_)), data=json.dumps(modifier), headers=self.headers) + return self.request("PATCH", "/".join((self.name, id_)), data=json.dumps(modifier), headers=self.headers, + params=parameters) def create(self, config, owner_id=None): """