Skip to content

Commit

Permalink
refactor(config/productTypes): ignore unindexed fields
Browse files Browse the repository at this point in the history
  • Loading branch information
bgiraudo committed Jan 18, 2024
1 parent b621e01 commit 3bf801f
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions eodag/api/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,6 @@ def build_index(self) -> None:
missionEndDate=fields.ID,
keywords=fields.KEYWORD(analyzer=kw_analyzer),
)
non_indexable_fields: List[str] = []
self._product_types_index = create_in(index_dir, product_types_schema)
ix_writer = self._product_types_index.writer()
for product_type in self.list_product_types(fetch_providers=False):
Expand All @@ -278,7 +277,7 @@ def build_index(self) -> None:
**{
k: v
for k, v in versioned_product_type.items()
if k not in non_indexable_fields
if k in product_types_schema.names()
}
)
ix_writer.commit()
Expand Down

0 comments on commit 3bf801f

Please sign in to comment.
  NODES
COMMUNITY 1
Note 1
Project 1
USERS 1