Skip to content

Commit

Permalink
fix: AnalysisPluginV0.summarize should not be abstract since summary …
Browse files Browse the repository at this point in the history
…is optional
  • Loading branch information
jstucke committed Nov 27, 2024
1 parent 00dc1f3 commit 1e6f861
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/analysis/plugin/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,11 @@ class MetaData(BaseModel):
#: It MUST be a `semver <https://semver.org/>`_ version.
#: Here is a quick summary how semver relates to plugins.
#: * MAJOR: The plugin schema changed.
#: * MINOR: The schema din't change but might contain more data.
#: * MINOR: The schema didn't change but might contain more data.
#: * PATCH: A bug was fixed e.g. a crash on some files.
#:
#: Note that any version change leads to rescheduling the analysis.
#: But backwards compatible results will still be shown in the fronfrontend.
#: But backwards compatible results will still be shown in the frontend.
version: semver.Version
#: The version of the backing analysis system.
#: E.g. for yara plugins this would be the yara version.
Expand Down Expand Up @@ -88,10 +88,9 @@ def __init__(self, metadata: MetaData):
# The type MetaData.Schema
Schema = typing.TypeVar('Schema')

@abc.abstractmethod
def summarize(self, result: Schema) -> list[str]:
def summarize(self, result: Schema) -> list[str]: # noqa: ARG002
"""
The summary is a list of categories in which the result can be grouped.
The summary is an optional list of categories in which the result can be grouped.
In the FACT_core frontend if you view the analysis of a container the
summary is used to group files included in it.
Expand All @@ -105,6 +104,7 @@ def summarize(self, result: Schema) -> list[str]:
:param result: The analysis as returned by :py:func:`analyze`
"""
return []

@abc.abstractmethod
def analyze(
Expand Down

0 comments on commit 1e6f861

Please sign in to comment.