web3 7.13.0__tar.gz → 7.14.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 (359) hide show
  1. {web3-7.13.0/web3.egg-info → web3-7.14.0}/PKG-INFO +1 -1
  2. {web3-7.13.0 → web3-7.14.0}/ens/async_ens.py +9 -5
  3. {web3-7.13.0 → web3-7.14.0}/ens/base_ens.py +1 -1
  4. {web3-7.13.0 → web3-7.14.0}/ens/utils.py +2 -1
  5. {web3-7.13.0 → web3-7.14.0}/pyproject.toml +2 -2
  6. {web3-7.13.0 → web3-7.14.0}/setup.py +1 -1
  7. {web3-7.13.0 → web3-7.14.0}/tests/core/caching-utils/test_generate_cache_key.py +5 -0
  8. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_call_interface.py +5 -5
  9. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_abi.py +3 -3
  10. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_encoding.py +5 -2
  11. {web3-7.13.0 → web3-7.14.0}/tests/core/web3-module/test_conversions.py +1 -1
  12. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/conftest.py +8 -6
  13. {web3-7.13.0 → web3-7.14.0}/web3/_utils/abi.py +5 -5
  14. {web3-7.13.0 → web3-7.14.0}/web3/_utils/async_transactions.py +12 -9
  15. {web3-7.13.0 → web3-7.14.0}/web3/_utils/batching.py +1 -1
  16. {web3-7.13.0 → web3-7.14.0}/web3/_utils/caching/caching_utils.py +2 -2
  17. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contracts.py +5 -5
  18. {web3-7.13.0 → web3-7.14.0}/web3/_utils/ens.py +1 -1
  19. {web3-7.13.0 → web3-7.14.0}/web3/_utils/events.py +1 -1
  20. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module_testing/eth_module.py +133 -125
  21. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module_testing/go_ethereum_admin_module.py +7 -6
  22. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module_testing/go_ethereum_debug_module.py +5 -4
  23. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module_testing/go_ethereum_txpool_module.py +6 -3
  24. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module_testing/module_testing_utils.py +1 -1
  25. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module_testing/net_module.py +4 -3
  26. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module_testing/persistent_connection_provider.py +132 -20
  27. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module_testing/utils.py +7 -6
  28. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module_testing/web3_module.py +15 -11
  29. {web3-7.13.0 → web3-7.14.0}/web3/_utils/normalizers.py +3 -3
  30. {web3-7.13.0 → web3-7.14.0}/web3/_utils/transactions.py +2 -1
  31. {web3-7.13.0 → web3-7.14.0}/web3/contract/async_contract.py +13 -13
  32. {web3-7.13.0 → web3-7.14.0}/web3/contract/base_contract.py +11 -12
  33. {web3-7.13.0 → web3-7.14.0}/web3/contract/utils.py +7 -7
  34. {web3-7.13.0 → web3-7.14.0}/web3/eth/async_eth.py +1 -1
  35. {web3-7.13.0 → web3-7.14.0}/web3/gas_strategies/time_based.py +1 -1
  36. {web3-7.13.0 → web3-7.14.0}/web3/main.py +24 -11
  37. {web3-7.13.0 → web3-7.14.0}/web3/manager.py +9 -8
  38. {web3-7.13.0 → web3-7.14.0}/web3/middleware/__init__.py +1 -1
  39. {web3-7.13.0 → web3-7.14.0}/web3/middleware/base.py +5 -5
  40. {web3-7.13.0 → web3-7.14.0}/web3/middleware/buffered_gas_estimate.py +1 -1
  41. {web3-7.13.0 → web3-7.14.0}/web3/middleware/filter.py +10 -9
  42. {web3-7.13.0 → web3-7.14.0}/web3/middleware/formatting.py +4 -4
  43. {web3-7.13.0 → web3-7.14.0}/web3/middleware/gas_price_strategy.py +1 -1
  44. {web3-7.13.0 → web3-7.14.0}/web3/middleware/names.py +4 -4
  45. {web3-7.13.0 → web3-7.14.0}/web3/middleware/signing.py +3 -3
  46. {web3-7.13.0 → web3-7.14.0}/web3/middleware/stalecheck.py +2 -2
  47. {web3-7.13.0 → web3-7.14.0}/web3/middleware/validation.py +2 -2
  48. {web3-7.13.0 → web3-7.14.0}/web3/module.py +3 -3
  49. {web3-7.13.0 → web3-7.14.0}/web3/providers/async_base.py +2 -2
  50. {web3-7.13.0 → web3-7.14.0}/web3/providers/base.py +2 -2
  51. {web3-7.13.0 → web3-7.14.0}/web3/providers/eth_tester/defaults.py +2 -2
  52. {web3-7.13.0 → web3-7.14.0}/web3/providers/eth_tester/main.py +1 -1
  53. {web3-7.13.0 → web3-7.14.0}/web3/providers/eth_tester/middleware.py +2 -2
  54. {web3-7.13.0 → web3-7.14.0}/web3/providers/persistent/persistent.py +4 -4
  55. {web3-7.13.0 → web3-7.14.0}/web3/providers/persistent/persistent_connection.py +1 -1
  56. {web3-7.13.0 → web3-7.14.0}/web3/providers/persistent/subscription_manager.py +1 -1
  57. {web3-7.13.0 → web3-7.14.0}/web3/providers/persistent/utils.py +1 -1
  58. {web3-7.13.0 → web3-7.14.0}/web3/types.py +16 -3
  59. {web3-7.13.0 → web3-7.14.0}/web3/utils/subscriptions.py +3 -2
  60. {web3-7.13.0 → web3-7.14.0/web3.egg-info}/PKG-INFO +1 -1
  61. {web3-7.13.0 → web3-7.14.0}/LICENSE +0 -0
  62. {web3-7.13.0 → web3-7.14.0}/MANIFEST.in +0 -0
  63. {web3-7.13.0 → web3-7.14.0}/README.md +0 -0
  64. {web3-7.13.0 → web3-7.14.0}/ens/__init__.py +0 -0
  65. {web3-7.13.0 → web3-7.14.0}/ens/_normalization.py +0 -0
  66. {web3-7.13.0 → web3-7.14.0}/ens/abis.py +0 -0
  67. {web3-7.13.0 → web3-7.14.0}/ens/auto.py +0 -0
  68. {web3-7.13.0 → web3-7.14.0}/ens/constants.py +0 -0
  69. {web3-7.13.0 → web3-7.14.0}/ens/contract_data.py +0 -0
  70. {web3-7.13.0 → web3-7.14.0}/ens/ens.py +0 -0
  71. {web3-7.13.0 → web3-7.14.0}/ens/exceptions.py +0 -0
  72. {web3-7.13.0 → web3-7.14.0}/ens/specs/nf.json +0 -0
  73. {web3-7.13.0 → web3-7.14.0}/ens/specs/normalization_spec.json +0 -0
  74. {web3-7.13.0 → web3-7.14.0}/scripts/release/test_package.py +0 -0
  75. {web3-7.13.0 → web3-7.14.0}/setup.cfg +0 -0
  76. {web3-7.13.0 → web3-7.14.0}/tests/__init__.py +0 -0
  77. {web3-7.13.0 → web3-7.14.0}/tests/beacon/test_async_beacon.py +0 -0
  78. {web3-7.13.0 → web3-7.14.0}/tests/beacon/test_beacon.py +0 -0
  79. {web3-7.13.0 → web3-7.14.0}/tests/conftest.py +0 -0
  80. {web3-7.13.0 → web3-7.14.0}/tests/core/admin-module/test_admin_addPeer.py +0 -0
  81. {web3-7.13.0 → web3-7.14.0}/tests/core/admin-module/test_admin_nodeInfo.py +0 -0
  82. {web3-7.13.0 → web3-7.14.0}/tests/core/admin-module/test_admin_peers.py +0 -0
  83. {web3-7.13.0 → web3-7.14.0}/tests/core/block-utils/test_select_method_for_block_identifier.py +0 -0
  84. {web3-7.13.0 → web3-7.14.0}/tests/core/caching-utils/test_request_caching.py +0 -0
  85. {web3-7.13.0 → web3-7.14.0}/tests/core/conftest.py +0 -0
  86. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/conftest.py +0 -0
  87. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_ambiguous_events.py +0 -0
  88. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_ambiguous_functions.py +0 -0
  89. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_attributes.py +0 -0
  90. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_build_transaction.py +0 -0
  91. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_caller_interface.py +0 -0
  92. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_class_construction.py +0 -0
  93. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_constructor.py +0 -0
  94. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_constructor_encoding.py +0 -0
  95. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_deployment.py +0 -0
  96. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_estimate_gas.py +0 -0
  97. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_events.py +0 -0
  98. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_events_build_filter.py +0 -0
  99. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_example.py +0 -0
  100. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_init.py +0 -0
  101. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_method_abi_decoding.py +0 -0
  102. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_method_abi_encoding.py +0 -0
  103. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_method_to_argument_matching.py +0 -0
  104. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_panic_errors.py +0 -0
  105. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_transact_interface.py +0 -0
  106. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_contract_util_functions.py +0 -0
  107. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_extracting_event_data.py +0 -0
  108. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_extracting_event_data_old.py +0 -0
  109. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/test_offchain_lookup.py +0 -0
  110. {web3-7.13.0 → web3-7.14.0}/tests/core/contracts/utils.py +0 -0
  111. {web3-7.13.0 → web3-7.14.0}/tests/core/datastructures/test_datastructures.py +0 -0
  112. {web3-7.13.0 → web3-7.14.0}/tests/core/empty-object/test_empty_object_is_falsy.py +0 -0
  113. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/conftest.py +0 -0
  114. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/test_accounts.py +0 -0
  115. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/test_block_api.py +0 -0
  116. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/test_default_account_api.py +0 -0
  117. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/test_eth_contract.py +0 -0
  118. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/test_eth_fee_history.py +0 -0
  119. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/test_eth_filter.py +0 -0
  120. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/test_eth_properties.py +0 -0
  121. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/test_gas_pricing.py +0 -0
  122. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/test_poa.py +0 -0
  123. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-module/test_transactions.py +0 -0
  124. {web3-7.13.0 → web3-7.14.0}/tests/core/eth-tester-api/test_withdrawals.py +0 -0
  125. {web3-7.13.0 → web3-7.14.0}/tests/core/exceptions/test_exceptions.py +0 -0
  126. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/conftest.py +0 -0
  127. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_basic_filter_tests.py +0 -0
  128. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_contract_create_filter_topic_merging.py +0 -0
  129. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_contract_data_filters.py +0 -0
  130. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_contract_get_logs.py +0 -0
  131. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_contract_on_event_filtering.py +0 -0
  132. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_contract_past_event_filtering.py +0 -0
  133. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_contract_topic_filters.py +0 -0
  134. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_existing_filter_instance.py +0 -0
  135. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_filter_against_latest_blocks.py +0 -0
  136. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_filter_against_pending_transactions.py +0 -0
  137. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_filter_against_transaction_logs.py +0 -0
  138. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_filters_against_many_blocks.py +0 -0
  139. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/test_utils_functions.py +0 -0
  140. {web3-7.13.0 → web3-7.14.0}/tests/core/filtering/utils.py +0 -0
  141. {web3-7.13.0 → web3-7.14.0}/tests/core/gas-strategies/test_rpc_gas_pricing_strategies.py +0 -0
  142. {web3-7.13.0 → web3-7.14.0}/tests/core/gas-strategies/test_time_based_gas_price_strategy.py +0 -0
  143. {web3-7.13.0 → web3-7.14.0}/tests/core/manager/conftest.py +0 -0
  144. {web3-7.13.0 → web3-7.14.0}/tests/core/manager/test_default_middlewares.py +0 -0
  145. {web3-7.13.0 → web3-7.14.0}/tests/core/manager/test_middleware_can_be_stateful.py +0 -0
  146. {web3-7.13.0 → web3-7.14.0}/tests/core/manager/test_middleware_onion_api.py +0 -0
  147. {web3-7.13.0 → web3-7.14.0}/tests/core/manager/test_provider_property.py +0 -0
  148. {web3-7.13.0 → web3-7.14.0}/tests/core/manager/test_provider_request_wrapping.py +0 -0
  149. {web3-7.13.0 → web3-7.14.0}/tests/core/manager/test_response_formatters.py +0 -0
  150. {web3-7.13.0 → web3-7.14.0}/tests/core/method-class/test_method.py +0 -0
  151. {web3-7.13.0 → web3-7.14.0}/tests/core/method-class/test_result_formatters.py +0 -0
  152. {web3-7.13.0 → web3-7.14.0}/tests/core/middleware/test_attrdict_middleware.py +0 -0
  153. {web3-7.13.0 → web3-7.14.0}/tests/core/middleware/test_eth_tester_middleware.py +0 -0
  154. {web3-7.13.0 → web3-7.14.0}/tests/core/middleware/test_filter_middleware.py +0 -0
  155. {web3-7.13.0 → web3-7.14.0}/tests/core/middleware/test_formatting_middleware.py +0 -0
  156. {web3-7.13.0 → web3-7.14.0}/tests/core/middleware/test_gas_price_strategy.py +0 -0
  157. {web3-7.13.0 → web3-7.14.0}/tests/core/middleware/test_middleware.py +0 -0
  158. {web3-7.13.0 → web3-7.14.0}/tests/core/middleware/test_name_to_address_middleware.py +0 -0
  159. {web3-7.13.0 → web3-7.14.0}/tests/core/middleware/test_stalecheck.py +0 -0
  160. {web3-7.13.0 → web3-7.14.0}/tests/core/middleware/test_transaction_signing.py +0 -0
  161. {web3-7.13.0 → web3-7.14.0}/tests/core/module-class/test_module.py +0 -0
  162. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_async_http_provider.py +0 -0
  163. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_async_ipc_provider.py +0 -0
  164. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_async_tester_provider.py +0 -0
  165. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_auto_provider.py +0 -0
  166. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_base_provider.py +0 -0
  167. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_http_provider.py +0 -0
  168. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_http_request_retry.py +0 -0
  169. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_ipc_provider.py +0 -0
  170. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_legacy_websocket_provider.py +0 -0
  171. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_provider_init.py +0 -0
  172. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_tester_provider.py +0 -0
  173. {web3-7.13.0 → web3-7.14.0}/tests/core/providers/test_websocket_provider.py +0 -0
  174. {web3-7.13.0 → web3-7.14.0}/tests/core/subscriptions/test_subscription_manager.py +0 -0
  175. {web3-7.13.0 → web3-7.14.0}/tests/core/subscriptions/test_subscriptions.py +0 -0
  176. {web3-7.13.0 → web3-7.14.0}/tests/core/test_library_files.py +0 -0
  177. {web3-7.13.0 → web3-7.14.0}/tests/core/testing-module/test_testing_mine.py +0 -0
  178. {web3-7.13.0 → web3-7.14.0}/tests/core/testing-module/test_testing_snapshot_and_revert.py +0 -0
  179. {web3-7.13.0 → web3-7.14.0}/tests/core/testing-module/test_testing_timeTravel.py +0 -0
  180. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/__init__.py +0 -0
  181. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/conftest.py +0 -0
  182. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_abi_filtering_by_argument_name.py +0 -0
  183. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_abi_is_encodable.py +0 -0
  184. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_abi_named_tree.py +0 -0
  185. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_address.py +0 -0
  186. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_async_transaction.py +0 -0
  187. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_attach_modules.py +0 -0
  188. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_attributedict.py +0 -0
  189. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_caching_utils.py +0 -0
  190. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_construct_event_data_set.py +0 -0
  191. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_construct_event_filter_params.py +0 -0
  192. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_construct_event_topics.py +0 -0
  193. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_datatypes.py +0 -0
  194. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_decorators.py +0 -0
  195. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_event_filter_builder.py +0 -0
  196. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_event_interface.py +0 -0
  197. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_fee_utils.py +0 -0
  198. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_formatters.py +0 -0
  199. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_http_session_manager.py +0 -0
  200. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_is_predefined_block_number.py +0 -0
  201. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_is_probably_enum.py +0 -0
  202. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_is_recognized_type.py +0 -0
  203. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_math.py +0 -0
  204. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_method_formatters.py +0 -0
  205. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_prepare_transaction_replacement.py +0 -0
  206. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_select_filter_method.py +0 -0
  207. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_threads.py +0 -0
  208. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_valid_transaction_params.py +0 -0
  209. {web3-7.13.0 → web3-7.14.0}/tests/core/utilities/test_validation.py +0 -0
  210. {web3-7.13.0 → web3-7.14.0}/tests/core/web3-module/test_api.py +0 -0
  211. {web3-7.13.0 → web3-7.14.0}/tests/core/web3-module/test_attach_modules.py +0 -0
  212. {web3-7.13.0 → web3-7.14.0}/tests/core/web3-module/test_client_version.py +0 -0
  213. {web3-7.13.0 → web3-7.14.0}/tests/core/web3-module/test_import_and_version.py +0 -0
  214. {web3-7.13.0 → web3-7.14.0}/tests/core/web3-module/test_keccak.py +0 -0
  215. {web3-7.13.0 → web3-7.14.0}/tests/core/web3-module/test_providers.py +0 -0
  216. {web3-7.13.0 → web3-7.14.0}/tests/core/web3-module/test_strict_bytes_type_checking.py +0 -0
  217. {web3-7.13.0 → web3-7.14.0}/tests/core/web3-module/test_web3_inheritance.py +0 -0
  218. {web3-7.13.0 → web3-7.14.0}/tests/ens/conftest.py +0 -0
  219. {web3-7.13.0 → web3-7.14.0}/tests/ens/normalization/normalization_tests.json +0 -0
  220. {web3-7.13.0 → web3-7.14.0}/tests/ens/normalization/test_normalize_name_ensip15.py +0 -0
  221. {web3-7.13.0 → web3-7.14.0}/tests/ens/test_ens.py +0 -0
  222. {web3-7.13.0 → web3-7.14.0}/tests/ens/test_get_registry.py +0 -0
  223. {web3-7.13.0 → web3-7.14.0}/tests/ens/test_get_text.py +0 -0
  224. {web3-7.13.0 → web3-7.14.0}/tests/ens/test_nameprep.py +0 -0
  225. {web3-7.13.0 → web3-7.14.0}/tests/ens/test_offchain_resolution.py +0 -0
  226. {web3-7.13.0 → web3-7.14.0}/tests/ens/test_setup_address.py +0 -0
  227. {web3-7.13.0 → web3-7.14.0}/tests/ens/test_setup_name.py +0 -0
  228. {web3-7.13.0 → web3-7.14.0}/tests/ens/test_utils.py +0 -0
  229. {web3-7.13.0 → web3-7.14.0}/tests/ens/test_wildcard_resolution.py +0 -0
  230. {web3-7.13.0 → web3-7.14.0}/tests/integration/README.md +0 -0
  231. {web3-7.13.0 → web3-7.14.0}/tests/integration/common.py +0 -0
  232. {web3-7.13.0 → web3-7.14.0}/tests/integration/conftest.py +0 -0
  233. {web3-7.13.0 → web3-7.14.0}/tests/integration/generate_fixtures/common.py +0 -0
  234. {web3-7.13.0 → web3-7.14.0}/tests/integration/generate_fixtures/go_ethereum.py +0 -0
  235. {web3-7.13.0 → web3-7.14.0}/tests/integration/geth-1.16.2-fixture.zip +0 -0
  236. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/__init__.py +0 -0
  237. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/common.py +0 -0
  238. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/test_goethereum_http.py +0 -0
  239. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/test_goethereum_ipc.py +0 -0
  240. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/test_goethereum_legacy_ws.py +0 -0
  241. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/test_goethereum_ws/__init__.py +0 -0
  242. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/test_goethereum_ws/conftest.py +0 -0
  243. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/test_goethereum_ws/test_async_await_w3.py +0 -0
  244. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/test_goethereum_ws/test_async_ctx_manager_w3.py +0 -0
  245. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/test_goethereum_ws/test_async_iterator_w3.py +0 -0
  246. {web3-7.13.0 → web3-7.14.0}/tests/integration/go_ethereum/utils.py +0 -0
  247. {web3-7.13.0 → web3-7.14.0}/tests/integration/test_ethereum_tester.py +0 -0
  248. {web3-7.13.0 → web3-7.14.0}/tests/utils.py +0 -0
  249. {web3-7.13.0 → web3-7.14.0}/web3/__init__.py +0 -0
  250. {web3-7.13.0 → web3-7.14.0}/web3/_utils/__init__.py +0 -0
  251. {web3-7.13.0 → web3-7.14.0}/web3/_utils/abi_element_identifiers.py +0 -0
  252. {web3-7.13.0 → web3-7.14.0}/web3/_utils/async_caching.py +0 -0
  253. {web3-7.13.0 → web3-7.14.0}/web3/_utils/blocks.py +0 -0
  254. {web3-7.13.0 → web3-7.14.0}/web3/_utils/caching/__init__.py +0 -0
  255. {web3-7.13.0 → web3-7.14.0}/web3/_utils/caching/request_caching_validation.py +0 -0
  256. {web3-7.13.0 → web3-7.14.0}/web3/_utils/compat/__init__.py +0 -0
  257. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/__init__.py +0 -0
  258. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/compile_contracts.py +0 -0
  259. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/__init__.py +0 -0
  260. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/_custom_contract_data.py +0 -0
  261. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/ambiguous_function_contract.py +0 -0
  262. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/arrays_contract.py +0 -0
  263. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/bytes_contracts.py +0 -0
  264. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/constructor_contracts.py +0 -0
  265. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/contract_caller_tester.py +0 -0
  266. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/emitter_contract.py +0 -0
  267. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/event_contracts.py +0 -0
  268. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/extended_resolver.py +0 -0
  269. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/fallback_function_contract.py +0 -0
  270. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/function_name_tester_contract.py +0 -0
  271. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/math_contract.py +0 -0
  272. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/offchain_lookup.py +0 -0
  273. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/offchain_resolver.py +0 -0
  274. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/panic_errors_contract.py +0 -0
  275. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/payable_tester.py +0 -0
  276. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/receive_function_contracts.py +0 -0
  277. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/reflector_contracts.py +0 -0
  278. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/revert_contract.py +0 -0
  279. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/simple_resolver.py +0 -0
  280. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/storage_contract.py +0 -0
  281. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/string_contract.py +0 -0
  282. {web3-7.13.0 → web3-7.14.0}/web3/_utils/contract_sources/contract_data/tuple_contracts.py +0 -0
  283. {web3-7.13.0 → web3-7.14.0}/web3/_utils/datatypes.py +0 -0
  284. {web3-7.13.0 → web3-7.14.0}/web3/_utils/decorators.py +0 -0
  285. {web3-7.13.0 → web3-7.14.0}/web3/_utils/empty.py +0 -0
  286. {web3-7.13.0 → web3-7.14.0}/web3/_utils/encoding.py +0 -0
  287. {web3-7.13.0 → web3-7.14.0}/web3/_utils/error_formatters_utils.py +0 -0
  288. {web3-7.13.0 → web3-7.14.0}/web3/_utils/fee_utils.py +0 -0
  289. {web3-7.13.0 → web3-7.14.0}/web3/_utils/filters.py +0 -0
  290. {web3-7.13.0 → web3-7.14.0}/web3/_utils/formatters.py +0 -0
  291. {web3-7.13.0 → web3-7.14.0}/web3/_utils/http.py +0 -0
  292. {web3-7.13.0 → web3-7.14.0}/web3/_utils/http_session_manager.py +0 -0
  293. {web3-7.13.0 → web3-7.14.0}/web3/_utils/hypothesis.py +0 -0
  294. {web3-7.13.0 → web3-7.14.0}/web3/_utils/math.py +0 -0
  295. {web3-7.13.0 → web3-7.14.0}/web3/_utils/method_formatters.py +0 -0
  296. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module.py +0 -0
  297. {web3-7.13.0 → web3-7.14.0}/web3/_utils/module_testing/__init__.py +0 -0
  298. {web3-7.13.0 → web3-7.14.0}/web3/_utils/rpc_abi.py +0 -0
  299. {web3-7.13.0 → web3-7.14.0}/web3/_utils/threads.py +0 -0
  300. {web3-7.13.0 → web3-7.14.0}/web3/_utils/type_conversion.py +0 -0
  301. {web3-7.13.0 → web3-7.14.0}/web3/_utils/utility_methods.py +0 -0
  302. {web3-7.13.0 → web3-7.14.0}/web3/_utils/validation.py +0 -0
  303. {web3-7.13.0 → web3-7.14.0}/web3/_utils/windows.py +0 -0
  304. {web3-7.13.0 → web3-7.14.0}/web3/auto/__init__.py +0 -0
  305. {web3-7.13.0 → web3-7.14.0}/web3/auto/gethdev.py +0 -0
  306. {web3-7.13.0 → web3-7.14.0}/web3/beacon/__init__.py +0 -0
  307. {web3-7.13.0 → web3-7.14.0}/web3/beacon/api_endpoints.py +0 -0
  308. {web3-7.13.0 → web3-7.14.0}/web3/beacon/async_beacon.py +0 -0
  309. {web3-7.13.0 → web3-7.14.0}/web3/beacon/beacon.py +0 -0
  310. {web3-7.13.0 → web3-7.14.0}/web3/constants.py +0 -0
  311. {web3-7.13.0 → web3-7.14.0}/web3/contract/__init__.py +0 -0
  312. {web3-7.13.0 → web3-7.14.0}/web3/contract/contract.py +0 -0
  313. {web3-7.13.0 → web3-7.14.0}/web3/datastructures.py +0 -0
  314. {web3-7.13.0 → web3-7.14.0}/web3/eth/__init__.py +0 -0
  315. {web3-7.13.0 → web3-7.14.0}/web3/eth/base_eth.py +0 -0
  316. {web3-7.13.0 → web3-7.14.0}/web3/eth/eth.py +0 -0
  317. {web3-7.13.0 → web3-7.14.0}/web3/exceptions.py +0 -0
  318. {web3-7.13.0 → web3-7.14.0}/web3/gas_strategies/__init__.py +0 -0
  319. {web3-7.13.0 → web3-7.14.0}/web3/gas_strategies/rpc.py +0 -0
  320. {web3-7.13.0 → web3-7.14.0}/web3/geth.py +0 -0
  321. {web3-7.13.0 → web3-7.14.0}/web3/logs.py +0 -0
  322. {web3-7.13.0 → web3-7.14.0}/web3/method.py +0 -0
  323. {web3-7.13.0 → web3-7.14.0}/web3/middleware/attrdict.py +0 -0
  324. {web3-7.13.0 → web3-7.14.0}/web3/middleware/proof_of_authority.py +0 -0
  325. {web3-7.13.0 → web3-7.14.0}/web3/middleware/pythonic.py +0 -0
  326. {web3-7.13.0 → web3-7.14.0}/web3/net.py +0 -0
  327. {web3-7.13.0 → web3-7.14.0}/web3/providers/__init__.py +0 -0
  328. {web3-7.13.0 → web3-7.14.0}/web3/providers/auto.py +0 -0
  329. {web3-7.13.0 → web3-7.14.0}/web3/providers/eth_tester/__init__.py +0 -0
  330. {web3-7.13.0 → web3-7.14.0}/web3/providers/ipc.py +0 -0
  331. {web3-7.13.0 → web3-7.14.0}/web3/providers/legacy_websocket.py +0 -0
  332. {web3-7.13.0 → web3-7.14.0}/web3/providers/persistent/__init__.py +0 -0
  333. {web3-7.13.0 → web3-7.14.0}/web3/providers/persistent/async_ipc.py +0 -0
  334. {web3-7.13.0 → web3-7.14.0}/web3/providers/persistent/request_processor.py +0 -0
  335. {web3-7.13.0 → web3-7.14.0}/web3/providers/persistent/subscription_container.py +0 -0
  336. {web3-7.13.0 → web3-7.14.0}/web3/providers/persistent/websocket.py +0 -0
  337. {web3-7.13.0 → web3-7.14.0}/web3/providers/rpc/__init__.py +0 -0
  338. {web3-7.13.0 → web3-7.14.0}/web3/providers/rpc/async_rpc.py +0 -0
  339. {web3-7.13.0 → web3-7.14.0}/web3/providers/rpc/rpc.py +0 -0
  340. {web3-7.13.0 → web3-7.14.0}/web3/providers/rpc/utils.py +0 -0
  341. {web3-7.13.0 → web3-7.14.0}/web3/py.typed +0 -0
  342. {web3-7.13.0 → web3-7.14.0}/web3/scripts/__init__.py +0 -0
  343. {web3-7.13.0 → web3-7.14.0}/web3/scripts/install_pre_releases.py +0 -0
  344. {web3-7.13.0 → web3-7.14.0}/web3/scripts/parse_pygeth_version.py +0 -0
  345. {web3-7.13.0 → web3-7.14.0}/web3/scripts/release/__init__.py +0 -0
  346. {web3-7.13.0 → web3-7.14.0}/web3/scripts/release/test_package.py +0 -0
  347. {web3-7.13.0 → web3-7.14.0}/web3/testing.py +0 -0
  348. {web3-7.13.0 → web3-7.14.0}/web3/tracing.py +0 -0
  349. {web3-7.13.0 → web3-7.14.0}/web3/utils/__init__.py +0 -0
  350. {web3-7.13.0 → web3-7.14.0}/web3/utils/abi.py +0 -0
  351. {web3-7.13.0 → web3-7.14.0}/web3/utils/address.py +0 -0
  352. {web3-7.13.0 → web3-7.14.0}/web3/utils/async_exception_handling.py +0 -0
  353. {web3-7.13.0 → web3-7.14.0}/web3/utils/caching.py +0 -0
  354. {web3-7.13.0 → web3-7.14.0}/web3/utils/exception_handling.py +0 -0
  355. {web3-7.13.0 → web3-7.14.0}/web3.egg-info/SOURCES.txt +0 -0
  356. {web3-7.13.0 → web3-7.14.0}/web3.egg-info/dependency_links.txt +0 -0
  357. {web3-7.13.0 → web3-7.14.0}/web3.egg-info/not-zip-safe +0 -0
  358. {web3-7.13.0 → web3-7.14.0}/web3.egg-info/requires.txt +0 -0
  359. {web3-7.13.0 → web3-7.14.0}/web3.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: web3
