Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions detection_rules/devtools.py
Original file line number Diff line number Diff line change
Expand Up @@ -1050,6 +1050,15 @@ def raw_permalink(raw_link: str) -> str:
raise raise_client_error(
"Gist not found: verify the gist_id exists and the token has access to it", exc=exc
) from exc
if exc.response.status_code == requests.status_codes.codes.unauthorized:
text = json.loads(exc.response.text).get(
"message", "verify the token is valid and has the necessary permissions"
)
error_message = f"Unauthorized: {text}"
raise raise_client_error(
error_message,
exc=exc,
) from exc
raise

response_data = response.json()
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "detection_rules"
version = "1.4.2"
version = "1.4.3"
description = "Detection Rules is the home for rules used by Elastic Security. This repository is used for the development, maintenance, testing, validation, and release of rules for Elastic Security’s Detection Engine."
readme = "README.md"
requires-python = ">=3.12"
Expand Down
Loading