onetick-py 1.172.0__tar.gz → 1.174.0__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 (163) hide show
  1. {onetick_py-1.172.0/src/onetick_py.egg-info → onetick_py-1.174.0}/PKG-INFO +12 -26
  2. {onetick_py-1.172.0 → onetick_py-1.174.0}/pyproject.toml +3 -0
  3. onetick_py-1.174.0/requirements.strict.txt +10 -0
  4. onetick_py-1.174.0/requirements.txt +13 -0
  5. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/_version.py +1 -1
  6. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/aggregations/_base.py +1 -1
  7. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/aggregations/order_book.py +13 -7
  8. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/aggregations/other.py +2 -2
  9. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/compatibility.py +15 -10
  10. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/configuration.py +3 -2
  11. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/misc.py +59 -13
  12. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/symbol.py +5 -2
  13. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/_methods/conversions.py +3 -2
  14. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/_methods/op_types.py +12 -3
  15. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/base.py +2 -2
  16. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/source.py +9 -1
  17. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/functions.py +3 -2
  18. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/run.py +3 -1
  19. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/types.py +127 -59
  20. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/render.py +271 -58
  21. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/types.py +2 -0
  22. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/tz.py +8 -6
  23. {onetick_py-1.172.0 → onetick_py-1.174.0/src/onetick_py.egg-info}/PKG-INFO +12 -26
  24. onetick_py-1.174.0/src/onetick_py.egg-info/requires.txt +41 -0
  25. onetick_py-1.172.0/requirements.strict.txt +0 -9
  26. onetick_py-1.172.0/requirements.txt +0 -32
  27. onetick_py-1.172.0/src/onetick_py.egg-info/requires.txt +0 -85
  28. {onetick_py-1.172.0 → onetick_py-1.174.0}/LICENSE +0 -0
  29. {onetick_py-1.172.0 → onetick_py-1.174.0}/README.md +0 -0
  30. {onetick_py-1.172.0 → onetick_py-1.174.0}/setup.cfg +0 -0
  31. {onetick_py-1.172.0 → onetick_py-1.174.0}/setup.py +0 -0
  32. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/locator_parser/__init__.py +0 -0
  33. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/locator_parser/acl.py +0 -0
  34. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/locator_parser/actions.py +0 -0
  35. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/locator_parser/common.py +0 -0
  36. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/locator_parser/io.py +0 -0
  37. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/locator_parser/locator.py +0 -0
  38. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/__init__.py +0 -0
  39. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/doc_utilities/__init__.py +0 -0
  40. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/doc_utilities/napoleon.py +0 -0
  41. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/doc_utilities/ot_doctest.py +0 -0
  42. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/doc_utilities/snippets.py +0 -0
  43. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/lib/__init__.py +0 -0
  44. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/lib/instance.py +0 -0
  45. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/__init__.py +0 -0
  46. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/_stack_info.py +0 -0
  47. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/aggregations/__init__.py +0 -0
  48. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/aggregations/_docs.py +0 -0
  49. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/aggregations/compute.py +0 -0
  50. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/aggregations/functions.py +0 -0
  51. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/aggregations/generic.py +0 -0
  52. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/aggregations/high_low.py +0 -0
  53. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/aggregations/num_distinct.py +0 -0
  54. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/backports.py +0 -0
  55. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/cache.py +0 -0
  56. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/callback/__init__.py +0 -0
  57. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/callback/callback.py +0 -0
  58. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/callback/callbacks.py +0 -0
  59. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/__init__.py +0 -0
  60. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_csv_inspector.py +0 -0
  61. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_internal/__init__.py +0 -0
  62. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_internal/_manually_bound_value.py +0 -0
  63. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_internal/_nodes_history.py +0 -0
  64. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_internal/_op_utils/__init__.py +0 -0
  65. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_internal/_op_utils/every_operand.py +0 -0
  66. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_internal/_op_utils/is_const.py +0 -0
  67. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_internal/_per_tick_scripts/tick_list_sort_template.script +0 -0
  68. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_internal/_proxy_node.py +0 -0
  69. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_internal/_state_objects.py +0 -0
  70. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_internal/_state_vars.py +0 -0
  71. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/__init__.py +0 -0
  72. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/_symbol_param.py +0 -0
  73. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/schema.py +0 -0
  74. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/__init__.py +0 -0
  75. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/aggregations.py +0 -0
  76. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/applyers.py +0 -0
  77. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/columns.py +0 -0
  78. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/data_quality.py +0 -0
  79. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/debugs.py +0 -0
  80. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/drops.py +0 -0
  81. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/fields.py +0 -0
  82. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/filters.py +0 -0
  83. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/joins.py +0 -0
  84. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/merges.py +0 -0
  85. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/pandases.py +0 -0
  86. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/renames.py +0 -0
  87. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/sorts.py +0 -0
  88. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/switches.py +0 -0
  89. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/symbols.py +0 -0
  90. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/times.py +0 -0
  91. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/source_methods/writes.py +0 -0
  92. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/_source/tmp_otq.py +0 -0
  93. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column.py +0 -0
  94. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/__init__.py +0 -0
  95. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/_methods/__init__.py +0 -0
  96. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/_methods/_internal.py +0 -0
  97. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/_methods/methods.py +0 -0
  98. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/accessors/__init__.py +0 -0
  99. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/accessors/_accessor.py +0 -0
  100. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/accessors/decimal_accessor.py +0 -0
  101. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/accessors/dt_accessor.py +0 -0
  102. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/accessors/float_accessor.py +0 -0
  103. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/column_operations/accessors/str_accessor.py +0 -0
  104. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/cut_builder.py +0 -0
  105. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/db_constants.py +0 -0
  106. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/eval_query.py +0 -0
  107. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/lambda_object.py +0 -0
  108. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/multi_output_source.py +0 -0
  109. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/per_tick_script.py +0 -0
  110. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/core/query_inspector.py +0 -0
  111. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/db/__init__.py +0 -0
  112. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/db/_inspection.py +0 -0
  113. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/db/db.py +0 -0
  114. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/db/utils.py +0 -0
  115. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/docs/__init__.py +0 -0
  116. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/docs/docstring_parser.py +0 -0
  117. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/docs/utils.py +0 -0
  118. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/license.py +0 -0
  119. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/log.py +0 -0
  120. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/math.py +0 -0
  121. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/misc.py +0 -0
  122. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/oqd/__init__.py +0 -0
  123. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/oqd/eps.py +0 -0
  124. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/oqd/sources.py +0 -0
  125. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/otq.py +0 -0
  126. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/pyomd_mock.py +0 -0
  127. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/servers.py +0 -0
  128. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/session.py +0 -0
  129. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/__init__.py +0 -0
  130. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/cache.py +0 -0
  131. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/common.py +0 -0
  132. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/csv.py +0 -0
  133. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/custom.py +0 -0
  134. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/data_file.py +0 -0
  135. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/data_source.py +0 -0
  136. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/empty.py +0 -0
  137. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/odbc.py +0 -0
  138. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/order_book.py +0 -0
  139. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/parquet.py +0 -0
  140. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/pit.py +0 -0
  141. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/query.py +0 -0
  142. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/snapshots.py +0 -0
  143. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/split_query_output_by_symbol.py +0 -0
  144. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/symbology_mapping.py +0 -0
  145. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/symbols.py +0 -0
  146. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sources/ticks.py +0 -0
  147. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/sql.py +0 -0
  148. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/state.py +0 -0
  149. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/__init__.py +0 -0
  150. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/acl.py +0 -0
  151. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/config.py +0 -0
  152. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/default.py +0 -0
  153. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/file.py +0 -0
  154. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/helpers.py +0 -0
  155. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/locator.py +0 -0
  156. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/perf.py +0 -0
  157. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/query.py +0 -0
  158. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/script.py +0 -0
  159. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick/py/utils/temp.py +0 -0
  160. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick_py.egg-info/SOURCES.txt +0 -0
  161. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick_py.egg-info/dependency_links.txt +0 -0
  162. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick_py.egg-info/entry_points.txt +0 -0
  163. {onetick_py-1.172.0 → onetick_py-1.174.0}/src/onetick_py.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: onetick-py
3
- Version: 1.172.0
3
+ Version: 1.174.0
4
4
  Summary: Python package that allows you to work with OneTick
5
5
  Author-email: solutions <solutions@onetick.com>
6
6
  License-Expression: MIT
@@ -19,40 +19,26 @@ Classifier: Environment :: Console
19
19
  Requires-Python: >=3.9
20
20
  Description-Content-Type: text/markdown
21
21
  License-File: LICENSE
22
- Requires-Dist: pandas==1.1.5; python_version == "3.6"
23
- Requires-Dist: pandas==1.3.4; python_version == "3.7"
24
- Requires-Dist: pandas<2.1.0,>=1.3.4; python_version == "3.8"
25
- Requires-Dist: pandas<2.3.0,>=1.3.4; python_version == "3.9"
26
- Requires-Dist: pandas<2.3.0,>=1.5.1; python_version == "3.10"
27
- Requires-Dist: pandas<2.3.0,>=1.5.3; python_version == "3.11"
28
- Requires-Dist: pandas<2.3.0,>=2.2.0; python_version >= "3.12"
29
- Requires-Dist: pyarrow; python_version >= "3.12"
30
- Requires-Dist: numpy==1.19.5; python_version <= "3.7"
31
- Requires-Dist: numpy==1.21.6; python_version == "3.8"
32
- Requires-Dist: numpy<2.3.0,>=1.20.3; python_version >= "3.9"
22
+ Requires-Dist: pandas>=1.5.2
23
+ Requires-Dist: numpy
33
24
  Requires-Dist: coolname
