From 593c4d1865dff6bebc321ee81b4f1d5871ee3a2e Mon Sep 17 00:00:00 2001 From: msimonin <matthieu.simonin@inria.fr> Date: Fri, 1 Jul 2022 14:31:07 +0200 Subject: [PATCH] StorageHomeUser: use id as __attr_id --- grid5000/objects.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/grid5000/objects.py b/grid5000/objects.py index a7d60e0..9f34661 100644 --- a/grid5000/objects.py +++ b/grid5000/objects.py @@ -213,7 +213,8 @@ class StorageHomeUserManager(RESTManager): We'd prefer having a list, so we inject an uid in the responses: [ { - "uid": "G5k-home_jpicard_j_1666466-nancy_1" + # We align the id_attr according to what is returned by the api + "id": "G5k-home_jpicard_j_1666466-nancy_1" "ipv4": [ "172.16.64.97" ], @@ -229,7 +230,7 @@ class StorageHomeUserManager(RESTManager): _objs = [] for uid, access in l_objs.items(): _obj = access - _obj.update(uid=uid) + _obj.update(id=uid) _objs.append(_obj) return [self._obj_cls(self, _obj) for _obj in _objs] -- GitLab