mirror of
https://github.com/freqtrade/freqtrade.git
synced 2024-11-10 10:21:59 +00:00
Remove more deprecated options
This commit is contained in:
parent
505584dc48
commit
4b2a6a84f4
|
@ -41,7 +41,7 @@ logger = logging.getLogger(__name__)
|
|||
|
||||
|
||||
def schema_to_dict(schema: Union[WSMessageSchema, WSRequestSchema]):
|
||||
return schema.dict(exclude_none=True)
|
||||
return schema.model_dump(exclude_none=True)
|
||||
|
||||
|
||||
class ExternalMessageConsumer:
|
||||
|
@ -344,7 +344,7 @@ class ExternalMessageConsumer:
|
|||
def _consume_whitelist_message(self, producer_name: str, message: WSMessageSchema):
|
||||
try:
|
||||
# Validate the message
|
||||
whitelist_message = WSWhitelistMessage.model_validate(message)
|
||||
whitelist_message = WSWhitelistMessage.model_validate(message.model_dump())
|
||||
except ValidationError as e:
|
||||
logger.error(f"Invalid message from `{producer_name}`: {e}")
|
||||
return
|
||||
|
@ -356,7 +356,7 @@ class ExternalMessageConsumer:
|
|||
|
||||
def _consume_analyzed_df_message(self, producer_name: str, message: WSMessageSchema):
|
||||
try:
|
||||
df_message = WSAnalyzedDFMessage.model_validate(message)
|
||||
df_message = WSAnalyzedDFMessage.model_validate(message.model_dump())
|
||||
except ValidationError as e:
|
||||
logger.error(f"Invalid message from `{producer_name}`: {e}")
|
||||
return
|
||||
|
|
Loading…
Reference in New Issue
Block a user