Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Nov 14, 2024. It is now read-only.
This repository was archived by the owner on Nov 14, 2024. It is now read-only.

ace: confusion with ephemeral and permament processing #3

@neteler

Description

@neteler

The user @veroandreo reported to me an issue with the current ace version:

This gives error (but user expectancy is that it should work):

ace location="latlong_wgs84" mapset="chelsa_climate_south_america" grass_command="g.list type=raster"
...
{
  "accept_datetime": "2021-04-23 07:15:52.849249",
  "accept_timestamp": 1619162152.8492472,
  "api_info": {
    "endpoint": "asyncpersistentresource",
    "method": "POST",
    "path": "/api/v1/locations/latlong_wgs84/mapsets/chelsa_climate_south_america/processing_async",
    "request_url": "http://actinia.mundialis.de/api/v1/locations/latlong_wgs84/mapsets/chelsa_climate_south_america/processing_async"
  },
  "datetime": "2021-04-23 07:15:53.008159",
  "exception": {
    "message": "AsyncProcessError:  Mapset <chelsa_climate_south_america> exists in the global dataset and can not be modified.",
    "traceback": [
      "  File \"/usr/lib/python3.8/site-packages/actinia_core/resources/ephemeral_processing.py\", line 1356, in run\n    self._execute()\n",
      "  File \"/usr/lib/python3.8/site-packages/actinia_core/resources/persistent_processing.py\", line 560, in _execute\n    self._check_lock_target_mapset()\n",
      "  File \"/usr/lib/python3.8/site-packages/actinia_core/resources/persistent_processing.py\", line 370, in _check_lock_target_mapset\n    self.target_mapset_exists = self._check_mapset(self.target_mapset_name)\n",
      "  File \"/usr/lib/python3.8/site-packages/actinia_core/resources/persistent_processing.py\", line 326, in _check_mapset\n    raise AsyncProcessError(\"Mapset <%s> exists in the global \"\n"
    ],
    "type": "<class 'actinia_core.resources.common.exceptions.AsyncProcessError'>"
  },
  "http_code": 400,
  "message": "AsyncProcessError:  Mapset <chelsa_climate_south_america> exists in the global dataset and can not be modified.",
  "process_chain_list": [
    {
      "list": [
        {
          "id": "g.list_1804289383",
          "inputs": [
            {
              "param": "type",
              "value": "raster"
            },
            {
              "param": "separator",
              "value": "newline"
            }
          ],
          "module": "g.list"
        }
      ],
      "version": "1"
    }
  ],
  "process_log": [],
  "progress": {
    "num_of_steps": 1,
    "step": 0
  },
  "resource_id": "resource_id-60535ec9-bd60-4910-932c-aab3163f3ea9",
  "status": "error",
  "time_delta": 0.1589653491973877,
  "timestamp": 1619162153.008107,
  "urls": {
    "resources": [],
    "status": "https://actinia.mundialis.de/api/v1/resources/veroandreo/resource_id-60535ec9-bd60-4910-932c-aab3163f3ea9"
  },
  "user_id": "veroandreo"
}

while this works:

ace location="latlong_wgs84" grass_command="g.list type=raster mapset=chelsa_climate_south_america"
https://actinia.mundialis.de/api/v1/locations/latlong_wgs84/processing_async_export
{'version': '1', 'list': [{'module': 'g.list', 'id': 'g.list_1804289383', 'inputs': [{'param': 'type', 'value': 'raster'}, {'param': 'mapset', 'value': 'chelsa_climate_south_america'}, {'param': 'separator', 'value': 'newline'}]}]}
veroandreo
Resource status accepted
Polling: https://actinia.mundialis.de/api/v1/resources/veroandreo/resource_id-3e22b95c-e1f6-4bcb-9303-1af736f4f03a
Resource poll status: accepted
Resource accepted
Resource poll status: finished
Processing successfully finished
--------------------------------------------------------------------------
CHELSA_bio10_01
CHELSA_bio10_02
CHELSA_bio10_03
CHELSA_bio10_04
...

I suspect these changes within PR #1:
- 332297130b8c0863c2ed63ccea6404bd3edd6dc7
- 9d61111d655eea46f2dfabffdc779379b7e75cd6
- (maybe more)

I think that the originally present `-p` flag would be more intuitive.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions