Commit f8df1c00 authored by Christoffer Stoll's avatar Christoffer Stoll
Browse files

validation_flag 0 bug

parent fd588489
......@@ -84,13 +84,14 @@ def parse_dat(file_name, id, timezone):
for c in range(2, len(l)):
cols = l[c].split(",")
if len(cols) == 3:
val = nlstrip(cols[2])
d = OrderedDict()
d["sampling_point_id"] = id
d["begin_position"] = parse_date(cols[0], timezone)
d["end_position"] = parse_date(cols[0], timezone, 24 if timestep == "day" else 1)
d["value"] = cols[1]
d["verification_flag"] = 1
d["validation_flag"] = nlstrip(cols[2])
d["validation_flag"] = -1 if val == 0 else val
d["concentration"] = "http://dd.eionet.europa.eu/vocabulary/uom/concentration/" + unit
d["timestep"] = "http://dd.eionet.europa.eu/vocabulary/aq/primaryObservation/" + timestep
a.append(d)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment