Skip to content

Commit

Permalink
rove_connector: return error for invalid ts_id
Browse files Browse the repository at this point in the history
  • Loading branch information
intarga committed Dec 3, 2024
1 parent 1e202d6 commit ff195f8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions rove_connector/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,9 @@ impl DataConnector for Connector {
match space_spec {
SpaceSpec::One(ts_id) => {
self.fetch_one(
// TODO: deal with this unwrap
ts_id.parse().unwrap(),
ts_id
.parse()
.map_err(|_| data_switch::Error::InvalidSeriesId(ts_id.to_string()))?,
time_spec,
num_leading_points,
num_trailing_points,
Expand Down

0 comments on commit ff195f8

Please sign in to comment.