3
- Version: 7.13.0
3
+ Version: 7.14.0
4
4
  Summary: web3: A Python library for interacting with Ethereum
5
5
  Home-page: https://github.com/ethereum/web3.py
6
6
  Author: The Ethereum Foundation
@@ -72,7 +72,9 @@ if TYPE_CHECKING:
72
72
  AsyncContract,
73
73
  AsyncContractFunction,
74
74
  )
75
- from web3.main import AsyncWeb3 # noqa: F401
75
+ from web3.main import ( # noqa: F401
76
+ AsyncWeb3,
77
+ )
76
78
  from web3.middleware.base import ( # noqa: F401
77
79
  Middleware,
78
80
  )
@@ -96,12 +98,12 @@ class AsyncENS(BaseENS):
96
98
  """
97
99
 
98
100
  # mypy types
99
- w3: "AsyncWeb3"
101
+ w3: "AsyncWeb3[Any]"
100
102
 
101
103
  def __init__(
102
104
  self,
103
- provider: "AsyncBaseProvider" = None,
104
- addr: ChecksumAddress = None,
105
+ provider: Optional["AsyncBaseProvider"] = None,
106
+ addr: Optional[ChecksumAddress] = None,
105
107
  middleware: Optional[Sequence[Tuple["Middleware", str]]] = None,
106
108
  ) -> None:
107
109
  """
