ratio1 3.4.50__tar.gz → 3.4.52__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 (213) hide show
  1. {ratio1-3.4.50 → ratio1-3.4.52}/.devcontainer/devcontainer.json +2 -2
  2. {ratio1-3.4.50 → ratio1-3.4.52}/PKG-INFO +1 -1
  3. {ratio1-3.4.50 → ratio1-3.4.52}/pyproject.toml +1 -1
  4. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/_ver.py +1 -1
  5. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/bc/evm.py +237 -1
  6. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/base.py +1 -0
  7. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/evm_net.py +83 -33
  8. {ratio1-3.4.50 → ratio1-3.4.52}/.devcontainer/Dockerfile +0 -0
  9. {ratio1-3.4.50 → ratio1-3.4.52}/.gitattributes +0 -0
  10. {ratio1-3.4.50 → ratio1-3.4.52}/.github/workflows/python-publish.yml +0 -0
  11. {ratio1-3.4.50 → ratio1-3.4.52}/.gitignore +0 -0
  12. {ratio1-3.4.50 → ratio1-3.4.52}/.vscode/launch.json +0 -0
  13. {ratio1-3.4.50 → ratio1-3.4.52}/LICENSE +0 -0
  14. {ratio1-3.4.50 → ratio1-3.4.52}/README.md +0 -0
  15. {ratio1-3.4.50 → ratio1-3.4.52}/TODOs.md +0 -0
  16. {ratio1-3.4.50 → ratio1-3.4.52}/__init__.py +0 -0
  17. {ratio1-3.4.50 → ratio1-3.4.52}/r1ctl.MD +0 -0
  18. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/__init__.py +0 -0
  19. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/__init__.py +0 -0
  20. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/distributed_custom_code_presets.py +0 -0
  21. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/generic_session.py +0 -0
  22. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/instance.py +0 -0
  23. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/payload/__init__.py +0 -0
  24. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/payload/payload.py +0 -0
  25. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/pipeline.py +0 -0
  26. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/plugin_template.py +0 -0
  27. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/responses.py +0 -0
  28. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/transaction.py +0 -0
  29. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base/webapp_pipeline.py +0 -0
  30. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/base_decentra_object.py +0 -0
  31. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/bc/__init__.py +0 -0
  32. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/bc/base.py +0 -0
  33. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/bc/chain.py +0 -0
  34. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/bc/ec.py +0 -0
  35. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/certs/51.15.142.167.crt +0 -0
  36. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/certs/__init__.py +0 -0
  37. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/certs/a0d9818f.ala.eu-central-1.emqxsl.com.crt +0 -0
  38. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/certs/r9092118.ala.eu-central-1.emqxsl.com.crt +0 -0
  39. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/certs/s624dbd4.ala.us-east-1.emqxsl.com.crt +0 -0
  40. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/cli/README.md +0 -0
  41. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/cli/cli.py +0 -0
  42. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/cli/cli_commands.py +0 -0
  43. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/cli/nodes.py +0 -0
  44. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/cli/oracles.py +0 -0
  45. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/cli/package_update.py +0 -0
  46. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/code_cheker/__init__.py +0 -0
  47. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/code_cheker/base.py +0 -0
  48. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/code_cheker/checker.py +0 -0
  49. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/comm/__init__.py +0 -0
  50. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/comm/amqp_wrapper.py +0 -0
  51. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/comm/base_comm_wrapper.py +0 -0
  52. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/comm/mqtt_wrapper.py +0 -0
  53. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/README.md +0 -0
  54. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/__init__.py +0 -0
  55. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/apps.py +0 -0
  56. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/comms.py +0 -0
  57. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/environment.py +0 -0
  58. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/formatter.py +0 -0
  59. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/heartbeat.py +0 -0
  60. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/misc.py +0 -0
  61. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/payload.py +0 -0
  62. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/const/plugins/deeploy_const.py +0 -0
  63. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/default/__init__.py +0 -0
  64. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/default/instance/__init__.py +0 -0
  65. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/default/instance/chain_dist_custom_job_01_plugin.py +0 -0
  66. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/default/instance/custom_webapi_01_plugin.py +0 -0
  67. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/default/instance/generic_http_01_plugin.py +0 -0
  68. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/default/instance/net_mon_01_plugin.py +0 -0
  69. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/default/instance/telegram_basic_bot_01_plugin.py +0 -0
  70. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/default/instance/telegram_conversational_bot_01_plugin.py +0 -0
  71. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/default/instance/view_scene_01_plugin.py +0 -0
  72. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/default/session/mqtt_session.py +0 -0
  73. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/io_formatter/__init__.py +0 -0
  74. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/io_formatter/base/__init__.py +0 -0
  75. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/io_formatter/base/base_formatter.py +0 -0
  76. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/io_formatter/default/__init__.py +0 -0
  77. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/io_formatter/default/a_dummy.py +0 -0
  78. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/io_formatter/default/aixp1.py +0 -0
  79. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/io_formatter/default/default.py +0 -0
  80. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/io_formatter/io_formatter_manager.py +0 -0
  81. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/ipfs/__init__.py +0 -0
  82. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/ipfs/ifps_keygen +0 -0
  83. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/ipfs/ipfs_setup/ipfs.service +0 -0
  84. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/ipfs/ipfs_setup/launch_service.sh +0 -0
  85. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/ipfs/ipfs_setup/restart.sh +0 -0
  86. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/ipfs/ipfs_setup/run.sh +0 -0
  87. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/ipfs/ipfs_setup/setup.sh +0 -0
  88. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/ipfs/ipfs_setup/show.sh +0 -0
  89. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/ipfs/ipfs_setup/write_key.sh +0 -0
  90. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/ipfs/r1fs.py +0 -0
  91. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/__init__.py +0 -0
  92. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/base_logger.py +0 -0
  93. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/__init__.py +0 -0
  94. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/class_instance_mixin.py +0 -0
  95. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/computer_vision_mixin.py +0 -0
  96. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/datetime_mixin.py +0 -0
  97. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/download_mixin.py +0 -0
  98. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/general_serialization_mixin.py +0 -0
  99. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/json_serialization_mixin.py +0 -0
  100. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/machine_mixin.py +0 -0
  101. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/pickle_serialization_mixin.py +0 -0
  102. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/process_mixin.py +0 -0
  103. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/resource_size_mixin.py +0 -0
  104. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/timers_mixin.py +0 -0
  105. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/upload_mixin.py +0 -0
  106. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/logger_mixins/utils_mixin.py +0 -0
  107. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/small_logger.py +0 -0
  108. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/tzlocal/__init__.py +0 -0
  109. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/tzlocal/unix.py +0 -0
  110. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/tzlocal/utils.py +0 -0
  111. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/tzlocal/win32.py +0 -0
  112. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/logging/tzlocal/windows_tz.py +0 -0
  113. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/plugins_manager_mixin.py +0 -0
  114. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/utils/__init__.py +0 -0
  115. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/utils/comm_utils.py +0 -0
  116. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/utils/config.py +0 -0
  117. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/utils/dotenv.py +0 -0
  118. {ratio1-3.4.50 → ratio1-3.4.52}/ratio1/utils/oracle_sync/oracle_tester.py +0 -0
  119. {ratio1-3.4.50 → ratio1-3.4.52}/requirements.txt +0 -0
  120. {ratio1-3.4.50 → ratio1-3.4.52}/template.env +0 -0
  121. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/.example_env +0 -0
  122. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/8. custom_code_fastapi_assets/index.html +0 -0
  123. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/9. code_sandbox_from_scratch_assets/index.html +0 -0
  124. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/_example_pk_sdk.pem +0 -0
  125. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/eth2025/deploy_home_safety.py +0 -0
  126. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/eth2025/deploy_maintenance_monitoring.py +0 -0
  127. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex01_part1_connect.py +0 -0
  128. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex01_part2_filter.py +0 -0
  129. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex01_part3_adv_filter.py +0 -0
  130. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex02_part1_deploy_webapi.py +0 -0
  131. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex02_part2_deploy_plugin.py +0 -0
  132. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex02_part3_deploy_r1fs_test.py +0 -0
  133. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex03_custom_code_on_one_remote__example_1.py +0 -0
  134. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex04_custom_code_on_one_remote__example_2.py +0 -0
  135. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex05_custom_code_on_one_remote__example_3.py +0 -0
  136. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex06_custom_code_on_multiple_remotes__example_1.py +0 -0
  137. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex07_custom_code_on_multiple_remotes__example_2.py +0 -0
  138. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex08_custom_webapi.py +0 -0
  139. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex09_code_sandbox_from_scratch.py +0 -0
  140. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex10_telegram_echo_bot.py +0 -0
  141. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex11_telegram_blackjack_bot.py +0 -0
  142. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex12_telegram_smart_bot.py +0 -0
  143. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex13_launch_repo_based_webapp.py +0 -0
  144. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex14_wallets.py +0 -0
  145. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex15_telegram_rogue_style_game.py +0 -0
  146. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex16_launch_repo_based_http_server.py +0 -0
  147. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex17_launch_repo_based_balanced_webapp.py +0 -0
  148. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex18_deploy_container_webapi.py +0 -0
  149. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex19_deeploy_container_example.py +0 -0
  150. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex20_deeploy_telegram_bot.py +0 -0
  151. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex21_telegram_community_bot.py +0 -0
  152. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/ex22_deeploy_custom_code.py +0 -0
  153. {ratio1-3.4.50 → ratio1-3.4.52}/tutorials/video_presentation/1. hello_world.ipynb +0 -0
  154. {ratio1-3.4.50 → ratio1-3.4.52}/winrun.bat +0 -0
  155. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/README.md +0 -0
  156. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/_show_config_check.py +0 -0
  157. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/cstore_check.py +0 -0
  158. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/dauth_check.py +0 -0
  159. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/keys_check.py +0 -0
  160. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/node_info_check.py +0 -0
  161. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/ora_check.py +0 -0
  162. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/ora_intervals.py +0 -0
  163. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/ora_sign_check.py +0 -0
  164. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/owner_check.py +0 -0
  165. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/payload_check.py +0 -0
  166. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/session_check.py +0 -0
  167. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/w3_auth_check.py +0 -0
  168. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/w3_nodes_licenses.py +0 -0
  169. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/w3_oracles_check.py +0 -0
  170. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/w3_poai_check.py +0 -0
  171. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/whitelist_check.py +0 -0
  172. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/_checks/workload_check.py +0 -0
  173. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/dates/check_date.py +0 -0
  174. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/debug/close_pipeline.py +0 -0
  175. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/decentralized/chain_dist_example.py +0 -0
  176. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/decentralized/chain_dist_example_initiator.py +0 -0
  177. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/decentralized/chain_dist_example_worker.py +0 -0
  178. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/deeploy/checker.py +0 -0
  179. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/deeploy/checker2.py +0 -0
  180. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/deeploy/create_request.py +0 -0
  181. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/enc_dec/enc_dec_test.py +0 -0
  182. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/eth/balance.py +0 -0
  183. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/eth/eth_sign.py +0 -0
  184. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/eth/info.md +0 -0
  185. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/eth/send.py +0 -0
  186. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/eth/send_many.py +0 -0
  187. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/eth/sign.py +0 -0
  188. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/log.py +0 -0
  189. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/logger/run.py +0 -0
  190. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/lp/lp_checker.py +0 -0
  191. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/multi-enc-dec/multi_test1.py +0 -0
  192. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/multi-enc-dec/multi_test2.py +0 -0
  193. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/pipelines/start.py +0 -0
  194. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/pipelines/stop.py +0 -0
  195. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/scripts/monitoring/collect_messages.py +0 -0
  196. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/scripts/monitoring/get_hb_distribution.py +0 -0
  197. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/scripts/monitoring/multithreaded_network_sniffer.py +0 -0
  198. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/sign/simple_payload_checker.py +0 -0
  199. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/sign/test_sign1.py +0 -0
  200. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/sign/test_sign2.py +0 -0
  201. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/test.py +0 -0
  202. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/tokens/get_check.py +0 -0
  203. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/utils/get_documentation.py +0 -0
  204. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/various/attach_example.py +0 -0
  205. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/various/ex1.py +0 -0
  206. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/various/hello.py +0 -0
  207. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/various/remote_exec.py +0 -0
  208. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/various/save_images.py +0 -0
  209. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/wl/wl_add.py +0 -0
  210. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/xarchive/_tutorials/3. simple_real_time_custom_code.py +0 -0
  211. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/xarchive/_tutorials/4. real_time_custom_code_2.py +0 -0
  212. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/xarchive/_tutorials/8. chatbot.py +0 -0
  213. {ratio1-3.4.50 → ratio1-3.4.52}/xperimental/xarchive/test.py +0 -0