34
25
  Requires-Dist: python-dateutil
35
26
  Requires-Dist: python-dotenv
36
27
  Requires-Dist: tzlocal
37
28
  Requires-Dist: tzdata
38
- Requires-Dist: backports.zoneinfo==0.2.1; python_version < "3.9"
39
- Requires-Dist: typing_extensions==4.7.1; python_version < "3.8"
40
- Requires-Dist: singledispatchmethod==1.0; python_version < "3.8"
41
- Requires-Dist: backports.cached-property==1.0.2; python_version <= "3.8"
42
- Requires-Dist: backports.functools-lru-cache==1.6.6; python_version <= "3.8"
43
- Requires-Dist: astunparse==1.6.3; python_version <= "3.8"
44
29
  Requires-Dist: graphviz==0.20.1; python_version > "3.6"
45
30
  Requires-Dist: packaging>=21.0
46
31
  Provides-Extra: strict
47
- Requires-Dist: numpy==1.19.5; python_version <= "3.7" and extra == "strict"
48
- Requires-Dist: numpy==1.21.6; python_version == "3.8" and extra == "strict"
49
- Requires-Dist: numpy==1.23.0; (python_version >= "3.9" and python_version <= "3.10") and extra == "strict"
50
- Requires-Dist: numpy==1.26.4; (python_version >= "3.11" and python_version <= "3.12") and extra == "strict"
51
- Requires-Dist: pandas==1.1.5; python_version == "3.6" and extra == "strict"
52
- Requires-Dist: pandas==1.3.4; (python_version >= "3.7" and python_version <= "3.9") and extra == "strict"
53
- Requires-Dist: pandas==1.5.1; python_version == "3.10" and extra == "strict"
32
+ Requires-Dist: numpy==1.23.0; python_version == "3.9" and extra == "strict"
33
+ Requires-Dist: numpy==1.23.0; python_version == "3.10" and extra == "strict"
34
+ Requires-Dist: numpy==1.26.4; python_version == "3.11" and extra == "strict"
35
+ Requires-Dist: numpy==1.26.4; python_version == "3.12" and extra == "strict"
36
+ Requires-Dist: pandas==1.5.2; python_version == "3.9" and extra == "strict"
37
+ Requires-Dist: pandas==1.5.3; python_version == "3.10" and extra == "strict"
54
38
  Requires-Dist: pandas==1.5.3; python_version == "3.11" and extra == "strict"
55
- Requires-Dist: pandas==2.2.0; python_version >= "3.12" and extra == "strict"
39
+ Requires-Dist: pandas==2.2.1; python_version == "3.12" and extra == "strict"
40
+ Requires-Dist: pandas==2.3.0; python_version == "3.13" and extra == "strict"
41
+ Requires-Dist: pandas==2.3.3; python_version == "3.14" and extra == "strict"
56
42
  Provides-Extra: webapi
57
43
  Requires-Dist: onetick.query_webapi; extra == "webapi"
58
44
  Provides-Extra: polars
@@ -28,6 +28,9 @@ classifiers = [
28
28
  "Programming Language :: Python :: 3.11",
29
29
  "Programming Language :: Python :: 3.12",
30
30
  "Programming Language :: Python :: 3.13",
31
+ # OneTick server and onetick.query-webapi do not support it yet
32
+ # mantis [onetick 0037046]: Add support of python 3.14
33
+ # "Programming Language :: Python :: 3.14",
31
34
  "Operating System :: OS Independent",
32
35
  "Environment :: Console",
33
36
  ]
@@ -0,0 +1,10 @@
1
+ numpy==1.23.0; python_version == '3.9'
2
+ numpy==1.23.0; python_version == '3.10'
3
+ numpy==1.26.4; python_version == '3.11'
4
+ numpy==1.26.4; python_version == '3.12'
5
+ pandas==1.5.2; python_version == '3.9'
6
+ pandas==1.5.3; python_version == '3.10'
7
+ pandas==1.5.3; python_version == '3.11'
8
+ pandas==2.2.1; python_version == '3.12'
9
+ pandas==2.3.0; python_version == '3.13'
10
+ pandas==2.3.3; python_version == '3.14'
@@ -0,0 +1,13 @@
1
+ # open source packages
2
+ # >= 1.5.0 is needed for support of zoneinfo timezone objects
3
+ pandas>=1.5.2
4
+ numpy
5
+
6
+ coolname
7
+ python-dateutil
8
+ python-dotenv
9
+ tzlocal
10
+ tzdata
11
+
12
+ graphviz==0.20.1; python_version > '3.6'
13
+ packaging >= 21.0
@@ -1,2 +1,2 @@
1
1
  # This file was generated automatically. DO NOT CHANGE.
2
- VERSION = '1.172.0'
2
+ VERSION = '1.174.0'
@@ -547,7 +547,7 @@ class _AggregationTSSelection(_Aggregation):
547
547
 
