Skip to content

Commit 8be90ad

Browse files
authored
Merge pull request #403 from splunk/new_error_printout_generic_case
New error printout generic case
2 parents 6fa5996 + aa059a0 commit 8be90ad

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

contentctl/input/director.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -338,10 +338,15 @@ def createSecurityContent(
338338
for err in error.errors():
339339
error_msg = err.get("msg", "")
340340
if "https://errors.pydantic.dev" in error_msg:
341-
continue
341+
# Unfortunately, this is a catch-all for untyped errors. We will still need to emit this
342+
# This is harder to read, but the other option is suppressing it which we cannot do as
343+
# it makes troubleshooting extremelt difficult
344+
print(
345+
f" {Colors.RED}{Colors.ERROR} {error_msg}{Colors.END}"
346+
)
342347

343348
# Clean error categorization
344-
if "Field required" in error_msg:
349+
elif "Field required" in error_msg:
345350
print(
346351
f" {Colors.YELLOW}{Colors.WARNING} Field Required: {err.get('loc', [''])[0]}{Colors.END}"
347352
)

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[tool.poetry]
22
name = "contentctl"
33

4-
version = "5.4.0"
4+
version = "5.4.1"
55

66
description = "Splunk Content Control Tool"
77
authors = ["STRT <[email protected]>"]

0 commit comments

Comments
 (0)