Skip to content

Commit 1a1de4f

Browse files
committed
Rather test that the returned value does not have a field always in a future.
1 parent 2610e21 commit 1a1de4f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

dataikuapi/dss/plugin.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,8 +144,8 @@ def delete(self, force=False):
144144
}
145145
ret = self.client._perform_json("POST", "/plugins/{pluginId}/actions/delete".format(pluginId=self.plugin_id),
146146
body=params)
147-
if "projectCount" in ret:
148-
raise DataikuException("Plugin has usages or analysis errors.")
147+
if "state" not in ret:
148+
raise DataikuException("Plugin has usages or analysis errors. See list_usages() for more info.")
149149
return self.client.get_future(ret.get("jobId", None))
150150

151151
########################################################

0 commit comments

Comments
 (0)