548
548
  class _FloatAggregation(_Aggregation):
549
549
 
550
- require_type = (int, float, ott._inf)
550
+ require_type = (int, float, ott._inf, ott.decimal)
551
551
 
552
552
  """
553
553
  Aggregation that expect int or float as input
@@ -229,6 +229,9 @@ class ObSnapshot(_OrderBookAggregation):
229
229
  # we don't want to set hard limit on the output of order book aggregations
230
230
  if self.show_full_detail:
231
231
  kwargs['all_fields'] = True
232
+ self._size_type = int
233
+ if self.size_max_fractional_digits > 0:
234
+ self._size_type = float # type: ignore[assignment]
232
235
  super().__init__(*args, **kwargs)
233
236
 
234
237
  def _param_validation(self):
@@ -244,7 +247,7 @@ class ObSnapshot(_OrderBookAggregation):
244
247
  def _get_output_schema(self, src: 'Source', name: Optional[str] = None) -> dict:
245
248
  schema = {
246
249
  'PRICE': float,
247
- 'SIZE': int,
250
+ 'SIZE': self._size_type,
248
251
  'LEVEL': int,
249
252
  'UPDATE_TIME': otp.nsectime,
250
253
  'BUY_SELL_FLAG': int,
@@ -265,10 +268,10 @@ class ObSnapshotWide(ObSnapshot):
265
268
  def _get_output_schema(self, src: 'Source', name: Optional[str] = None) -> dict:
266
269
  schema = {
267
270
  'BID_PRICE': float,
268
- 'BID_SIZE': int,
271
+ 'BID_SIZE': self._size_type,
269
272
  'BID_UPDATE_TIME': otp.nsectime,
270
273
  'ASK_PRICE': float,
271
- 'ASK_SIZE': int,
274
+ 'ASK_SIZE': self._size_type,
272
275
  'ASK_UPDATE_TIME': otp.nsectime,
273
276
  'LEVEL': int,
274
277
  }
@@ -299,10 +302,10 @@ class ObSnapshotFlat(ObSnapshot):
299
302
  for level in range(1, self.max_levels + 1):
300
303
  schema.update({
301
304
  f'BID_PRICE{level}': float,
302
- f'BID_SIZE{level}': int,
305
+ f'BID_SIZE{level}': self._size_type,
303
306
  f'BID_UPDATE_TIME{level}': otp.nsectime,
304
307
  f'ASK_PRICE{level}': float,
305
- f'ASK_SIZE{level}': int,
308
+ f'ASK_SIZE{level}': self._size_type,
306
309
  f'ASK_UPDATE_TIME{level}': otp.nsectime,
307
310
  })
308
311
  return schema
@@ -343,6 +346,9 @@ class ObSummary(_OrderBookAggregation):
343
346
  self.state_key_max_inactivity_sec = state_key_max_inactivity_sec
344
347
  self.size_max_fractional_digits = size_max_fractional_digits
345
348
  self.include_market_order_ticks = include_market_order_ticks
349
+ self._size_type = int
350
+ if self.size_max_fractional_digits > 0:
351
+ self._size_type = float # type: ignore[assignment]
346
352
  super().__init__(*args, **kwargs)
347
353
 
348
354
  def _param_validation(self):
@@ -357,12 +363,12 @@ class ObSummary(_OrderBookAggregation):
357
363
 
358
364
  def _get_output_schema(self, src: 'Source', name: Optional[str] = None) -> dict:
359
365
  schema = {
360
- 'BID_SIZE': int,
366
+ 'BID_SIZE': self._size_type,
361
367
  'BID_VWAP': float,
362
368
  'BEST_BID_PRICE': float,
363
369
  'WORST_BID_PRICE': float,
364
370
  'NUM_BID_LEVELS': int,
365
- 'ASK_SIZE': int,
371
+ 'ASK_SIZE': self._size_type,
366
372
  'ASK_VWAP': float,
367
373
  'BEST_ASK_PRICE': float,
368
374
  'WORST_ASK_PRICE': float,
@@ -100,7 +100,7 @@ class Vwap(_Aggregation):
100
100
  FIELDS_TO_SKIP: List = ['column_name']
101
101
 
102
102
  output_field_type = float
103
- require_type = (int, float, ott.nsectime)
103
+ require_type = (int, float, ott.nsectime, ott.decimal)
104
104
 
105
105
  def __init__(self,
106
106
  price_column: str,
@@ -271,7 +271,7 @@ class Average(_FloatAggregation):
271
271
  class StdDev(_Aggregation): # Stddev does not support inf, so no need to use _FloatAggregation
272
272
  NAME = "STDDEV"
273
273
  EP = otq.Stddev
274
- require_type = (int, float)
274
+ require_type = (int, float, ott.decimal)
275
275
  output_field_type = float
276
276
  FIELDS_MAPPING = deepcopy(_Aggregation.FIELDS_MAPPING)
277
277
  FIELDS_MAPPING['biased'] = 'BIASED'
@@ -3,6 +3,7 @@ import warnings
3
3
  from dataclasses import dataclass, astuple
4
4
  from datetime import datetime
5
5
  from typing import Optional
6
+
6
7
  from packaging.version import parse as parse_version
7
8
 
8
9
  import onetick.py as otp
@@ -416,14 +417,15 @@ def is_odbc_query_supported():
416
417
 
417
418
 
418
419
  def is_event_processor_repr_upper():
419
- return _is_min_build_or_version(None, None,
420
- 20240205120000, min_update_number=0) or otq.webapi
420
+ if otq.webapi:
421
+ return True
422
+ return _is_min_build_or_version(1.25, None,
423
+ 20240205120000, min_update_number=0)
421
424
 
422
425
 
423
426
  def is_date_trunc_fixed():
424
- # tests/core/accessors/test_dt.py::TestDateTrunc::test_dst_year
425
- # this test will show, when release fixes the issue
426
- return _is_min_build_or_version(None, None,
427
+ # Fixed 0032253: DATE_TRUNC function returns wrong answer in case of daylight saving time
428
+ return _is_min_build_or_version(1.25, None,
427
429
  20240205120000, min_update_number=0)
428
430
 
429
431
 
@@ -511,7 +513,8 @@ def is_duplicating_quotes_not_supported():
511
513
  # 20240329: Fixed 0032754:
512
514
  # Logical expressions should trigger error when duplicate single(or double) quote
513
515
  # is directly followed or preceded by some name
514
- return _is_min_build_or_version(None, None, 20240330120000)
516
+ return _is_min_build_or_version(1.25, None,
517
+ 20240330120000)
515
518
 
516
519
 
517
520
  def are_quotes_in_query_params_supported():
@@ -681,9 +684,9 @@ def is_ob_virtual_prl_and_show_full_detail_supported():
681
684
 
682
685
 
683
686
  def is_per_tick_script_boolean_problem():
684
- # strange problem, couldn't reproduce it anywhere except a single onetick build
687
+ # strange problem, couldn't reproduce it anywhere except a single onetick release
685
688
  version = get_onetick_version()
686
- return version.release_version == '1.22' and version.build_number in (20220815034358, 20220128183755)
689
+ return version.release_version == '1.22'
687
690
 
688
691
 
689
692
  def is_symbol_time_override_fixed():
@@ -709,8 +712,10 @@ def is_native_plus_zstd_supported():
709
712
 
710
713
  def is_save_snapshot_database_parameter_supported():
711
714
  # 20220929: Implemented 0028559: Update SAVE_SNAPSHOT to specify output database
712
- return _is_min_build_or_version(1.23, 20230605193357,
713
- 20221111120000)
715
+ client_support = 'database' in otq.SaveSnapshot.Parameters.list_parameters()
716
+ server_support = _is_min_build_or_version(1.23, 20230605193357,
717
+ 20221111120000)
718
+ return client_support and server_support
714
719
 
715
720
 
716
721
  def is_join_with_snapshot_snapshot_fields_parameter_supported():
@@ -656,8 +656,9 @@ class Config:
656
656
  )
657
657
 
658
658
  max_expected_ticks_per_symbol = OtpProperty(
659
- description='Expected maximum number of ticks per symbol (used for performance optimizations).',
660
- base_default=2000,
659
+ description='Expected maximum number of ticks per symbol (used for performance optimizations). '
660
+ 'Default is 2000.',
661
+ base_default=None,
661
662
  allowed_types=int,
662
663
  env_var_name='OTP_MAX_EXPECTED_TICKS_PER_SYMBOL',
663
664
  )
@@ -618,6 +618,9 @@ def pnl_realized(
618
618
  The name of the field with price, default is **PRICE**.
619
619
  buy_sell_flag_field: str, :py:class:`otp.Column <onetick.py.Column>`
620
620
  The name of the field with buy/sell flag, default is **BUY_SELL_FLAG**.
621
+ If the type of this field is string, then possible values are 'B' or 'b' for buy and 'S' or 's' for sell.
622
+ If the type of this field is integer, then possible values are 0 for buy and 1 for sell.
623
+
621
624
 
622
625
  See also
623
626
  --------
@@ -625,20 +628,63 @@ def pnl_realized(
625
628
 
626
629
  Examples
627
630
  --------
631
+ Let's generate some data:
628
632
 
629
- Simple usage
630
-
631
- >>> data = otp.DataSource('SOME_DATABASE', tick_type='TT', symbols='AA') # doctest: +SKIP
632
- >>> data = data.pnl_realized() # doctest: +SKIP
633
- >>> otp.run(data) # doctest: +SKIP
634
- Time BUY_SELL_FLAG PRICE SIZE PNL_REALIZED
635
- 0 2003-12-01 00:00:00.000 0 5 20 0.0
636
- 1 2003-12-01 00:00:00.001 0 4 30 0.0
637
- 2 2003-12-01 00:00:00.002 1 3 15 -30.0
638
- 3 2003-12-01 00:00:00.003 0 10 50 0.0
639
- 4 2003-12-01 00:00:00.004 1 7 18 49.0
640
- 5 2003-12-01 00:00:00.005 1 9 6 30.0
641
- 6 2003-12-01 00:00:00.006 0 8 40 0.0
633
+ >>> trades = otp.Ticks(
634
+ ... PRICE=[1.0, 2.0, 3.0, 2.5, 4.0, 5.0, 6.0, 7.0, 3.0, 4.0, 1.0],
635
+ ... SIZE=[700, 20, 570, 600, 100, 100, 100, 100, 150, 10, 100],
636
+ ... SELL_FLAG=[0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1],
637
+ ... SIDE=['B', 'B', 'B', 'S', 'S', 'S', 'S', 'S', 'B', 'B', 'S'],
638
+ ... )
639
+ >>> otp.run(trades)
640
+ Time PRICE SIZE SELL_FLAG SIDE
641
+ 0 2003-12-01 00:00:00.000 1.0 700 0 B
642
+ 1 2003-12-01 00:00:00.001 2.0 20 0 B
643
+ 2 2003-12-01 00:00:00.002 3.0 570 0 B
644
+ 3 2003-12-01 00:00:00.003 2.5 600 1 S
645
+ 4 2003-12-01 00:00:00.004 4.0 100 1 S
646
+ 5 2003-12-01 00:00:00.005 5.0 100 1 S
647
+ 6 2003-12-01 00:00:00.006 6.0 100 1 S
648
+ 7 2003-12-01 00:00:00.007 7.0 100 1 S
649
+ 8 2003-12-01 00:00:00.008 3.0 150 0 B
650
+ 9 2003-12-01 00:00:00.009 4.0 10 0 B
651
+ 10 2003-12-01 00:00:00.010 1.0 100 1 S
652
+
653
+ And then calculate profit and loss metric for it.
654
+
655
+ First let's use string ``buy_sell_flag_field`` field:
656
+
657
+ >>> data = trades.pnl_realized(buy_sell_flag_field='SIDE') # doctest: +SKIP
658
+ >>> otp.run(data)[['Time', 'PRICE', 'SIZE', 'SIDE', 'PNL_REALIZED']] # doctest: +SKIP
659
+ Time PRICE SIZE SIDE PNL_REALIZED
660
+ 0 2003-12-01 00:00:00.000 1.0 700 B 0.0
661
+ 1 2003-12-01 00:00:00.001 2.0 20 B 0.0
662
+ 2 2003-12-01 00:00:00.002 3.0 570 B 0.0
663
+ 3 2003-12-01 00:00:00.003 2.5 600 S 900.0
664
+ 4 2003-12-01 00:00:00.004 4.0 100 S 300.0
665
+ 5 2003-12-01 00:00:00.005 5.0 100 S 220.0
666
+ 6 2003-12-01 00:00:00.006 6.0 100 S 300.0
667
+ 7 2003-12-01 00:00:00.007 7.0 100 S 400.0
668
+ 8 2003-12-01 00:00:00.008 3.0 150 B 0.0
669
+ 9 2003-12-01 00:00:00.009 4.0 10 B 0.0
670
+ 10 2003-12-01 00:00:00.010 1.0 100 S -200.0
671
+
672
+ We can get the same result using integer ``buy_sell_flag_field`` field:
673
+
674
+ >>> data = trades.pnl_realized(buy_sell_flag_field='SELL_FLAG') # doctest: +SKIP
675
+ >>> otp.run(data)[['Time', 'PRICE', 'SIZE', 'SELL_FLAG', 'PNL_REALIZED']] # doctest: +SKIP
676
+ Time PRICE SIZE SELL_FLAG PNL_REALIZED
677
+ 0 2003-12-01 00:00:00.000 1.0 700 0 0.0
678
+ 1 2003-12-01 00:00:00.001 2.0 20 0 0.0
679
+ 2 2003-12-01 00:00:00.002 3.0 570 0 0.0
680
+ 3 2003-12-01 00:00:00.003 2.5 600 1 900.0
681
+ 4 2003-12-01 00:00:00.004 4.0 100 1 300.0
682
+ 5 2003-12-01 00:00:00.005 5.0 100 1 220.0
683
+ 6 2003-12-01 00:00:00.006 6.0 100 1 300.0
684
+ 7 2003-12-01 00:00:00.007 7.0 100 1 400.0
685
+ 8 2003-12-01 00:00:00.008 3.0 150 0 0.0
686
+ 9 2003-12-01 00:00:00.009 4.0 10 0 0.0
687
+ 10 2003-12-01 00:00:00.010 1.0 100 1 -200.0
642
688
  """
643
689
  if computation_method not in ['fifo']:
644
690
  raise ValueError(
@@ -35,7 +35,7 @@ class SymbolType:
35
35
  | :ref:`api/misc/symbol_param:Symbol Parameters Objects`
36
36
  """
37
37
 
38
- self._name = _SymbolParamColumn("_SYMBOL_NAME", str)
38
+ self.__name = _SymbolParamColumn("_SYMBOL_NAME", str)
39
39
 
40
40
  @property
41
41
  def name(self):
@@ -61,7 +61,7 @@ class SymbolType:
61
61
  4 2003-12-01 00:00:00.002 3 S1
62
62
  5 2003-12-01 00:00:00.002 -1 S2
63
63
  """
64
- return self._name
64
+ return self.__name
65
65
 
66
66
  def get(self, name, dtype, default=None):
67
67
  """
@@ -131,6 +131,9 @@ class SymbolType:
131
131
  -------
132
132
  _SymbolParamColumn
133
133
  """
134
+ if item == '__objclass__':
135
+ # fix for PY-1399 (some inspect functions try to access this special attribute)
136
+ raise AttributeError(f"'{self.__class__.__name__}' object has no attribute '{item}'")
134
137
  if not item.startswith('_') and item != 'pytest_mock_example_attribute_that_shouldnt_exist':
135
138
  warnings.warn("`__getattr__` method is deprecated. Please, use `__getitem__` method instead.",
136
139
  FutureWarning, stacklevel=2)
@@ -31,7 +31,7 @@ def float_to_str(prev_op, dtype=str):
31
31
  return MethodResult(op_str, dtype)
32
32
 
33
33
 
34
- def float_to_decimal(prev_op):
34
+ def num_to_decimal(prev_op):
35
35
  return MethodResult(f'decimal({str(prev_op)})', ott.decimal)
36
36
 
37
37
 
@@ -192,7 +192,7 @@ class _ConversionsDict(UserDict):
192
192
 
193
193
  CONVERSIONS = _ConversionsDict({(float, int): float_to_int,
194
194
  (float, str): float_to_str,
195
- (float, ott.decimal): float_to_decimal,
195
+ (float, ott.decimal): num_to_decimal,
196
196
  (ott.decimal, int): float_to_int,
197
197
  (ott.decimal, str): decimal_to_str,
198
198
  (ott.decimal, float): decimal_to_float,
@@ -206,6 +206,7 @@ CONVERSIONS = _ConversionsDict({(float, int): float_to_int,
206
206
  (int, float): int_to_float,
207
207
  (int, ott.nsectime): int_to_nsectime,
208
208
  (int, ott.msectime): int_to_msectime,
209
+ (int, ott.decimal): num_to_decimal,
209
210
  (str, float): str_to_float,
210
211
  (str, ott.decimal): str_to_decimal,
211
212
  (str, int): str_to_int,
@@ -8,9 +8,12 @@ from onetick.py import types as ott
8
8
 
9
9
 
10
10
  def are_numerics(*dtypes):
11
- return all(inspect.isclass(dtype)
12
- and (issubclass(dtype, (float, int)) or np.issubdtype(dtype, np.integer))
13
- and not issubclass(dtype, (ott.nsectime, ott.msectime)) for dtype in dtypes)
11
+ return all(
12
+ inspect.isclass(dtype)
13
+ and (issubclass(dtype, (float, int)) or np.issubdtype(dtype, np.integer) or issubclass(dtype, ott.decimal))
14
+ and not issubclass(dtype, (ott.nsectime, ott.msectime))
15
+ for dtype in dtypes
16
+ )
14
17
 
15
18
 
16
19
  def are_ints_not_time(*dtypes):
@@ -109,6 +112,12 @@ def _get_widest_type(left, right):
109
112
  (<class '...MyTime'>, None, <class '...MyNSec'>)
110
113
  """
111
114
 
115
+ # decimal takes precedence before integer and floating point types
116
+ if issubclass(left, ott.decimal) and are_numerics(right):
117
+ return left
118
+ if are_numerics(left) and issubclass(right, ott.decimal):
119
+ return right
120
+
112
121
  if issubclass(left, float) and issubclass(right, float):
113
122
  # between np.float and float we choose base float
114
123
  if left is not float and np.issubdtype(left, np.floating):
@@ -476,7 +476,7 @@ class Operation:
476
476
  Property that provides access to
477
477
  methods specific to float type.
478
478
  """
479
- if issubclass(self.dtype, float) and self.dtype is not ott.decimal:
479
+ if issubclass(self.dtype, float):
480
480
  from onetick.py.core.column_operations.accessors.float_accessor import _FloatAccessor
481
481
  return _FloatAccessor(self)
482
482
  else:
@@ -1043,7 +1043,7 @@ class Raw(Operation):
1043
1043
  def __init__(self, raw, dtype):
1044
1044
  if dtype is str:
1045
1045
  warnings.warn(
1046
- f'Be careful, default string length in OneTick is {ott.string.DEFAULT_LENGTH}.'
1046
+ f'Be careful, default string length in OneTick is {ott.string.DEFAULT_LENGTH}. '
1047
1047
  "Length of the result raw expression can't be calculated automatically, "
1048
1048
  "so you'd better use onetick.py.string type.",
1049
1049
  stacklevel=2,
@@ -947,7 +947,9 @@ class Source:
947
947
  view: bool = False,
948
948
  line_limit: Optional[Tuple[int, int]] = (10, 30),
949
949
  parse_eval_from_params: bool = False,
950
+ render_debug_info: bool = False,
950
951
  debug: bool = False,
952
+ graphviz_compat_mode: bool = False,
951
953
  **kwargs,
952
954
  ):
953
955
  """
@@ -973,8 +975,13 @@ class Source:
973
975
  If one of tuple values set to zero the corresponding limit disabled.
974
976
  parse_eval_from_params: bool
975
977
  Enable parsing and printing `eval` sub-queries from EP parameters.
978
+ render_debug_info: bool
979
+ Render additional debug information.
976
980
  debug: bool
977
981
  Allow to print stdout or stderr from `Graphviz` render.
982
+ graphviz_compat_mode: bool
983
+ Change internal parameters of result graph for better compatibility with old `Graphviz` versions.
984
+ Could produce larger and less readable graphs.
978
985
  kwargs:
979
986
  Additional arguments to be passed to :py:meth:`onetick.py.Source.to_otq` method (except
980
987
  ``file_name``, ``file_suffix`` and ``query_name`` parameters)
@@ -1006,7 +1013,8 @@ class Source:
1006
1013
 
1007
1014
  otq_path = self.to_otq(**kwargs)
1008
1015
  return render_otq(
1009
- otq_path, image_path, output_format, load_external_otqs, view, line_limit, parse_eval_from_params, debug,
1016
+ otq_path, image_path, output_format, load_external_otqs, view, line_limit, parse_eval_from_params,
1017
+ render_debug_info, debug, graphviz_compat_mode,
1010
1018
  )
1011
1019
 
1012
1020
  def copy(self, ep=None, columns=None, deep=False) -> 'Source':
@@ -327,6 +327,7 @@ def merge(sources, align_schema=True, symbols=None, identify_input_ts=False,
327
327
 
328
328
  if enforce_order:
329
329
  result.drop('OMDSEQ', inplace=True)
330
+ merged_columns.pop('OMDSEQ')
330
331
 
331
332
  if identify_input_ts:
332
333
  result.schema['SYMBOL_NAME' + added_field_name_suffix] = str
@@ -2030,7 +2031,7 @@ def _add_element(cur_res, element, format_spec_additional=None):
2030
2031
  if isinstance(element, Operation):
2031
2032
  if format_spec_additional is None:
2032
2033
  cur_res += element.apply(str)
2033
- elif issubclass(element.dtype, float) and re.fullmatch(r'\.\d+f', format_spec_additional):
2034
+ elif issubclass(element.dtype, (float, ott.decimal)) and re.fullmatch(r'\.\d+f', format_spec_additional):
2034
2035
  # float has strange behavior when precision=0
2035
2036
  decimal_elem = element.apply(ott.decimal)
2036
2037
  precision_str = re.findall(r'\d+', format_spec_additional)[0]
@@ -2047,7 +2048,7 @@ def _add_element(cur_res, element, format_spec_additional=None):
2047
2048
  else:
2048
2049
  if format_spec_additional is None:
2049
2050
  cur_res += str(element)
2050
- elif isinstance(element, float):
2051
+ elif isinstance(element, (float, ott.decimal)):
2051
2052
  formatting = f'{{:{format_spec_additional}}}'
2052
2053
  cur_res += formatting.format(element)
2053
2054
  else:
@@ -557,8 +557,10 @@ def run(query: Union[Callable, Dict, otp.Source, otp.MultiOutputSource, # NOSON
557
557
  kwargs['password'] = password
558
558
 
559
559
  max_expected_ticks_per_symbol = max_expected_ticks_per_symbol or otp.config.max_expected_ticks_per_symbol
560
- if has_max_expected_ticks_per_symbol(throw_warning=True):
560
+ if max_expected_ticks_per_symbol is not None and has_max_expected_ticks_per_symbol(throw_warning=True):
561
561
  kwargs['max_expected_ticks_per_symbol'] = max_expected_ticks_per_symbol
562
+ elif max_expected_ticks_per_symbol is None and has_max_expected_ticks_per_symbol(throw_warning=False):
563
+ kwargs['max_expected_ticks_per_symbol'] = 2000
562
564
 
563
565
  if encoding is not None and has_query_encoding_parameter(throw_warning=True):
564
566
  kwargs['encoding'] = encoding