File tree Expand file tree Collapse file tree 2 files changed +7
-1
lines changed
Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ class CpeMatchDatabaseWriteWorker(ScapDatabaseWriteWorker[CPEMatchString]):
1919 _item_type_plural = CPE_MATCH_TYPE_PLURAL
2020 "Plural form of the type of items to use in log messages."
2121
22- _arg_defaults = ScapDatabaseWriteWorker .arg_defaults
22+ _arg_defaults = ScapDatabaseWriteWorker ._arg_defaults
2323 "Default values for optional arguments."
2424
2525 @classmethod
Original file line number Diff line number Diff line change 1414 DEFAULT_POSTGRES_DATABASE_NAME ,
1515 DEFAULT_POSTGRES_HOST ,
1616 DEFAULT_POSTGRES_PORT ,
17+ DEFAULT_VERBOSITY ,
1718 CLIError ,
1819)
1920from ...db import PostgresDatabase
@@ -45,12 +46,16 @@ class ScapDatabaseWriteWorker(BaseScapWorker[T]):
4546 """
4647
4748 _item_type_plural = BaseScapWorker ._item_type_plural
49+ "Plural form of the type of items to use in log messages."
50+
4851 _arg_defaults = {
4952 "database_name" : DEFAULT_POSTGRES_DATABASE_NAME ,
5053 "database_host" : DEFAULT_POSTGRES_HOST ,
5154 "database_port" : DEFAULT_POSTGRES_PORT ,
5255 "database_schema" : None ,
56+ "verbose" : DEFAULT_VERBOSITY ,
5357 }
58+ "Default values for optional arguments."
5459
5560 @classmethod
5661 def add_args_to_parser (
@@ -232,6 +237,7 @@ async def _loop_start(self) -> None:
232237
233238 async def __aenter__ (self ):
234239 await self ._database .__aenter__ ()
240+ await self ._manager .__aenter__ ()
235241 return self
236242
237243 async def __aexit__ (self , exc_type , exc_val , exc_tb ):
You can’t perform that action at this time.
0 commit comments