@@ -5,10 +5,10 @@
5
5
  "runArgs": [
6
6
  //"--gpus=all",
7
7
  "--hostname",
8
- "sdk_dev",
8
+ "r1sdk_dev",
9
9
 
10
10
  "--name",
11
- "r1_sdk_devenv"
11
+ "r1r1_sdk"
12
12
  ],
13
13
 
14
14
  "customizations": {
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ratio1
3
- Version: 3.4.50
3
+ Version: 3.4.52
4
4
  Summary: `ratio1` or Ration1 SDK is the Python SDK required for client app development for the Ratio1 ecosystem
5
5
  Project-URL: Homepage, https://github.com/Ratio1/ratio1_sdk
6
6
  Project-URL: Bug Tracker, https://github.com/Ratio1/ratio1_sdk/issues
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "ratio1"
7
- version = "3.4.50"
7
+ version = "3.4.52"
8
8
  authors = [
9
9
  { name="Andrei Ionut Damian", email="andrei.damian@ratio1.ai" },
10
10
  { name="Cristan Bleotiu", email="cristian.bleotiu@ratio1.ai" },
@@ -1,4 +1,4 @@
1
- __VER__ = "3.4.50"
1
+ __VER__ = "3.4.52"
2
2
 
3
3
  if __name__ == "__main__":
4
4
  with open("pyproject.toml", "rt") as fd:
@@ -1327,7 +1327,7 @@ class _EVMMixin:
1327
1327
  network = w3vars.network
1328
1328
  contract = w3vars.w3.eth.contract(
1329
1329
  address=w3vars.poai_manager_address,
1330
- abi=EVM_ABI_DATA.GET_JOB_DETAILS
1330
+ abi=EVM_ABI_DATA.POAI_MANAGER_ABI
1331
1331
  )
1332
1332
 
1333
1333
  self.P(f"`getJobDetails` on {network} via {w3vars.rpc_url}", verbosity=2)
@@ -1356,6 +1356,242 @@ class _EVMMixin:
1356
1356
 
1357
1357
  return details
1358
1358
 
1359
+ def web3_submit_node_update(
1360
+ self,
1361
+ job_id: int,
1362
+ nodes: list,
1363
+ wait_for_tx: bool = False,
1364
+ timeout: int = 120,
1365
+ network: str = None,
1366
+ return_receipt=False,
1367
+ ):
1368
+ """
1369
+ Submit nodes update for a given job.
1370
+
1371
+ Parameters
1372
+ ----------
1373
+ job_id : int
1374
+ The job ID to update.
1375
+
1376
+ nodes : list
1377
+ The list of new nodes running the job.
1378
+
1379
+ network : str, optional
1380
+ The network to use. If None, uses the default self.evm_network.
1381
+
1382
+ Returns
1383
+ -------
1384
+ The transaction hash.
1385
+ """
1386
+ # Validate the input parameters.
1387
+ assert isinstance(job_id, int), "Invalid job ID"
1388
+ assert isinstance(nodes, list), "Nodes must be a list"
1389
+
1390
+ # Retrieve the Web3 instance, RPC URL, and the R1 contract address.
1391
+ # Note: This follows the same pattern as web3_get_balance_r1.
1392
+ w3vars = self._get_web3_vars(network)
1393
+ network = w3vars.network
1394
+
1395
+ # Create the token contract instance.
1396
+ poai_manager_contract = w3vars.w3.eth.contract(
1397
+ address=w3vars.poai_manager_address, abi=EVM_ABI_DATA.POAI_MANAGER_ABI
1398
+ )
1399
+
1400
+ # Estimate gas fees for the token transfer.
1401
+ gas_price = w3vars.w3.eth.gas_price # This fetches the current suggested gas price from the network.
1402
+ estimated_gas = poai_manager_contract.functions.submitNodeUpdate(job_id, nodes).estimate_gas(
1403
+ {'from': self.eth_address}
1404
+ )
1405
+ gas_cost = estimated_gas * gas_price
1406
+
1407
+ # Check that the sender's ETH balance can cover gas costs plus an extra buffer.
1408
+ eth_balance = w3vars.w3.eth.get_balance(self.eth_address)
1409
+ if eth_balance < gas_cost:
1410
+ raise Exception("Insufficient ETH balance to cover gas fees.")
1411
+
1412
+ # Get the transaction count for the nonce.
1413
+ nonce = w3vars.w3.eth.get_transaction_count(self.eth_address)
1414
+
1415
+ # Programmatically determine the chainId.
1416
+ chain_id = w3vars.w3.eth.chain_id
1417
+
1418
+ # Build the transaction for the ERC20 transfer.
1419
+ tx = poai_manager_contract.functions.submitNodeUpdate(job_id, nodes).build_transaction({
1420
+ 'from': self.eth_address,
1421
+ 'nonce': nonce,
1422
+ 'gas': estimated_gas,
1423
+ 'gasPrice': gas_price,
1424
+ 'chainId': chain_id,
1425
+ })
1426
+
1427
+ self.P(f"Executing transaction on {network} via {w3vars.rpc_url}:\n {json.dumps(dict(tx), indent=2)}", verbosity=2)
1428
+
1429
+ # Sign the transaction using the internal account (via _get_eth_account).
1430
+ eth_account = self._get_eth_account()
1431
+ signed_tx = w3vars.w3.eth.account.sign_transaction(tx, eth_account.key)
1432
+
1433
+ # Broadcast the transaction.
1434
+ tx_hash = w3vars.w3.eth.send_raw_transaction(signed_tx.raw_transaction)
1435
+
1436
+ if wait_for_tx:
1437
+ # Wait for the transaction receipt if required.
1438
+ tx_receipt = w3vars.w3.eth.wait_for_transaction_receipt(tx_hash, timeout=timeout)
1439
+ tx_hash_hex = tx_receipt.transactionHash.hex()
1440
+ self.P(f"Transaction mined: {tx_hash_hex}", color='g', verbosity=2)
1441
+ if return_receipt:
1442
+ return tx_receipt
1443
+ else:
1444
+ return tx_hash_hex
1445
+ else:
1446
+ return tx_hash.hex()
1447
+
1448
+ def web3_allocate_rewards_across_all_escrows(
1449
+ self,
1450
+ network: str = None,
1451
+ wait_for_tx=True,
1452
+ timeout=120,
1453
+ return_receipt=False,
1454
+ ):
1455
+ """
1456
+ Allocate rewards across all escrows.
1457
+
1458
+ Parameters
1459
+ ----------
1460
+ network : str, optional
1461
+ The network to use. If None, uses the default self.evm_network.
1462
+
1463
+ Returns
1464
+ -------
1465
+ The transaction hash.
1466
+ """
1467
+ # Retrieve the Web3 instance, RPC URL, and the R1 contract address.
1468
+ # Note: This follows the same pattern as web3_get_balance_r1.
1469
+ w3vars = self._get_web3_vars(network)
1470
+ network = w3vars.network
1471
+
1472
+ # Create the token contract instance.
1473
+ poai_manager_contract = w3vars.w3.eth.contract(
1474
+ address=w3vars.poai_manager_address, abi=EVM_ABI_DATA.POAI_MANAGER_ABI
1475
+ )
1476
+
1477
+ # Estimate gas fees for the token transfer.
1478
+ gas_price = w3vars.w3.eth.gas_price # This fetches the current suggested gas price from the network.
1479
+ estimated_gas = poai_manager_contract.functions.allocateRewardsAcrossAllEscrows().estimate_gas(
1480
+ {'from': self.eth_address}
1481
+ )
1482
+ gas_cost = estimated_gas * gas_price
1483
+
1484
+ # Check that the sender's ETH balance can cover gas costs plus an extra buffer.
1485
+ eth_balance = w3vars.w3.eth.get_balance(self.eth_address)
1486
+ if eth_balance < gas_cost:
1487
+ raise Exception("Insufficient ETH balance to cover gas fees.")
1488
+
1489
+ # Get the transaction count for the nonce.
1490
+ nonce = w3vars.w3.eth.get_transaction_count(self.eth_address)
1491
+
1492
+ # Programmatically determine the chainId.
1493
+ chain_id = w3vars.w3.eth.chain_id
1494
+
1495
+ # Build the transaction for the ERC20 transfer.
1496
+ tx = poai_manager_contract.functions.allocateRewardsAcrossAllEscrows().build_transaction({
1497
+ 'from': self.eth_address,
1498
+ 'nonce': nonce,
1499
+ 'gas': estimated_gas,
1500
+ 'gasPrice': gas_price,
1501
+ 'chainId': chain_id,
1502
+ })
1503
+
1504
+ self.P(f"Executing transaction on {network} via {w3vars.rpc_url}:\n {json.dumps(dict(tx), indent=2)}", verbosity=2)
1505
+
1506
+ # Sign the transaction using the internal account (via _get_eth_account).
1507
+ eth_account = self._get_eth_account()
1508
+ signed_tx = w3vars.w3.eth.account.sign_transaction(tx, eth_account.key)
1509
+
1510
+ # Broadcast the transaction.
1511
+ tx_hash = w3vars.w3.eth.send_raw_transaction(signed_tx.raw_transaction)
1512
+
1513
+ if wait_for_tx:
1514
+ # Wait for the transaction receipt if required.
1515
+ tx_receipt = w3vars.w3.eth.wait_for_transaction_receipt(tx_hash, timeout=timeout)
1516
+ tx_hash_hex = tx_receipt.transactionHash.hex()
1517
+ self.P(f"Transaction mined: {tx_hash_hex}", color='g', verbosity=2)
1518
+ if return_receipt:
1519
+ return tx_receipt
1520
+ else:
1521
+ return tx_hash_hex
1522
+ else:
1523
+ return tx_hash.hex()
1524
+
1525
+ def web3_get_unvalidated_job_ids(
1526
+ self,
1527
+ network: str = None
1528
+ ):
1529
+ """
1530
+ Retrieve unvalidated job IDs using getUnvalidatedJobIds().
1531
+
1532
+ Parameters
1533
+ ----------
1534
+ network : str, optional
1535
+ The network to use. If None, defaults to self.evm_network.
1536
+
1537
+ Returns
1538
+ -------
1539
+ list
1540
+ A list of unvalidated job IDs.
1541
+ """
1542
+ # Retrieve the necessary Web3 variables (pattern consistent with web3_get_job_details).
1543
+ w3vars = self._get_web3_vars(network)
1544
+ network = w3vars.network
1545
+
1546
+ contract = w3vars.w3.eth.contract(
1547
+ address=w3vars.poai_manager_address,
1548
+ abi=EVM_ABI_DATA.POAI_MANAGER_ABI
1549
+ )
1550
+
1551
+ self.P(f"`getUnvalidatedJobIds` on {network} via {w3vars.rpc_url}", verbosity=2)
1552
+
1553
+ # Call the contract function to get unvalidated job IDs.
1554
+ result = contract.functions.getUnvalidatedJobIds().call()
1555
+
1556
+ self.P(f"Unvalidated Job IDs: {result}", verbosity=2)
1557
+
1558
+ return result
1559
+
1560
+ def web3_get_is_last_epoch_allocated(
1561
+ self,
1562
+ network: str = None
1563
+ ):
1564
+ """
1565
+ Check if the last epoch has been allocated using getIsLastEpochAllocated().
1566
+
1567
+ Parameters
1568
+ ----------
1569
+ network : str, optional
1570
+ The network to use. If None, defaults to self.evm_network.
1571
+
1572
+ Returns
1573
+ -------
1574
+ bool
1575
+ True if the last epoch has been allocated, False otherwise.
1576
+ """
1577
+ # Retrieve the necessary Web3 variables (pattern consistent with web3_get_unvalidated_job_ids).
1578
+ w3vars = self._get_web3_vars(network)
1579
+ network = w3vars.network
1580
+
1581
+ contract = w3vars.w3.eth.contract(
1582
+ address=w3vars.poai_manager_address,
1583
+ abi=EVM_ABI_DATA.POAI_MANAGER_ABI
1584
+ )
1585
+
1586
+ self.P(f"`getIsLastEpochAllocated` on {network} via {w3vars.rpc_url}", verbosity=2)
1587
+
1588
+ # Call the contract function to check if last epoch is allocated.
1589
+ result = contract.functions.getIsLastEpochAllocated().call()
1590
+
1591
+ self.P(f"Last epoch allocated: {result}", verbosity=2)
1592
+
1593
+ return result
1594
+
1359
1595
  def get_deeploy_url(self):
1360
1596
  """
1361
1597
  Returns the deeploy URL from the environment or the network data
@@ -173,6 +173,7 @@ class CONFIG_STREAM:
173
173
  LAST_UPDATE_TIME = 'LAST_UPDATE_TIME'
174
174
 
175
175
  IS_DEEPLOYED = 'IS_DEEPLOYED'
176
+ DEEPLOY_SPECS = 'DEEPLOY_SPECS'
176
177
 
177
178
  URL = K_URL
178
179
  TYPE = K_TYPE
@@ -220,7 +220,41 @@ _GET_ADDRESSES_BALANCES = [
220
220
  }
221
221
  ]
222
222
 
223
- _GET_JOB_DETAILS_ABI = [
223
+ # A minimal ERC20 ABI for balanceOf, transfer, and decimals functions.
224
+ _ERC20_ABI = [
225
+ {
226
+ "constant": True,
227
+ "inputs": [{"name": "_owner", "type": "address"}],
228
+ "name": "balanceOf",
229
+ "outputs": [{"name": "balance", "type": "uint256"}],
230
+ "payable": False,
231
+ "stateMutability": "view",
232
+ "type": "function"
233
+ },
234
+ {
235
+ "constant": False,
236
+ "inputs": [
237
+ {"name": "_to", "type": "address"},
238
+ {"name": "_value", "type": "uint256"}
239
+ ],
240
+ "name": "transfer",
241
+ "outputs": [{"name": "success", "type": "bool"}],
242
+ "payable": False,
243
+ "stateMutability": "nonpayable",
244
+ "type": "function"
245
+ },
246
+ {
247
+ "constant": True,
248
+ "inputs": [],
249
+ "name": "decimals",
250
+ "outputs": [{"name": "", "type": "uint8"}],
251
+ "payable": False,
252
+ "stateMutability": "view",
253
+ "type": "function"
254
+ }
255
+ ]
256
+
257
+ _POAI_MANAGER_ABI = [
224
258
  {
225
259
  "inputs": [
226
260
  {
@@ -306,44 +340,60 @@ _GET_JOB_DETAILS_ABI = [
306
340
  ],
307
341
  "stateMutability": "view",
308
342
  "type": "function"
309
- }
310
- ]
311
-
312
- # A minimal ERC20 ABI for balanceOf, transfer, and decimals functions.
313
- _ERC20_ABI = [
343
+ },
314
344
  {
315
- "constant": True,
316
- "inputs": [{"name": "_owner", "type": "address"}],
317
- "name": "balanceOf",
318
- "outputs": [{"name": "balance", "type": "uint256"}],
319
- "payable": False,
320
- "stateMutability": "view",
321
- "type": "function"
345
+ "inputs": [
346
+ {
347
+ "internalType": "uint256",
348
+ "name": "jobId",
349
+ "type": "uint256"
350
+ },
351
+ {
352
+ "internalType": "address[]",
353
+ "name": "newActiveNodes",
354
+ "type": "address[]"
355
+ }
356
+ ],
357
+ "name": "submitNodeUpdate",
358
+ "outputs": [],
359
+ "stateMutability": "nonpayable",
360
+ "type": "function"
322
361
  },
323
362
  {
324
- "constant": False,
325
- "inputs": [
326
- {"name": "_to", "type": "address"},
327
- {"name": "_value", "type": "uint256"}
328
- ],
329
- "name": "transfer",
330
- "outputs": [{"name": "success", "type": "bool"}],
331
- "payable": False,
332
- "stateMutability": "nonpayable",
333
- "type": "function"
363
+ "inputs": [],
364
+ "name": "allocateRewardsAcrossAllEscrows",
365
+ "outputs": [],
366
+ "stateMutability": "nonpayable",
367
+ "type": "function"
334
368
  },
335
369
  {
336
- "constant": True,
337
- "inputs": [],
338
- "name": "decimals",
339
- "outputs": [{"name": "", "type": "uint8"}],
340
- "payable": False,
341
- "stateMutability": "view",
342
- "type": "function"
370
+ "inputs": [],
371
+ "name": "getUnvalidatedJobIds",
372
+ "outputs": [
373
+ {
374
+ "internalType": "uint256[]",
375
+ "name": "",
376
+ "type": "uint256[]"
377
+ }
378
+ ],
379
+ "stateMutability": "view",
380
+ "type": "function"
381
+ },
382
+ {
383
+ "inputs": [],
384
+ "name": "getIsLastEpochAllocated",
385
+ "outputs": [
386
+ {
387
+ "internalType": "bool",
388
+ "name": "",
389
+ "type": "bool"
390
+ }
391
+ ],
392
+ "stateMutability": "view",
393
+ "type": "function"
343
394
  }
344
395
  ]
345
396
 
346
-
347
397
  # Here are all the constants used for blockchain interaction for each network.
348
398
  EVM_NET_DATA = {
349
399
  EvmNetData.MAINNET: {
@@ -390,7 +440,7 @@ EVM_NET_DATA = {
390
440
  EvmNetData.DAUTH_R1_ADDR_KEY : "0x277CbD0Cf25F4789Bc04035eCd03d811FAf73691",
391
441
  EvmNetData.DAUTH_MND_ADDR_KEY : "0x17B8934dc5833CdBa1eF42D13D65D677C4727748",
392
442
  EvmNetData.DAUTH_PROXYAPI_ADDR_KEY : "0xFcF04c9A67330431Af75a546615E4881BD8bdC78",
393
- EvmNetData.DAUTH_POAI_MANAGER_KEY : "0x9A41f43494fCD592577228fE8E4014f2D75d2aa3",
443
+ EvmNetData.DAUTH_POAI_MANAGER_KEY : "0xCc7C4e0f4f25b57807F34227Fb446E68c8c36ce5",
394
444
  EvmNetData.DAUTH_RPC_KEY : "https://base-sepolia.public.blastapi.io",
395
445
  EvmNetData.EE_GENESIS_EPOCH_DATE_KEY : "2025-06-30 07:00:00",
396
446
  EvmNetData.EE_EPOCH_INTERVALS_KEY : 1,
@@ -439,6 +489,6 @@ class EVM_ABI_DATA:
439
489
  GET_WALLET_NODES = _GET_WALLET_NODES
440
490
  GET_ADDRESSES_BALANCES = _GET_ADDRESSES_BALANCES
441
491
  IS_NODE_ACTIVE = _DAUTH_ABI_IS_NODE_ACTIVE
442
- GET_JOB_DETAILS = _GET_JOB_DETAILS_ABI
443
492
  ERC20_ABI = _ERC20_ABI
493
+ POAI_MANAGER_ABI = _POAI_MANAGER_ABI
444
494
 
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