Skip to content

Commit

Permalink
revise warning
Browse files Browse the repository at this point in the history
  • Loading branch information
Lin-Dongzhao committed Apr 24, 2024
1 parent 2d0f099 commit 68bc3c5
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 10 deletions.
6 changes: 2 additions & 4 deletions messages.pot
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2024-04-24 11:54+0800\n"
"POT-Creation-Date: 2024-04-24 13:56+0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
Expand Down Expand Up @@ -896,9 +896,7 @@ msgid "Cash add {}. units {} become to {}"
msgstr ""

#: rqalpha/portfolio/account.py:350
msgid ""
"Futures account's cash turns negative after settlement, please increase "
"cash or adjust position"
msgid "Futures account's cash turns negative after settlement"
msgstr ""

#: rqalpha/portfolio/account.py:356
Expand Down
2 changes: 1 addition & 1 deletion rqalpha/portfolio/account.py
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ def _on_settlement(self, event):

# 如果期货结算结束时 cash 为负数,抛出提醒给到用户
if self._type == "FUTURE" and self.cash < 0:
user_system_log.warn(_("Futures account's cash turns negative after settlement, please increase cash or adjust position"))
user_system_log.warn(_("Futures account's cash turns negative after settlement"))

# 如果 total_value <= 0 则认为已爆仓,清空仓位,资金归0
forced_liquidation = self._env.config.base.forced_liquidation
Expand Down
Binary file modified rqalpha/utils/translations/zh_Hans_CN/LC_MESSAGES/messages.mo
Binary file not shown.
8 changes: 3 additions & 5 deletions rqalpha/utils/translations/zh_Hans_CN/LC_MESSAGES/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2024-04-24 11:54+0800\n"
"POT-Creation-Date: 2024-04-24 13:56+0800\n"
"PO-Revision-Date: 2016-10-24 21:20+0800\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language: zh_Hans_CN\n"
Expand Down Expand Up @@ -924,10 +924,8 @@ msgid "Cash add {}. units {} become to {}"
msgstr "入金{}元,份额由{}变动为{}"

#: rqalpha/portfolio/account.py:350
msgid ""
"Futures account's cash turns negative after settlement, please increase "
"cash or adjust position"
msgstr "期货账户的现金在结算后变为负数,请增加现金或调整仓位"
msgid "Futures account's cash turns negative after settlement"
msgstr "期货账户的现金在结算后变为负数"

#: rqalpha/portfolio/account.py:356
msgid "Trigger Forced Liquidation, current total_value is 0"
Expand Down

0 comments on commit 68bc3c5

Please sign in to comment.