Added correct exception in Chunks parse output #346
Labels
No labels
P0
P1
P2
P3
good first issue
Infrastructure
blocked
bug
config
discussion
documentation
duplicate
enhancement
go
help wanted
internal
invalid
kludge
observability
perfomance
question
refactoring
wontfix
No milestone
No project
No assignees
4 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: TrueCloudLab/frostfs-testlib#346
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "d.zayakin/frostfs-testlib:add-correct-exception-in-chunks-parse-output"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Signed-off-by: Dmitriy Zayakin d.zayakin@yadro.com
@ -162,3 +162,3 @@
parse_result = json.loads(object_nodes)
if parse_result.get("errors"):
raise parse_result["errors"]
raise ValueError("Key error in output, not empty.\n", parse_result["errors"])
Why
ValueError
?parse_result
is not an argument of a function_parse_object_nodes
.also, there is no need to add more text to it.
it's just
raise RuntimeError(", ".join(parse_result["errors"]))
Then why is it a RuntimeError? The mistake here is that we got some kind of value in the key at all, but it shouldn't be there.
132ffec3ec
to974836f1bd