@@ -123,7 +125,9 @@ class AsyncENS(BaseENS):
123
125
  )
124
126
 
125
127
  @classmethod
126
- def from_web3(cls, w3: "AsyncWeb3", addr: ChecksumAddress = None) -> "AsyncENS":
128
+ def from_web3(
129
+ cls, w3: "AsyncWeb3[Any]", addr: ChecksumAddress = None
130
+ ) -> "AsyncENS":
127
131
  """
128
132
  Generate an AsyncENS instance with web3
129
133
 
@@ -38,7 +38,7 @@ if TYPE_CHECKING:
38
38
 
39
39
 
40
40
  class BaseENS:
41
- w3: Union["AsyncWeb3", "Web3"] = None
41
+ w3: Union["AsyncWeb3[Any]", "Web3"] = None
42
42
  ens: Union["Contract", "AsyncContract"] = None
43
43
  _resolver_contract: Union[Type["Contract"], Type["AsyncContract"]] = None
44
44
  _reverse_resolver_contract: Union[Type["Contract"], Type["AsyncContract"]] = None
@@ -302,7 +302,7 @@ def is_valid_ens_name(ens_name: str) -> bool:
302
302
  def init_async_web3(
303
303
  provider: "AsyncBaseProvider" = None,
304
304
  middleware: Optional[Sequence[Tuple["Middleware", str]]] = (),
305
- ) -> "AsyncWeb3":
305
+ ) -> "AsyncWeb3[Any]":
306
306
  from web3 import (
307
307
  AsyncWeb3 as AsyncWeb3Main,
308
308
  )
@@ -327,6 +327,7 @@ def init_async_web3(
327
327
  )
328
328
  )
329
329
 
330
+ async_w3: "AsyncWeb3[Any]"
330
331
  if provider is default:
331
332
  async_w3 = AsyncWeb3Main(
332
333
  middleware=middleware, ens=None, modules={"eth": (AsyncEthMain)}
@@ -15,7 +15,7 @@ multi_line_output = 3
15
15
  profile = "black"
16
16
  use_parentheses = true
17
17
  # skip `__init__.py` files because sometimes order of initialization is important
18
- skip="__init__.py,web3/main.py,web3/utils/windows.py"
18
+ skip="__init__.py,web3/main.py,web3/_utils/windows.py"
19
19
 
20
20
  [tool.mypy]
21
21
  check_untyped_defs = true
@@ -127,7 +127,7 @@ name = "Removals"
127
127
  showcontent = true
128
128
 
129
129
  [tool.bumpversion]
130
- current_version = "7.13.0"
130
+ current_version = "7.14.0"
131
131
  parse = """
