[FR] Load ECS mapping based on supplied stack version (#5925)
* Load ECS mapping based on supplied stack version
This commit is contained in:
@@ -17,7 +17,6 @@ from elasticsearch.exceptions import BadRequestError
|
||||
from semver import Version
|
||||
|
||||
from . import ecs, integrations, misc, utils
|
||||
from .config import load_current_package_version
|
||||
from .esql import EventDataset
|
||||
from .esql_errors import (
|
||||
EsqlKibanaBaseError,
|
||||
@@ -511,7 +510,7 @@ def prepare_mappings( # noqa: PLR0913
|
||||
custom_mapping.update({index: index_mapping})
|
||||
|
||||
# Load ECS in an index mapping format (nested schema)
|
||||
current_version = Version.parse(load_current_package_version(), optional_minor_and_patch=True)
|
||||
current_version = Version.parse(stack_version, optional_minor_and_patch=True)
|
||||
ecs_schema = get_ecs_schema_mappings(current_version)
|
||||
|
||||
# Filter combined mappings based on the provided indices
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
[project]
|
||||
name = "detection_rules"
|
||||
version = "1.6.14"
|
||||
version = "1.6.15"
|
||||
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"
|
||||
|
||||
Reference in New Issue
Block a user