rqalpha 5.6.0__tar.gz → 5.6.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (207) hide show
  1. {rqalpha-5.6.0/rqalpha.egg-info → rqalpha-5.6.2}/PKG-INFO +3 -2
  2. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/_version.py +3 -3
  3. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/data/base_data_source/data_source.py +2 -1
  4. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/mod.py +5 -1
  5. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_simulation/matcher.py +24 -27
  6. {rqalpha-5.6.0 → rqalpha-5.6.2/rqalpha.egg-info}/PKG-INFO +3 -2
  7. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha.egg-info/requires.txt +6 -1
  8. {rqalpha-5.6.0 → rqalpha-5.6.2}/setup.cfg +1 -1
  9. {rqalpha-5.6.0 → rqalpha-5.6.2}/setup.py +2 -1
  10. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/test_position_queue.py +1 -1
  11. {rqalpha-5.6.0 → rqalpha-5.6.2}/CHANGELOG.rst +0 -0
  12. {rqalpha-5.6.0 → rqalpha-5.6.2}/LICENSE +0 -0
  13. {rqalpha-5.6.0 → rqalpha-5.6.2}/MANIFEST.in +0 -0
  14. {rqalpha-5.6.0 → rqalpha-5.6.2}/README.rst +0 -0
  15. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/__init__.py +0 -0
  16. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/__main__.py +0 -0
  17. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/api.py +0 -0
  18. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/apis/__init__.py +0 -0
  19. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/apis/api_abstract.py +0 -0
  20. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/apis/api_base.py +0 -0
  21. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/apis/api_rqdatac.py +0 -0
  22. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/apis/names.py +0 -0
  23. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/cmds/__init__.py +0 -0
  24. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/cmds/bundle.py +0 -0
  25. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/cmds/entry.py +0 -0
  26. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/cmds/misc.py +0 -0
  27. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/cmds/mod.py +0 -0
  28. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/cmds/run.py +0 -0
  29. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/config.yml +0 -0
  30. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/const.py +0 -0
  31. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/core/__init__.py +0 -0
  32. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/core/events.py +0 -0
  33. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/core/execution_context.py +0 -0
  34. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/core/executor.py +0 -0
  35. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/core/global_var.py +0 -0
  36. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/core/strategy.py +0 -0
  37. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/core/strategy_context.py +0 -0
  38. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/core/strategy_loader.py +0 -0
  39. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/core/strategy_universe.py +0 -0
  40. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/data/__init__.py +0 -0
  41. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/data/bar_dict_price_board.py +0 -0
  42. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/data/base_data_source/__init__.py +0 -0
  43. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/data/base_data_source/adjust.py +0 -0
  44. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/data/base_data_source/storage_interface.py +0 -0
  45. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/data/base_data_source/storages.py +0 -0
  46. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/data/bundle.py +0 -0
  47. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/data/data_proxy.py +0 -0
  48. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/data/trading_dates_mixin.py +0 -0
  49. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/environment.py +0 -0
  50. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/IF1706_20161108.csv +0 -0
  51. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/IF_macd.py +0 -0
  52. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/buy_and_hold.py +0 -0
  53. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/data_source/get_csv_module.py +0 -0
  54. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/data_source/import_get_csv_module.py +0 -0
  55. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/data_source/read_csv_as_df.py +0 -0
  56. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/extend_api/rqalpha_mod_extend_api_demo.py +0 -0
  57. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/extend_api/test_extend_api.py +0 -0
  58. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/golden_cross.py +0 -0
  59. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/macd.py +0 -0
  60. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/pair_trading.py +0 -0
  61. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/rsi.py +0 -0
  62. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/run_code_demo.py +0 -0
  63. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/run_file_demo.py +0 -0
  64. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/run_func_demo.py +0 -0
  65. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/subscribe_event.py +0 -0
  66. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/test_pt.py +0 -0
  67. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/examples/turtle.py +0 -0
  68. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/interface.py +0 -0
  69. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/main.py +0 -0
  70. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/__init__.py +0 -0
  71. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_accounts/__init__.py +0 -0
  72. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_accounts/api/__init__.py +0 -0
  73. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_accounts/api/api_future.py +0 -0
  74. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_accounts/api/api_stock.py +0 -0
  75. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_accounts/component_validator.py +0 -0
  76. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_accounts/mod.py +0 -0
  77. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_accounts/position_model.py +0 -0
  78. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_accounts/position_validator.py +0 -0
  79. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_accounts/validator.py +0 -0
  80. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/__init__.py +0 -0
  81. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/plot/__init__.py +0 -0
  82. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/plot/consts.py +0 -0
  83. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/plot/plot.py +0 -0
  84. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/plot/utils.py +0 -0
  85. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/plot_store.py +0 -0
  86. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/report/__init__.py +0 -0
  87. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/report/excel_template.py +0 -0
  88. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/report/report.py +0 -0
  89. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_analyser/report/templates/summary.xlsx +0 -0
  90. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_progress/__init__.py +0 -0
  91. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_progress/mod.py +0 -0
  92. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_risk/__init__.py +0 -0
  93. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_risk/mod.py +0 -0
  94. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_risk/validators/__init__.py +0 -0
  95. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_risk/validators/cash_validator.py +0 -0
  96. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_risk/validators/is_trading_validator.py +0 -0
  97. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_risk/validators/price_validator.py +0 -0
  98. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_risk/validators/self_trade_validator.py +0 -0
  99. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_scheduler/__init__.py +0 -0
  100. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_scheduler/mod.py +0 -0
  101. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_scheduler/scheduler.py +0 -0
  102. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_simulation/__init__.py +0 -0
  103. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_simulation/mod.py +0 -0
  104. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_simulation/signal_broker.py +0 -0
  105. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_simulation/simulation_broker.py +0 -0
  106. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_simulation/simulation_event_source.py +0 -0
  107. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_simulation/slippage.py +0 -0
  108. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_simulation/testing.py +0 -0
  109. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_simulation/validator.py +0 -0
  110. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_transaction_cost/__init__.py +0 -0
  111. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_transaction_cost/deciders.py +0 -0
  112. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/rqalpha_mod_sys_transaction_cost/mod.py +0 -0
  113. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod/utils.py +0 -0
  114. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/mod_config.yml +0 -0
  115. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/model/__init__.py +0 -0
  116. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/model/bar.py +0 -0
  117. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/model/instrument.py +0 -0
  118. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/model/order.py +0 -0
  119. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/model/tick.py +0 -0
  120. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/model/trade.py +0 -0
  121. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/portfolio/__init__.py +0 -0
  122. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/portfolio/account.py +0 -0
  123. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/portfolio/position.py +0 -0
  124. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/resource/ricequant-logo.png +0 -0
  125. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/user_module.py +0 -0
  126. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/__init__.py +0 -0
  127. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/arg_checker.py +0 -0
  128. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/class_helper.py +0 -0
  129. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/click_helper.py +0 -0
  130. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/concurrent.py +0 -0
  131. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/config.py +0 -0
  132. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/datetime_func.py +0 -0
  133. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/dict_func.py +0 -0
  134. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/exception.py +0 -0
  135. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/functools.py +0 -0
  136. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/i18n.py +0 -0
  137. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/log_capture.py +0 -0
  138. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/logger.py +0 -0
  139. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/package_helper.py +0 -0
  140. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/persisit_helper.py +0 -0
  141. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/repr.py +0 -0
  142. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/risk_free_helper.py +0 -0
  143. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/rq_json.py +0 -0
  144. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/strategy_loader_help.py +0 -0
  145. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/testing/__init__.py +0 -0
  146. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/testing/fixtures.py +0 -0
  147. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/testing/mocking.py +0 -0
  148. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/translations/__init__.py +0 -0
  149. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/translations/zh_Hans_CN/LC_MESSAGES/__init__.py +0 -0
  150. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/translations/zh_Hans_CN/LC_MESSAGES/messages.mo +0 -0
  151. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/translations/zh_Hans_CN/LC_MESSAGES/messages.po +0 -0
  152. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/translations/zh_Hans_CN/__init__.py +0 -0
  153. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha/utils/typing.py +0 -0
  154. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha.egg-info/SOURCES.txt +0 -0
  155. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha.egg-info/dependency_links.txt +0 -0
  156. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha.egg-info/entry_points.txt +0 -0
  157. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha.egg-info/not-zip-safe +0 -0
  158. {rqalpha-5.6.0 → rqalpha-5.6.2}/rqalpha.egg-info/top_level.txt +0 -0
  159. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/__init__.py +0 -0
  160. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/__init__.py +0 -0
  161. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/__init__.py +0 -0
  162. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_accounts/__init__.py +0 -0
  163. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_accounts/test_account_model.py +0 -0
  164. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_accounts/test_futures_settlement_price_type.py +0 -0
  165. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_accounts/test_margin_stocks.py +0 -0
  166. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_accounts/test_position_models.py +0 -0
  167. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_scheduler/__init__.py +0 -0
  168. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_scheduler/test_physical_time.py +0 -0
  169. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_scheduler/test_scheduler.py +0 -0
  170. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_simulation/__init__.py +0 -0
  171. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_simulation/test_management_fee.py +0 -0
  172. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_simulation/test_match.py +0 -0
  173. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_simulation/test_signal_broker.py +0 -0
  174. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_simulation/test_simulation_broker.py +0 -0
  175. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_simulation/test_simulation_event_source.py +0 -0
  176. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_transaction_cost/__init__.py +0 -0
  177. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/mod/sys_transaction_cost/test_commission_multiplier.py +0 -0
  178. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/test_api_base.py +0 -0
  179. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/test_api_future.py +0 -0
  180. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/test_api_stock.py +0 -0
  181. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/test_config.py +0 -0
  182. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/api_tests/utils.py +0 -0
  183. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_f_buy_and_hold.py +0 -0
  184. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_f_delivery.py +0 -0
  185. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_f_macd.py +0 -0
  186. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_f_macd_signal.py +0 -0
  187. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_f_mean_reverting.py +0 -0
  188. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_f_tick_size.py +0 -0
  189. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_s_buy_and_hold.py +0 -0
  190. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_s_dual_thrust.py +0 -0
  191. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_s_pit_tax.py +0 -0
  192. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_s_scheduler.py +0 -0
  193. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_s_tick_size.py +0 -0
  194. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_s_turtle.py +0 -0
  195. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_s_turtle_signal.py +0 -0
  196. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/test_sf_buy_and_hold.py +0 -0
  197. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/unittest/__init__.py +0 -0
  198. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/unittest/test_data/__init__.py +0 -0
  199. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/unittest/test_data/test_auto_update_bundle/__init__.py +0 -0
  200. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/unittest/test_data/test_auto_update_bundle/test_auto_update_bundle_mixin.py +0 -0
  201. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/unittest/test_data/test_instrument_mixin.py +0 -0
  202. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/unittest/test_data/test_trading_dates_mixin.py +0 -0
  203. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/unittest/test_mod/__init__.py +0 -0
  204. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/unittest/test_mod/test_sys_simulation/__init__.py +0 -0
  205. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/unittest/test_mod/test_sys_simulation/test_simulation_event_source.py +0 -0
  206. {rqalpha-5.6.0 → rqalpha-5.6.2}/tests/utils.py +0 -0
  207. {rqalpha-5.6.0 → rqalpha-5.6.2}/versioneer.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rqalpha
3
- Version: 5.6.0
3
+ Version: 5.6.2
4
4
  Summary: Ricequant Algorithm Trading System
5
5
  Home-page: https://github.com/ricequant/rqalpha
6
6
  Author: ricequant
@@ -19,7 +19,8 @@ Classifier: Programming Language :: Python :: 3.13
19
19
  Requires-Python: >=3.6
20
20
  License-File: LICENSE
21
21
  Requires-Dist: requests
22
- Requires-Dist: numpy<2.0.0
22
+ Requires-Dist: numpy<2.0.0; python_version <= "3.11"
23
+ Requires-Dist: numpy>=2.0.0; python_version >= "3.12"
23
24
  Requires-Dist: pandas>=1.0.5
24
25
  Requires-Dist: python-dateutil
25
26
  Requires-Dist: six
@@ -8,11 +8,11 @@ import json
8
8
 
9
9
  version_json = '''
10
10
  {
11
- "date": "2025-07-28T09:56:58+0800",
11
+ "date": "2025-08-12T16:39:32+0800",
12
12
  "dirty": false,
13
13
  "error": null,
14
- "full-revisionid": "faed23cd019cf672076d46299596583de74e23cb",
15
- "version": "5.6.0"
14
+ "full-revisionid": "df666766edc9f646d9064cedd7c841d58fa67a46",
15
+ "version": "5.6.2"
16
16
  }
17
17
  ''' # END VERSION_JSON