132
132
  (?P<major>\\d+)
133
133
  \\.(?P<minor>\\d+)
@@ -55,7 +55,7 @@ with open("./README.md") as readme:
55
55
  setup(
56
56
  name="web3",
57
57
  # *IMPORTANT*: Don't manually change the version here. See Contributing docs for the release process.
58
- version="7.13.0",
58
+ version="7.14.0",
59
59
  description="""web3: A Python library for interacting with Ethereum""",
60
60
  long_description=long_description,
61
61
  long_description_content_type="text/markdown",
@@ -4,7 +4,9 @@ from eth_utils import (
4
4
  to_dict,
5
5
  )
6
6
  from hypothesis import (
7
+ HealthCheck,
7
8
  given,
9
+ settings,
8
10
  strategies as st,
9
11
  )
10
12
 
@@ -42,6 +44,9 @@ def recursive_shuffle_dict(v):
42
44
  return v
43
45
 
44
46
 
47
+ # Generating data for the `all_st` strategy can be slow, so we disable the
48
+ # "too_slow" health check for this test.
49
+ @settings(suppress_health_check=[HealthCheck.too_slow])
45
50
  @given(value=all_st)
46
51
  def test_key_generation_is_deterministic(value):
47
52
  left = recursive_shuffle_dict(value)
@@ -238,8 +238,8 @@ def test_call_get_byte_array_non_strict(non_strict_arrays_contract, call):
238
238
  "args,expected",
239
239
  [
240
240
  ([b"1"], [b"1"]),
241
- (["0xDe"], [b"\xDe"]),
242
- (["0xDe", "0xDe"], [b"\xDe", b"\xDe"]),
241
+ (["0xDe"], [b"\xde"]),
242
+ (["0xDe", "0xDe"], [b"\xde", b"\xde"]),
243
243
  ],
244
244
  )
