django-daiquiri / daiquiri

A framework for the publication of scientific databases
https://escience.aip.de/daiquiri
Apache License 2.0
24 stars 8 forks source link

BUG: the errorSummary message get lost when using pyvo #155

Open agy-why opened 1 year ago

agy-why commented 1 year ago

Getting the errorSummary message was not working.

now with pyvo-PR#432 the problem is solved and it possible to get the error message back.

However the tap response is not properly formed in daiquiri and should be:

<uws:errorSummary  hasDetail="true" type="fatal">
    <uws:message>
        <uws:content>
            There has been an server error with your job.
    </uws:content>
</uws:message></uws:errorSummary>

in https://github.com/django-daiquiri/daiquiri/blob/master/daiquiri/jobs/renderers.py#L46

we need to add a render_error_summary method.

agy-why commented 1 year ago

something like that

for key, value in data.items():
    ...
    elif key == 'error_summary':
        start("uws:errorSummary", attrs={"hasDetail":True, "type": "fatal"})
        node("uws:message", text=value)
        end("uws:errorSummary")