Commit 1569510e authored by Victor Dosda's avatar Victor Dosda
Browse files

Fix bug 827661 error 500 on dipset query

parent a563becb
Pipeline #70542 failed with stages
in 23 minutes and 15 seconds
......@@ -118,12 +118,13 @@ async def query_dip(
) -> List[Dip]:
_, df = await persistence.read_dipset_data(ctx, ds=dipsetid)
if classification is not None:
if classification is not None and "classification" in df:
df = df[df["classification"] == classification]
if min_ref is not None and not math.isnan(min_ref):
df = df[df["reference"] >= min_ref]
if max_ref is not None and not math.isnan(max_ref):
df = df[df["reference"] <= max_ref]
if "reference" in df:
if min_ref is not None and not math.isnan(min_ref):
df = df[df["reference"] >= min_ref]
if max_ref is not None and not math.isnan(max_ref):
df = df[df["reference"] <= max_ref]
return persistence.df_to_dips(df)
......
Markdown is supported
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