You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{
"id": "finch",
"title": "Finch",
"abstract": "A Web Processing Service for Climate Indicators",
"url": "http://10.0.0.3/providers/finch",
"processes": "http://10.0.0.3/providers/finch/processes",
"type": "wps",
"contact": "Lastname, Firstname"
}
Response, on 4.0.0:
{
"description": "Invalid schema: [{'url': 'Must be a URL'}]",
"value": null,
"$schema": "http://10.0.0.3/json#/definitions/CreateProviderRequestBody",
"schema": "CreateProviderRequestBody"
}
Logs, on 4.0.0:
weaver | [2021-09-27 14:22:44,314] WARNING [MainThread][weaver.tweens] Handled request exception:
weaver | Cause: [POST http://10.0.0.3,10.0.0.3/providers]
weaver | Raised: [(HTTPBadRequest) <400> The server could not comply with the request since it is either malformed or otherwise incorrect.]
weaver | 192.168.128.8 - - [27/Sep/2021:14:22:44 +0000] "POST /providers HTTP/1.0" 400 182 "http://10.0.0.3/providers" "PostmanRuntime/7.28.4"
Expected behavior
Supposed to return a 200 OK, not a 400 Bad Request.
Context
Plus, when doing a GET /providers, we get this error:
weaver | [2021-09-27 14:23:27,621] ERROR [MainThread][weaver.wps_restapi.providers.providers] Unhandled internal server error. Exception: [Invalid(<weaver.wps_restapi.swagger_definitions.ProvidersBodySchema object at 140284574469008 (named )>, None)]
weaver | Traceback (most recent call last):
weaver | File "/opt/local/src/weaver/weaver/exceptions.py", line 387, in call
weaver | return function(*args, **kwargs)
weaver | File "/opt/local/src/weaver/weaver/wps_restapi/providers/providers.py", line 71, in get_providers
weaver | return HTTPOk(json=sd.ProvidersBodySchema().deserialize(data))
weaver | File "/opt/local/src/weaver/weaver/wps_restapi/colander_extras.py", line 570, in deserialize
weaver | return ExtendedSchemaNode.deserialize(self, cstruct) # noqa
weaver | File "/opt/local/src/weaver/weaver/wps_restapi/colander_extras.py", line 989, in deserialize
weaver | result = colander.MappingSchema.deserialize(self, result)
weaver | File "/usr/local/lib/python3.7/site-packages/colander/__init__.py", line 2351, in deserialize
weaver | appstruct = self.typ.deserialize(self, cstruct)
weaver | File "/usr/local/lib/python3.7/site-packages/colander/__init__.py", line 827, in deserialize
weaver | return self._impl(node, cstruct, callback)
weaver | File "/usr/local/lib/python3.7/site-packages/colander/__init__.py", line 807, in _impl
weaver | raise error
weaver | colander.Invalid: {'providers': 'Incorrect type cannot distinguish between multiple valid '
weaver | "schemas. Must be only one of: ['ProvidersListSchema', "
weaver | "'ProviderNamesSchema']."}
weaver | [2021-09-27 14:23:27,624] ERROR [MainThread][weaver.tweens] Handled request exception:
weaver | Cause: [GET http://10.0.0.3,10.0.0.3/providers]
weaver | Raised: [(HTTPInternalServerError) <500> Unhandled internal server error.]
weaver | 192.168.128.8 - - [27/Sep/2021:14:23:27 +0000] "GET /providers HTTP/1.0" 500 258 "http://10.0.0.3/providers" "PostmanRuntime/7.28.4"
Notice the Cause: [GET http://10.0.0.3,10.0.0.3/providers], which is similar to the duplicated IP in #292.
OS: MacOS
Browser : chrome
Instance: local
Version : 4.0.0
The text was updated successfully, but these errors were encountered:
Error occurs because of http://finch:5001/wps being an invalid URL for remote provider registration.
After replacing by http://10.0.0.3/providers/finch, consents are properly retrieved from WPS GetCapabilities response, but parsing of the XML fails.
Finch's XML contains illegal characters such as < within some descriptions. They must be escaped (eg: <).
Describe the bug
Can't post or retrieve Providers under Weaver 4.0.0.
How to Reproduce
POST /providers
Response, on 1.6.0:
Response, on 4.0.0:
Logs, on 4.0.0:
Expected behavior
Supposed to return a 200 OK, not a 400 Bad Request.
Context
Plus, when doing a
GET /providers
, we get this error:Notice the
Cause: [GET http://10.0.0.3,10.0.0.3/providers]
, which is similar to the duplicated IP in #292.The text was updated successfully, but these errors were encountered: