Skip to content

Commit

Permalink
[diamond_miner]: Prefix not found error
Browse files Browse the repository at this point in the history
  • Loading branch information
hrimlinger committed Jan 11, 2024
1 parent 9be8aee commit 2c1632c
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions iris/worker/inner_pipeline/diamond_miner.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,14 @@ async def diamond_miner_inner_pipeline(
prefix = f"{addr_v4}/{tool_parameters.prefix_len_v4}"
else:
prefix = f"{addr_v6}/{tool_parameters.prefix_len_v6}"
for protocol, ttls, n_initial_flows in targets[prefix]:
prefixes.append((prefix, protocol, ttls, n_initial_flows))
try:
for protocol, ttls, n_initial_flows in targets[prefix]:
prefixes.append((prefix, protocol, ttls, n_initial_flows))
except KeyError:
logger.error(
f"Prefix not in initial target file {targets_filepath}:{prefix}"
)
continue

logger.info("Insert probe counts")
insert_probe_counts(
Expand Down

0 comments on commit 2c1632c

Please sign in to comment.