Skip to content

Commit 7e596c0

Browse files
SkylerMalinowskibsngardner
authored andcommitted
feat: prefix user visible errors with its source
1 parent 7fad800 commit 7e596c0

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

CHANGELOG.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
All notable changes to this project will be documented in this file.
44

5+
## \[5.7.6\]
6+
7+
- Prefix user visible errors with its source.
8+
59
## \[5.7.5\]
610

711
- Add on_host_maintenance to packer module to support instances with GPUs.

scripts/resume.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ def resume_nodes(nodelist, placement_groups=None, exclusive_job=None):
281281
failed_reqs = [str(e) for e in failed.items()]
282282
log.error("bulkInsert API failures: {}".format("; ".join(failed_reqs)))
283283
for ident, exc in failed.items():
284-
down_nodes(grouped_nodes[ident].nodes, exc._get_reason())
284+
down_nodes(grouped_nodes[ident].nodes, f"GCP Error: {exc._get_reason()}")
285285

286286
if log.isEnabledFor(logging.DEBUG):
287287
for group, op in started.items():
@@ -325,7 +325,7 @@ def resume_nodes(nodelist, placement_groups=None, exclusive_job=None):
325325
for err in failed_op["error"]["errors"]
326326
)
327327
if code != "RESOURCE_ALREADY_EXISTS":
328-
down_nodes(hostlist, msg)
328+
down_nodes(hostlist, f"GCP Error: {msg}")
329329
log.error(
330330
f"errors from insert for node '{failed_node}' ({failed_op['name']}): {msg}"
331331
)

0 commit comments

Comments
 (0)