18
18
 
@@ -83,7 +83,8 @@ class BaseDataSource(AbstractDataSource):
83
83
  INSTRUMENT_TYPE.INDX: DayBarStore(_p('indexes.h5')),
84
84
  INSTRUMENT_TYPE.FUTURE: FutureDayBarStore(_p('futures.h5')),
85
85
  INSTRUMENT_TYPE.ETF: funds_day_bar_store,
86
- INSTRUMENT_TYPE.LOF: funds_day_bar_store
86
+ INSTRUMENT_TYPE.LOF: funds_day_bar_store,
87
+ INSTRUMENT_TYPE.REITs: funds_day_bar_store
87
88
  } # type: Dict[INSTRUMENT_TYPE, AbstractDayBarStore]
88
89
 
89
90
  self._future_info_store = FutureInfoStore(_p("future_info.json"), custom_future_info)
@@ -16,6 +16,7 @@
16
16
  # 详细的授权流程,请联系 public@ricequant.com 获取。
17
17
 
18
18
  import os
19
+ import re
19
20
  import pandas
20
21
  import pickle
21
22
  import jsonpickle
@@ -51,6 +52,9 @@ def _get_yearly_risk_free_rates(
51
52
  start_date = datetime.date(year + 1, 1, 1)
52
53
 
53
54
 
55
+ EQUITIES_OID_RE = re.compile(r"^\d{6}\.(XSHE|XSHG|BJSE)$")
56
+
57
+
54
58
  class AnalyserMod(AbstractMod):
55
59
  def __init__(self):
56
60
  self._env = None
@@ -434,7 +438,7 @@ class AnalyserMod(AbstractMod):
434
438
  }
