Closed B-Hartmann closed 2 years ago
When the circle exists, but the collections one wants to add the data to, the following error message is shown:
Initializing.
Traceback (most recent call last):
File "c:\users\bhartma\.environments\recover\lib\site-packages\dcoraid\cli.py", line 62, in upload_task
uj = task.load_task(path_task,
File "c:\users\bhartma\.environments\recover\lib\site-packages\dcoraid\upload\task.py", line 304, in load_task
ddict = dataset_create(
File "c:\users\bhartma\.environments\recover\lib\site-packages\dcoraid\api\dataset.py", line 62, in dataset_create
data = api.post("package_create", dataset_dict)
File "c:\users\bhartma\.environments\recover\lib\site-packages\dcoraid\api\ckan_api.py", line 317, in post
resp = self.handle_response(req, api_call)
File "c:\users\bhartma\.environments\recover\lib\site-packages\dcoraid\api\ckan_api.py", line 129, in handle_response
raise APINotFoundError(msg)
dcoraid.api.errors.APINotFoundError: Not Found Error: message: Not found: Collection was not found. (for 'package_create')
This is a little more descriptive, but the Error that is thrown is not quite right. If possible, I would suggest something like "CircleNotFoundError" and "CollectionNotFoundError" to be raised in these situations.
dcoraid 0.11.6 Windows 10 Python 3.9.0
When trying to upload data to an DCOR instance into a circle that actually does not exist yet on the server, the following error message is produced even though the api key used is correct:
There should be a more descriptive error like "circle not found"