opengeospatial / bblocks-postprocess

0 stars 0 forks source link

DateTime parsing throws processing error - not validation report #19

Closed rob-metalinkage closed 11 months ago

rob-metalinkage commented 11 months ago

When running tests process does not handle datetime parsing elegantly...

Traceback (most recent call last):
  File "/venv/lib/python3.10/site-packages/isodate/isodatetime.py", line 51, in parse_datetime
    datestring, timestring = datetimestring.split('T')
ValueError: not enough values to unpack (expected 2, got 1)
avillar commented 11 months ago

This is a warning that rdflib outputs to the console directly. It's not an error per-se, since rdflib is catching the exception and setting the literal to null.

Options:

  1. Disable logging warnings for rdflib.term
  2. Try to capture the warning logstream and add it to the log.
avillar commented 11 months ago

Ok, I went ahead with option 2. I haven't managed to remove the warning from the logging output, but at least we now capture it, mark is as an error, and add it to the log.

rob-metalinkage commented 11 months ago

Ok that's good enough. Is this an issue we should raise with rdflib though... it seems a clunky option assuming someone is reading a log output...

avillar commented 11 months ago

There's definitely some logging configuration that we could apply to avoid it, I'll try it tomorrow.

El 20 de octubre de 2023 0:20:01 Rob @.***> escribió:

Ok that's good enough. Is this an issue we should raise with rdflib though... it seems a clunky option assuming someone is reading a log output... — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you were assigned.Message ID: @.***>

--

Sign up for OGC News https://ogc.us4.list-manage.com/subscribe?u=704e02f81107a6caab1568067&id=4e4528fd9d

avillar commented 11 months ago

Ok, the warning that was still appearing was from the transforms, not the validation. I've disabled warnings in transforms, since if there's a problem, it's going to be the same as in the validations.