435
439
 
436
440
  if not trades.empty and all(
437
- trades.order_book_id.str.endswith(".XSHE") | trades.order_book_id.str.endswith(".XSHG")
441
+ EQUITIES_OID_RE.match(trade.order_book_id) for trade in trades.itertuples() # type: ignore
438
442
  ):
439
443
  # 策略仅交易股票、指数、场内基金等品种时才计算换手率
440
444
  trades_values = trades.last_price * trades.last_quantity
@@ -16,7 +16,7 @@
16
16
  # 详细的授权流程,请联系 public@ricequant.com 获取。
17
17
  import datetime
18
18
  from collections import defaultdict
19
- from copy import copy
19
+ import math
20
20
  from rqalpha.const import MATCHING_TYPE, ORDER_TYPE, POSITION_EFFECT, SIDE
21
21
  from rqalpha.environment import Environment
22
22
  from rqalpha.core.events import EVENT, Event
@@ -25,11 +25,26 @@ from rqalpha.model.trade import Trade
25
25
  from rqalpha.model.tick import TickObject
26
26
  from rqalpha.portfolio.account import Account
27
27
  from rqalpha.utils import is_valid_price
28
+ from rqalpha.interface import AbstractPriceBoard
28
29
  from typing import Dict
29
30
  from rqalpha.utils.i18n import gettext as _
