mirror of
https://github.com/volatilityfoundation/volatility3.git
synced 2026-09-22 01:24:51 +02:00
Fix more typing issues.
This commit is contained in:
@@ -65,7 +65,7 @@ class PluginInterface(interfaces_configuration.ConfigurableInterface, validity.V
|
||||
config_path: str,
|
||||
progress_callback: validity.ProgressCallback = None) -> None:
|
||||
super().__init__(context, config_path)
|
||||
self._progress_callback = progress_callback
|
||||
self._progress_callback = progress_callback or (lambda f, s: None)
|
||||
# Plugins self validate on construction, it makes it more difficult to work with them, but then
|
||||
# the validation doesn't need to be repeated over and over again by externals
|
||||
if self.unsatisfied(context, config_path):
|
||||
|
||||
@@ -7,7 +7,7 @@ from volatility.framework import interfaces, validity
|
||||
class Flags(validity.ValidityRoutines):
|
||||
"""Object that converts an integer into a set of flags based on their masks"""
|
||||
|
||||
def __init__(self, choices: typing.Mapping[str, int] = None) -> None:
|
||||
def __init__(self, choices: typing.Mapping[str, int]) -> None:
|
||||
self._check_type(choices, collections.Mapping)
|
||||
for k, v in choices.items():
|
||||
self._check_type(k, str)
|
||||
|
||||
Reference in New Issue
Block a user