245
245
  def test_set_byte_array(arrays_contract, call, transact, args, expected):
@@ -257,8 +257,8 @@ def test_set_byte_array(arrays_contract, call, transact, args, expected):
257
257
  "args,expected",
258
258
  [
259
259
  ([b"1"], [b"1"]),
260
- (["0xDe"], [b"\xDe"]),
261
- (["0xDe", "0xDe"], [b"\xDe", b"\xDe"]),
260
+ (["0xDe"], [b"\xde"]),
261
+ (["0xDe", "0xDe"], [b"\xde", b"\xde"]),
262
262
  ],
263
263
  )
264
264
  def test_set_byte_array_non_strict(
@@ -1503,7 +1503,7 @@ async def test_async_set_byte_array_non_strict(
1503
1503
 
1504
1504
 
1505
1505
  @pytest.mark.asyncio
1506
- @pytest.mark.parametrize("args,expected", [([b"1"], [b"1"]), (["0xDe"], [b"\xDe"])])
1506
+ @pytest.mark.parametrize("args,expected", [([b"1"], [b"1"]), (["0xDe"], [b"\xde"])])
1507
1507
  async def test_async_set_byte_array_strict_by_default(
1508
1508
  async_arrays_contract, async_call, async_transact, args, expected
1509
1509
  ):
@@ -249,8 +249,8 @@ def test_get_tuple_type_str_parts(
249
249
  [
250
250
  (
251
251
  ["bool[2]", "bytes"],
252
- [[True, False], b"\x00\xFF"],
253
- [("bool[2]", [("bool", True), ("bool", False)]), ("bytes", b"\x00\xFF")],
252
+ [[True, False], b"\x00\xff"],
253
+ [("bool[2]", [("bool", True), ("bool", False)]), ("bytes", b"\x00\xff")],
254
254
  ),
255
255
  (
256
256
  ["uint256[]"],
@@ -337,7 +337,7 @@ def test_map_abi_data(
337
337
 
338
338
  @pytest.mark.parametrize("arg", (6, 7, 9, 12, 20, 30))
339
339
  def test_exact_length_bytes_encoder_raises_on_non_multiples_of_8_bit_size(
340
- arg: Tuple[int, ...]
340
+ arg: Tuple[int, ...],
341
341
  ) -> None:
342
342
  with pytest.raises(Web3ValueError, match="multiple of 8"):
343
343
  _ = ExactLengthBytesEncoder(None, data_byte_size=2, value_bit_size=arg)
@@ -144,8 +144,11 @@ def test_text_if_str_on_text(val):
144
144
  ),
145
145
  (
146
146
  {
147
- "date": [datetime.datetime.utcnow(), datetime.datetime.now()],
148
- "other_date": datetime.datetime.utcnow().date(),
147
+ "date": [
148
+ datetime.datetime.now(datetime.timezone.utc),
149
+ datetime.datetime.now(),
150
+ ],
151
+ "other_date": datetime.datetime.now(datetime.timezone.utc).date(),
149
152
  },
150
153
  TypeError,
151
154
  "Could not encode to JSON: .*'other_date'.*is not JSON serializable",
@@ -159,7 +159,7 @@ def test_to_int_hexstr(val, expected):
159
159
  (b"\x01", "0x01"),
160
160
  (b"\x10", "0x10"),
161
161
  (b"\x01\x00", "0x0100"),
162
- (b"\x00\x0F", "0x000f"),
162
+ (b"\x00\x0f", "0x000f"),
163
163
  (b"", "0x"),
164
164
  (0, "0x0"),
165
165
  (1, "0x1"),
@@ -175,12 +175,14 @@ def start_geth_process_and_yield_port(
175
175
  bufsize=1,
176
176
  )
177
177
 
178
- port = wait_for_port(proc)
179
- yield port
180
-
181
- kill_proc_gracefully(proc)
182
- output, errors = proc.communicate(timeout=5)
183
- print("Geth Process Exited:\n" f"stdout: {output}\n\n" f"stderr: {errors}\n\n")
178
+ try:
179
+ port = wait_for_port(proc)
180
+ yield port
181
+ finally:
182
+ # Ensure cleanup happens even if test fails
183
+ kill_proc_gracefully(proc)
184
+ output, errors = proc.communicate(timeout=5)
185
+ print("Geth Process Exited:\n" f"stdout: {output}\n\n" f"stderr: {errors}\n\n")
184
186
 
185
187
 
186
188
  @pytest.fixture
@@ -852,7 +852,7 @@ def _named_subtree(
852
852
 
853
853
  def recursive_dict_to_namedtuple(data: Dict[str, Any]) -> Tuple[Any, ...]:
854
854
  def _dict_to_namedtuple(
855
- value: Union[Dict[str, Any], List[Any]]
855
+ value: Union[Dict[str, Any], List[Any]],
856
856
  ) -> Union[Tuple[Any, ...], List[Any]]:
857
857
  if not isinstance(value, dict):
858
858
  return value
@@ -864,7 +864,7 @@ def recursive_dict_to_namedtuple(data: Dict[str, Any]) -> Tuple[Any, ...]:
864
864
 
865
865
 
866
866
  def abi_decoded_namedtuple_factory(
867
- fields: Tuple[Any, ...]
867
+ fields: Tuple[Any, ...],
868
868
  ) -> Callable[..., Tuple[Any, ...]]:
869
869
  class ABIDecodedNamedTuple(namedtuple("ABIDecodedNamedTuple", fields, rename=True)): # type: ignore # noqa: E501
870
870
  def __new__(self, args: Any) -> "ABIDecodedNamedTuple":
@@ -877,9 +877,9 @@ def abi_decoded_namedtuple_factory(
877
877
 
878
878
 
879
879
  async def async_data_tree_map(
880
- async_w3: "AsyncWeb3",
880
+ async_w3: "AsyncWeb3[Any]",
881
881
  func: Callable[
882
- ["AsyncWeb3", TypeStr, Any], Coroutine[Any, Any, Tuple[TypeStr, Any]]
882
+ ["AsyncWeb3[Any]", TypeStr, Any], Coroutine[Any, Any, Tuple[TypeStr, Any]]
883
883
  ],
884
884
  data_tree: Any,
885
885
  ) -> "ABITypedData":
@@ -902,7 +902,7 @@ async def async_data_tree_map(
902
902
 
903
903
  @reject_recursive_repeats
904
904
  async def async_recursive_map(
905
- async_w3: "AsyncWeb3",
905
+ async_w3: "AsyncWeb3[Any]",
906
906
  func: Callable[[Any], Coroutine[Any, Any, TReturn]],
907
907
  data: Any,
908
908
  ) -> TReturn:
@@ -1,5 +1,6 @@
1
1
  from typing import (
2
2
  TYPE_CHECKING,
3
+ Any,
3
4
  Dict,
4
5
  Optional,
5
6
  Union,
@@ -46,13 +47,13 @@ if TYPE_CHECKING:
46
47
 
47
48
  # unused vars present in these funcs because they all need to have the same signature
48
49
  async def _estimate_gas(
49
- async_w3: "AsyncWeb3", tx: TxParams, _defaults: Dict[str, Union[bytes, int]]
50
+ async_w3: "AsyncWeb3[Any]", tx: TxParams, _defaults: Dict[str, Union[bytes, int]]
50
51
  ) -> int:
51
52
  return await async_w3.eth.estimate_gas(tx)
52
53
 
53
54
 
54
55
  async def _max_fee_per_gas(
55
- async_w3: "AsyncWeb3", tx: TxParams, defaults: Dict[str, Union[bytes, int]]
56
+ async_w3: "AsyncWeb3[Any]", tx: TxParams, defaults: Dict[str, Union[bytes, int]]
56
57
  ) -> Wei:
57
58
  block = await async_w3.eth.get_block("latest")
58
59
  max_priority_fee = tx.get(
@@ -62,13 +63,13 @@ async def _max_fee_per_gas(
62
63
 
63
64
 
64
65
  async def _max_priority_fee_gas(
65
- async_w3: "AsyncWeb3", _tx: TxParams, _defaults: Dict[str, Union[bytes, int]]
66
+ async_w3: "AsyncWeb3[Any]", _tx: TxParams, _defaults: Dict[str, Union[bytes, int]]
66
67
  ) -> Wei:
67
68
  return await async_w3.eth.max_priority_fee
68
69
 
69
70
 
70
71
  async def _chain_id(
71
- async_w3: "AsyncWeb3", _tx: TxParams, _defaults: Dict[str, Union[bytes, int]]
72
+ async_w3: "AsyncWeb3[Any]", _tx: TxParams, _defaults: Dict[str, Union[bytes, int]]
72
73
  ) -> int:
73
74
  return await async_w3.eth.chain_id
74
75
 
@@ -92,7 +93,7 @@ async def get_block_gas_limit(
92
93
 
93
94
 
94
95
  async def get_buffered_gas_estimate(
95
- async_w3: "AsyncWeb3", transaction: TxParams, gas_buffer: int = 100000
96
+ async_w3: "AsyncWeb3[Any]", transaction: TxParams, gas_buffer: int = 100000
96
97
  ) -> int:
97
98
  gas_estimate_transaction = cast(TxParams, dict(**transaction))
98
99
 
@@ -110,7 +111,9 @@ async def get_buffered_gas_estimate(
110
111
  return min(gas_limit, gas_estimate + gas_buffer)
111
112
 
112
113
 
113
- async def async_fill_nonce(async_w3: "AsyncWeb3", transaction: TxParams) -> TxParams:
114
+ async def async_fill_nonce(
115
+ async_w3: "AsyncWeb3[Any]", transaction: TxParams
116
+ ) -> TxParams:
114
117
  if "from" in transaction and "nonce" not in transaction:
115
118
  tx_count = await async_w3.eth.get_transaction_count(
116
119
  cast(ChecksumAddress, transaction["from"]),
@@ -121,7 +124,7 @@ async def async_fill_nonce(async_w3: "AsyncWeb3", transaction: TxParams) -> TxPa
121
124
 
122
125
 
123
126
  async def async_fill_transaction_defaults(
124
- async_w3: "AsyncWeb3", transaction: TxParams
127
+ async_w3: "AsyncWeb3[Any]", transaction: TxParams
125
128
  ) -> TxParams:
126
129
  """
127
130
  If async_w3 is None, fill as much as possible while offline
@@ -165,7 +168,7 @@ async def async_fill_transaction_defaults(
165
168
 
166
169
 
167
170
  async def async_get_required_transaction(
168
- async_w3: "AsyncWeb3", transaction_hash: _Hash32
171
+ async_w3: "AsyncWeb3[Any]", transaction_hash: _Hash32
169
172
  ) -> TxData:
170
173
  current_transaction = await async_w3.eth.get_transaction(transaction_hash)
171
174
  if not current_transaction:
@@ -176,7 +179,7 @@ async def async_get_required_transaction(
176
179
 
177
180
 
178
181
  async def async_replace_transaction(
179
- async_w3: "AsyncWeb3", current_transaction: TxData, new_transaction: TxParams
182
+ async_w3: "AsyncWeb3[Any]", current_transaction: TxData, new_transaction: TxParams
180
183
  ) -> HexBytes:
181
184
  new_transaction = prepare_replacement_transaction(
182
185
  async_w3, current_transaction, new_transaction
@@ -71,7 +71,7 @@ RPC_METHODS_UNSUPPORTED_DURING_BATCH = {
71
71
 
72
72
 
73
73
  class RequestBatcher(Generic[TFunc]):
74
- def __init__(self, web3: Union["AsyncWeb3", "Web3"]) -> None:
74
+ def __init__(self, web3: Union["AsyncWeb3[Any]", "Web3"]) -> None:
75
75
  self.web3 = web3
76
76
  self._requests_info: List[BatchRequestInformation] = []
77
77
  self._async_requests_info: List[
@@ -238,7 +238,7 @@ def _should_cache_response(
238
238
 
239
239
 
240
240
  def handle_request_caching(
241
- func: Callable[[SYNC_PROVIDER_TYPE, RPCEndpoint, Any], "RPCResponse"]
241
+ func: Callable[[SYNC_PROVIDER_TYPE, RPCEndpoint, Any], "RPCResponse"],
242
242
  ) -> Callable[..., "RPCResponse"]:
243
243
  def wrapper(
244
244
  provider: SYNC_PROVIDER_TYPE, method: RPCEndpoint, params: Any
@@ -401,7 +401,7 @@ def async_handle_recv_caching(
401
401
  func: Callable[
402
402
  ["PersistentConnectionProvider", "RPCRequest"],
403
403
  Coroutine[Any, Any, "RPCResponse"],
404
- ]
404
+ ],
405
405
  ) -> Callable[..., Coroutine[Any, Any, "RPCResponse"]]:
406
406
  async def wrapper(
407
407
  provider: "PersistentConnectionProvider",
@@ -121,7 +121,7 @@ def find_matching_event_abi(
121
121
 
122
122
 
123
123
  def encode_abi(
124
- w3: Union["AsyncWeb3", "Web3"],
124
+ w3: Union["AsyncWeb3[Any]", "Web3"],
125
125
  abi: ABIElement,
126
126
  arguments: Sequence[Any],
127
127
  data: Optional[HexStr] = None,
@@ -168,7 +168,7 @@ def encode_abi(
168
168
 
169
169
  def prepare_transaction(
170
170
  address: ChecksumAddress,
171
- w3: Union["AsyncWeb3", "Web3"],
171
+ w3: Union["AsyncWeb3[Any]", "Web3"],
172
172
  abi_element_identifier: ABIElementIdentifier,
173
173
  contract_abi: Optional[ABI] = None,
174
174
  abi_callable: Optional[ABICallable] = None,
@@ -232,7 +232,7 @@ def prepare_transaction(
232
232
 
233
233
 
234
234
  def encode_transaction_data(
235
- w3: Union["AsyncWeb3", "Web3"],
235
+ w3: Union["AsyncWeb3[Any]", "Web3"],
236
236
  abi_element_identifier: ABIElementIdentifier,
237
237
  contract_abi: Optional[ABI] = None,
238
238
  abi_callable: Optional[ABICallable] = None,
@@ -363,7 +363,7 @@ def parse_block_identifier_int(w3: "Web3", block_identifier_int: int) -> BlockNu
363
363
 
364
364
 
365
365
  async def async_parse_block_identifier(
366
- async_w3: "AsyncWeb3", block_identifier: BlockIdentifier
366
+ async_w3: "AsyncWeb3[Any]", block_identifier: BlockIdentifier
367
367
  ) -> BlockIdentifier:
368
368
  if block_identifier is None:
369
369
  return async_w3.eth.default_block
@@ -381,7 +381,7 @@ async def async_parse_block_identifier(
381
381
 
382
382
 
383
383
  async def async_parse_block_identifier_int(
384
- async_w3: "AsyncWeb3", block_identifier_int: int
384
+ async_w3: "AsyncWeb3[Any]", block_identifier_int: int
385
385
  ) -> BlockNumber:
386
386
  if block_identifier_int >= 0:
387
387
  block_num = block_identifier_int
@@ -75,7 +75,7 @@ class AsyncStaticENS:
75
75
 
76
76
  @contextmanager
77
77
  def ens_addresses(
78
- w3: Union["Web3", "AsyncWeb3"], name_addr_pairs: Dict[str, ChecksumAddress]
78
+ w3: Union["Web3", "AsyncWeb3[Any]"], name_addr_pairs: Dict[str, ChecksumAddress]
79
79
  ) -> Iterator[None]:
80
80
  original_ens = w3.ens
81
81
  if w3.provider.is_async:
@@ -453,7 +453,7 @@ class EventFilterBuilder(BaseEventFilterBuilder):
453
453
 
454
454
 
455
455
  class AsyncEventFilterBuilder(BaseEventFilterBuilder):
456
- async def deploy(self, async_w3: "AsyncWeb3") -> "AsyncLogFilter":
456
+ async def deploy(self, async_w3: "AsyncWeb3[Any]") -> "AsyncLogFilter":
457
457
  if not isinstance(async_w3, web3.AsyncWeb3):
458
458
  raise Web3ValueError(f"Invalid web3 argument: got: {async_w3!r}")
459
459