30
31
  from .slippage import SlippageDecider
31
32
 
32
33
 
34
+ LIMIT_PRICE_VALID_THRESHOLD = 1e-7
35
+
36
+
37
+ def _price_reaches_limit(order_book_id: str, side: SIDE, deal_price: float, price_board: AbstractPriceBoard):
38
+ if side == SIDE.BUY:
39
+ limit_price = price_board.get_limit_up(order_book_id)
40
+ return deal_price >= limit_price or math.isclose(deal_price, limit_price, abs_tol=LIMIT_PRICE_VALID_THRESHOLD)
41
+ elif side == SIDE.SELL:
42
+ limit_price = price_board.get_limit_down(order_book_id)
43
+ return deal_price <= limit_price or math.isclose(deal_price, limit_price, abs_tol=LIMIT_PRICE_VALID_THRESHOLD)
44
+ else:
45
+ raise ValueError(f"Unsupport side: {side}")
46
+
47
+
33
48
  class AbstractMatcher:
34
49
  def match(self, account, order, open_auction):
35
50
  # type: (Account, Order, bool) -> None
@@ -127,8 +142,6 @@ class DefaultBarMatcher(AbstractMatcher):
127
142
  else:
128
143
  # 撮合的时候无行情数据也不需要撤单,等到有行情再撮合
129
144
  reason = None
130
- # reason = _(u"Order Cancelled: current bar [{order_book_id}] miss market data.").format(
131
- # order_book_id=order.order_book_id)
132
145
  if reason:
133
146
  order.mark_rejected(reason)
134
147
  return
@@ -141,22 +154,14 @@ class DefaultBarMatcher(AbstractMatcher):
141
154
  return
142
155
  # 是否限制涨跌停不成交
143
156
  if self._price_limit:
144
- if order.side == SIDE.BUY and deal_price >= price_board.get_limit_up(order_book_id):
145
- return
146
- if order.side == SIDE.SELL and deal_price <= price_board.get_limit_down(order_book_id):
157
+ if _price_reaches_limit(order_book_id, order.side, deal_price, price_board):
147
158
  return
148
159
  else:
149
160
  if self._price_limit:
150
- if order.side == SIDE.BUY and deal_price >= price_board.get_limit_up(order_book_id):
151
- reason = _(
152
- "Order Cancelled: current bar [{order_book_id}] reach the limit_up price."
153
- ).format(order_book_id=order.order_book_id)
154
- order.mark_rejected(reason)
155
- return
156
- if order.side == SIDE.SELL and deal_price <= price_board.get_limit_down(order_book_id):
161
+ if _price_reaches_limit(order_book_id, order.side, deal_price, price_board):
157
162
  reason = _(
158
- "Order Cancelled: current bar [{order_book_id}] reach the limit_down price."
159
- ).format(order_book_id=order.order_book_id)
163
+ "Order Cancelled: current bar [{order_book_id}] reach the {limit_up_or_down} price."
164
+ ).format(order_book_id=order.order_book_id, limit_up_or_down="limit_up" if order.side == SIDE.BUY else "limit_down")
160
165
  order.mark_rejected(reason)
161
166
  return
162
167
 
@@ -372,9 +377,7 @@ class DefaultTickMatcher(AbstractMatcher):
372
377
  return
373
378
  # 是否限制涨跌停不成交
374
379
  if self._price_limit:
375
- if order.side == SIDE.BUY and deal_price >= price_board.get_limit_up(order_book_id):
376
- return
377
- if order.side == SIDE.SELL and deal_price <= price_board.get_limit_down(order_book_id):
380
+ if _price_reaches_limit(order_book_id, order.side, deal_price, price_board):
378
381
  return
379
382
  if self._liquidity_limit:
380
383
  if order.side == SIDE.BUY and price_board.get_a1(order_book_id) == 0:
@@ -383,16 +386,10 @@ class DefaultTickMatcher(AbstractMatcher):
383
386
  return
384
387
  else:
385
388
  if self._price_limit:
386
- if order.side == SIDE.BUY and deal_price >= price_board.get_limit_up(order_book_id):
387
- reason = _(
388
- "Order Cancelled: current tick [{order_book_id}] reach the limit_up price."
389
- ).format(order_book_id=order.order_book_id)
390
- order.mark_rejected(reason)
391
- return
392
- if order.side == SIDE.SELL and deal_price <= price_board.get_limit_down(order_book_id):
389
+ if _price_reaches_limit(order_book_id, order.side, deal_price, price_board):
393
390
  reason = _(
394
- "Order Cancelled: current tick [{order_book_id}] reach the limit_down price."
395
- ).format(order_book_id=order.order_book_id)
391
+ "Order Cancelled: current tick [{order_book_id}] reach the {limit_up_or_down} price."
392
+ ).format(order_book_id=order.order_book_id, limit_up_or_down="limit_up" if order.side == SIDE.BUY else "limit_down")
396
393
  order.mark_rejected(reason)
397
394
  return
398
395
  if self._liquidity_limit:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rqalpha
3
- Version: 5.6.0
3
+ Version: 5.6.2
4
4
  Summary: Ricequant Algorithm Trading System
5
5
  Home-page: https://github.com/ricequant/rqalpha
6
6
  Author: ricequant
@@ -19,7 +19,8 @@ Classifier: Programming Language :: Python :: 3.13
19
19
  Requires-Python: >=3.6
20
20
  License-File: LICENSE
21
21
  Requires-Dist: requests
22
- Requires-Dist: numpy<2.0.0
22
+ Requires-Dist: numpy<2.0.0; python_version <= "3.11"
23
+ Requires-Dist: numpy>=2.0.0; python_version >= "3.12"
23
24
  Requires-Dist: pandas>=1.0.5
24
25
  Requires-Dist: python-dateutil
25
26
  Requires-Dist: six
@@ -1,5 +1,4 @@
1
1
  requests
2
- numpy<2.0.0
3
2
  pandas>=1.0.5
4
3
  python-dateutil
5
4
  six
@@ -16,5 +15,11 @@ openpyxl
16
15
  methodtools
17
16
  filelock
18
17
 
18
+ [:python_version <= "3.11"]
19
+ numpy<2.0.0
20
+
21
+ [:python_version >= "3.12"]
22
+ numpy>=2.0.0
23
+
19
24
  [profiler]
20
25
  line_profiler
@@ -1,6 +1,6 @@
1
1
  [metadata]
2
2
  name = rqalpha
3
- version = 5.6.0
3
+ version = 5.6.2
4
4
 
5
5
  [versioneer]
6
6
  VCS = git
@@ -17,7 +17,8 @@ import versioneer
17
17
 
18
18
  requirements = [
19
19
  'requests',
20
- 'numpy < 2.0.0',
20
+ 'numpy < 2.0.0 ; python_version <= "3.11"',
21
+ 'numpy >=2.0.0 ; python_version >= "3.12"',
21
22
  'pandas >=1.0.5',
22
23
  'python-dateutil',
23
24
  'six',
@@ -272,7 +272,7 @@ def test_future_position_queue_close_today():
272
272
  "start_date": "2016-03-07",
273
273
  "end_date": "2016-03-08",
274
274
  "accounts": {
275
- "future": 1000000
275
+ "future": 10000000
276
276
  }
277
277
  }
278
278
  }
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes