apify 1.3.0__tar.gz → 3.0.5b8__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 (292) hide show
  1. apify-3.0.5b8/.editorconfig +15 -0
  2. apify-3.0.5b8/.github/CODEOWNERS +4 -0
  3. apify-3.0.5b8/.github/workflows/build_and_deploy_docs.yaml +87 -0
  4. apify-3.0.5b8/.github/workflows/check_pr_title.yaml +14 -0
  5. apify-3.0.5b8/.github/workflows/pre_release.yaml +90 -0
  6. apify-3.0.5b8/.github/workflows/release.yaml +124 -0
  7. apify-3.0.5b8/.github/workflows/run_code_checks.yaml +43 -0
  8. apify-3.0.5b8/.github/workflows/update_new_issue.yaml +25 -0
  9. apify-3.0.5b8/.gitignore +49 -0
  10. apify-3.0.5b8/.markdownlint.yaml +5 -0
  11. apify-3.0.5b8/.pre-commit-config.yaml +14 -0
  12. apify-3.0.5b8/CHANGELOG.md +484 -0
  13. apify-3.0.5b8/CONTRIBUTING.md +160 -0
  14. apify-3.0.5b8/Makefile +52 -0
  15. apify-3.0.5b8/PKG-INFO +430 -0
  16. apify-3.0.5b8/README.md +188 -0
  17. apify-3.0.5b8/docs/01_overview/01_introduction.mdx +59 -0
  18. apify-3.0.5b8/docs/01_overview/02_running_actors_locally.mdx +66 -0
  19. apify-3.0.5b8/docs/01_overview/03_actor_structure.mdx +35 -0
  20. apify-3.0.5b8/docs/01_overview/code/01_introduction.py +24 -0
  21. apify-3.0.5b8/docs/01_overview/code/actor_structure/__main__.py +6 -0
  22. apify-3.0.5b8/docs/01_overview/code/actor_structure/main.py +8 -0
  23. apify-3.0.5b8/docs/01_overview/code/actor_structure/py.typed +0 -0
  24. apify-3.0.5b8/docs/02_concepts/01_actor_lifecycle.mdx +101 -0
  25. apify-3.0.5b8/docs/02_concepts/02_actor_input.mdx +18 -0
  26. apify-3.0.5b8/docs/02_concepts/03_storages.mdx +173 -0
  27. apify-3.0.5b8/docs/02_concepts/04_actor_events.mdx +81 -0
  28. apify-3.0.5b8/docs/02_concepts/05_proxy_management.mdx +108 -0
  29. apify-3.0.5b8/docs/02_concepts/06_interacting_with_other_actors.mdx +51 -0
  30. apify-3.0.5b8/docs/02_concepts/07_webhooks.mdx +31 -0
  31. apify-3.0.5b8/docs/02_concepts/08_access_apify_api.mdx +31 -0
  32. apify-3.0.5b8/docs/02_concepts/09_running_webserver.mdx +26 -0
  33. apify-3.0.5b8/docs/02_concepts/10_logging.mdx +114 -0
  34. apify-3.0.5b8/docs/02_concepts/11_configuration.mdx +34 -0
  35. apify-3.0.5b8/docs/02_concepts/12_pay_per_event.mdx +52 -0
  36. apify-3.0.5b8/docs/02_concepts/code/01_class_context.py +21 -0
  37. apify-3.0.5b8/docs/02_concepts/code/01_class_manual.py +26 -0
  38. apify-3.0.5b8/docs/02_concepts/code/01_context_manager.py +15 -0
  39. apify-3.0.5b8/docs/02_concepts/code/01_error_handling_context.py +13 -0
  40. apify-3.0.5b8/docs/02_concepts/code/01_error_handling_manual.py +33 -0
  41. apify-3.0.5b8/docs/02_concepts/code/01_init_exit.py +22 -0
  42. apify-3.0.5b8/docs/02_concepts/code/01_instance_context.py +27 -0
  43. apify-3.0.5b8/docs/02_concepts/code/01_instance_manual.py +32 -0
  44. apify-3.0.5b8/docs/02_concepts/code/01_reboot.py +23 -0
  45. apify-3.0.5b8/docs/02_concepts/code/01_status_message.py +24 -0
  46. apify-3.0.5b8/docs/02_concepts/code/02_input.py +15 -0
  47. apify-3.0.5b8/docs/02_concepts/code/03_dataset_exports.py +37 -0
  48. apify-3.0.5b8/docs/02_concepts/code/03_dataset_read_write.py +22 -0
  49. apify-3.0.5b8/docs/02_concepts/code/03_deleting_storages.py +19 -0
  50. apify-3.0.5b8/docs/02_concepts/code/03_kvs_iterating.py +24 -0
  51. apify-3.0.5b8/docs/02_concepts/code/03_kvs_public_url.py +17 -0
  52. apify-3.0.5b8/docs/02_concepts/code/03_kvs_read_write.py +31 -0
  53. apify-3.0.5b8/docs/02_concepts/code/03_opening_storages.py +22 -0
  54. apify-3.0.5b8/docs/02_concepts/code/03_rq.py +54 -0
  55. apify-3.0.5b8/docs/02_concepts/code/04_actor_events.py +42 -0
  56. apify-3.0.5b8/docs/02_concepts/code/05_apify_proxy.py +18 -0
  57. apify-3.0.5b8/docs/02_concepts/code/05_apify_proxy_config.py +21 -0
  58. apify-3.0.5b8/docs/02_concepts/code/05_custom_proxy.py +23 -0
  59. apify-3.0.5b8/docs/02_concepts/code/05_custom_proxy_function.py +34 -0
  60. apify-3.0.5b8/docs/02_concepts/code/05_proxy_actor_input.py +22 -0
  61. apify-3.0.5b8/docs/02_concepts/code/05_proxy_httpx.py +28 -0
  62. apify-3.0.5b8/docs/02_concepts/code/05_proxy_rotation.py +29 -0
  63. apify-3.0.5b8/docs/02_concepts/code/06_interacting_call.py +28 -0
  64. apify-3.0.5b8/docs/02_concepts/code/06_interacting_call_task.py +25 -0
  65. apify-3.0.5b8/docs/02_concepts/code/06_interacting_metamorph.py +30 -0
  66. apify-3.0.5b8/docs/02_concepts/code/06_interacting_start.py +19 -0
  67. apify-3.0.5b8/docs/02_concepts/code/07_webhook.py +22 -0
  68. apify-3.0.5b8/docs/02_concepts/code/07_webhook_preventing.py +23 -0
  69. apify-3.0.5b8/docs/02_concepts/code/08_actor_client.py +17 -0
  70. apify-3.0.5b8/docs/02_concepts/code/08_actor_new_client.py +20 -0
  71. apify-3.0.5b8/docs/02_concepts/code/09_webserver.py +53 -0
  72. apify-3.0.5b8/docs/02_concepts/code/10_log_config.py +17 -0
  73. apify-3.0.5b8/docs/02_concepts/code/10_logger_usage.py +28 -0
  74. apify-3.0.5b8/docs/02_concepts/code/10_redirect_log.py +21 -0
  75. apify-3.0.5b8/docs/02_concepts/code/10_redirect_log_existing_run.py +28 -0
  76. apify-3.0.5b8/docs/02_concepts/code/11_config.py +23 -0
  77. apify-3.0.5b8/docs/02_concepts/code/12_actor_charge.py +36 -0
  78. apify-3.0.5b8/docs/02_concepts/code/12_conditional_actor_charge.py +24 -0
  79. apify-3.0.5b8/docs/03_guides/01_beautifulsoup_httpx.mdx +30 -0
  80. apify-3.0.5b8/docs/03_guides/02_parsel_impit.mdx +28 -0
  81. apify-3.0.5b8/docs/03_guides/03_playwright.mdx +57 -0
  82. apify-3.0.5b8/docs/03_guides/04_selenium.mdx +46 -0
  83. apify-3.0.5b8/docs/03_guides/05_crawlee.mdx +46 -0
  84. apify-3.0.5b8/docs/03_guides/06_scrapy.mdx +114 -0
  85. apify-3.0.5b8/docs/03_guides/code/01_beautifulsoup_httpx.py +88 -0
  86. apify-3.0.5b8/docs/03_guides/code/02_parsel_impit.py +94 -0
  87. apify-3.0.5b8/docs/03_guides/code/03_playwright.py +97 -0
  88. apify-3.0.5b8/docs/03_guides/code/04_selenium.py +106 -0
  89. apify-3.0.5b8/docs/03_guides/code/05_crawlee_beautifulsoup.py +55 -0
  90. apify-3.0.5b8/docs/03_guides/code/05_crawlee_parsel.py +55 -0
  91. apify-3.0.5b8/docs/03_guides/code/05_crawlee_playwright.py +58 -0
  92. apify-3.0.5b8/docs/03_guides/code/scrapy_project/src/__init__.py +0 -0
  93. apify-3.0.5b8/docs/03_guides/code/scrapy_project/src/__main__.py +22 -0
  94. apify-3.0.5b8/docs/03_guides/code/scrapy_project/src/items.py +10 -0
  95. apify-3.0.5b8/docs/03_guides/code/scrapy_project/src/main.py +37 -0
  96. apify-3.0.5b8/docs/03_guides/code/scrapy_project/src/py.typed +0 -0
  97. apify-3.0.5b8/docs/03_guides/code/scrapy_project/src/settings.py +11 -0
  98. apify-3.0.5b8/docs/03_guides/code/scrapy_project/src/spiders/__init__.py +3 -0
  99. apify-3.0.5b8/docs/03_guides/code/scrapy_project/src/spiders/py.typed +0 -0
  100. apify-3.0.5b8/docs/03_guides/code/scrapy_project/src/spiders/title.py +68 -0
  101. apify-3.0.5b8/docs/04_upgrading/upgrading_to_v2.md +48 -0
  102. apify-3.0.5b8/docs/04_upgrading/upgrading_to_v3.md +159 -0
  103. apify-3.0.5b8/docs/pyproject.toml +9 -0
  104. apify-3.0.5b8/pyproject.toml +233 -0
  105. apify-3.0.5b8/renovate.json +25 -0
  106. apify-3.0.5b8/src/apify/__init__.py +38 -0
  107. apify-3.0.5b8/src/apify/_actor.py +1314 -0
  108. apify-3.0.5b8/src/apify/_charging.py +394 -0
  109. apify-3.0.5b8/src/apify/_configuration.py +504 -0
  110. apify-3.0.5b8/src/apify/_consts.py +13 -0
  111. {apify-1.3.0 → apify-3.0.5b8}/src/apify/_crypto.py +87 -41
  112. apify-3.0.5b8/src/apify/_models.py +174 -0
  113. apify-3.0.5b8/src/apify/_proxy_configuration.py +317 -0
  114. apify-3.0.5b8/src/apify/_utils.py +91 -0
  115. apify-3.0.5b8/src/apify/events/__init__.py +5 -0
  116. apify-3.0.5b8/src/apify/events/_apify_event_manager.py +140 -0
  117. apify-3.0.5b8/src/apify/events/_types.py +102 -0
  118. apify-3.0.5b8/src/apify/events/py.typed +0 -0
  119. apify-3.0.5b8/src/apify/log.py +32 -0
  120. apify-3.0.5b8/src/apify/py.typed +0 -0
  121. apify-3.0.5b8/src/apify/request_loaders/__init__.py +18 -0
  122. apify-3.0.5b8/src/apify/request_loaders/_apify_request_list.py +162 -0
  123. apify-3.0.5b8/src/apify/request_loaders/py.typed +0 -0
  124. apify-3.0.5b8/src/apify/scrapy/__init__.py +32 -0
  125. apify-3.0.5b8/src/apify/scrapy/_actor_runner.py +26 -0
  126. apify-3.0.5b8/src/apify/scrapy/_async_thread.py +122 -0
  127. apify-3.0.5b8/src/apify/scrapy/_logging_config.py +48 -0
  128. apify-3.0.5b8/src/apify/scrapy/extensions/__init__.py +3 -0
  129. apify-3.0.5b8/src/apify/scrapy/extensions/_httpcache.py +216 -0
  130. apify-3.0.5b8/src/apify/scrapy/middlewares/__init__.py +3 -0
  131. apify-3.0.5b8/src/apify/scrapy/middlewares/apify_proxy.py +145 -0
  132. apify-3.0.5b8/src/apify/scrapy/middlewares/py.typed +0 -0
  133. apify-3.0.5b8/src/apify/scrapy/pipelines/__init__.py +3 -0
  134. apify-1.3.0/src/apify/scrapy/pipelines.py → apify-3.0.5b8/src/apify/scrapy/pipelines/actor_dataset_push.py +16 -9
  135. apify-3.0.5b8/src/apify/scrapy/pipelines/py.typed +0 -0
  136. apify-3.0.5b8/src/apify/scrapy/py.typed +0 -0
  137. apify-3.0.5b8/src/apify/scrapy/requests.py +150 -0
  138. apify-3.0.5b8/src/apify/scrapy/scheduler.py +174 -0
  139. apify-3.0.5b8/src/apify/scrapy/utils.py +53 -0
  140. apify-3.0.5b8/src/apify/storage_clients/__init__.py +12 -0
  141. apify-3.0.5b8/src/apify/storage_clients/_apify/__init__.py +11 -0
  142. apify-3.0.5b8/src/apify/storage_clients/_apify/_dataset_client.py +311 -0
  143. apify-3.0.5b8/src/apify/storage_clients/_apify/_key_value_store_client.py +235 -0
  144. apify-3.0.5b8/src/apify/storage_clients/_apify/_models.py +131 -0
  145. apify-3.0.5b8/src/apify/storage_clients/_apify/_request_queue_client.py +304 -0
  146. apify-3.0.5b8/src/apify/storage_clients/_apify/_request_queue_shared_client.py +533 -0
  147. apify-3.0.5b8/src/apify/storage_clients/_apify/_request_queue_single_client.py +424 -0
  148. apify-3.0.5b8/src/apify/storage_clients/_apify/_storage_client.py +132 -0
  149. apify-3.0.5b8/src/apify/storage_clients/_apify/_utils.py +221 -0
  150. apify-3.0.5b8/src/apify/storage_clients/_apify/py.typed +0 -0
  151. apify-3.0.5b8/src/apify/storage_clients/_file_system/__init__.py +2 -0
  152. apify-3.0.5b8/src/apify/storage_clients/_file_system/_key_value_store_client.py +103 -0
  153. apify-3.0.5b8/src/apify/storage_clients/_file_system/_storage_client.py +41 -0
  154. apify-3.0.5b8/src/apify/storage_clients/_smart_apify/__init__.py +1 -0
  155. apify-3.0.5b8/src/apify/storage_clients/_smart_apify/_storage_client.py +124 -0
  156. apify-3.0.5b8/src/apify/storage_clients/py.typed +0 -0
  157. apify-3.0.5b8/src/apify/storages/__init__.py +3 -0
  158. apify-3.0.5b8/src/apify/storages/py.typed +0 -0
  159. apify-3.0.5b8/tests/integration/README.md +162 -0
  160. apify-3.0.5b8/tests/integration/__init__.py +0 -0
  161. apify-3.0.5b8/tests/integration/_utils.py +17 -0
  162. apify-3.0.5b8/tests/integration/actor/__init__.py +0 -0
  163. apify-3.0.5b8/tests/integration/actor/actor_source_base/Dockerfile +19 -0
  164. apify-3.0.5b8/tests/integration/actor/actor_source_base/requirements.txt +4 -0
  165. apify-3.0.5b8/tests/integration/actor/actor_source_base/server.py +101 -0
  166. apify-3.0.5b8/tests/integration/actor/actor_source_base/src/__init__.py +0 -0
  167. apify-3.0.5b8/tests/integration/actor/actor_source_base/src/__main__.py +20 -0
  168. apify-3.0.5b8/tests/integration/actor/actor_source_base/src/main.py +8 -0
  169. apify-3.0.5b8/tests/integration/actor/conftest.py +322 -0
  170. apify-3.0.5b8/tests/integration/actor/test_actor_api_helpers.py +468 -0
  171. apify-3.0.5b8/tests/integration/actor/test_actor_call_timeouts.py +105 -0
  172. apify-3.0.5b8/tests/integration/actor/test_actor_charge.py +116 -0
  173. apify-3.0.5b8/tests/integration/actor/test_actor_create_proxy_configuration.py +73 -0
  174. apify-3.0.5b8/tests/integration/actor/test_actor_dataset.py +230 -0
  175. apify-3.0.5b8/tests/integration/actor/test_actor_events.py +108 -0
  176. apify-3.0.5b8/tests/integration/actor/test_actor_key_value_store.py +315 -0
  177. apify-3.0.5b8/tests/integration/actor/test_actor_lifecycle.py +162 -0
  178. apify-3.0.5b8/tests/integration/actor/test_actor_log.py +90 -0
  179. apify-3.0.5b8/tests/integration/actor/test_actor_request_queue.py +529 -0
  180. apify-3.0.5b8/tests/integration/actor/test_actor_scrapy.py +49 -0
  181. apify-3.0.5b8/tests/integration/actor/test_apify_storages.py +28 -0
  182. apify-3.0.5b8/tests/integration/actor/test_crawlers_with_storages.py +113 -0
  183. apify-3.0.5b8/tests/integration/actor/test_fixtures.py +100 -0
  184. apify-3.0.5b8/tests/integration/apify_api/__init__.py +0 -0
  185. apify-3.0.5b8/tests/integration/apify_api/conftest.py +70 -0
  186. apify-3.0.5b8/tests/integration/apify_api/test_apify_storages.py +125 -0
  187. apify-3.0.5b8/tests/integration/apify_api/test_request_queue.py +1194 -0
  188. apify-3.0.5b8/tests/integration/conftest.py +28 -0
  189. apify-3.0.5b8/tests/unit/__init__.py +0 -0
  190. apify-3.0.5b8/tests/unit/actor/__init__.py +0 -0
  191. apify-3.0.5b8/tests/unit/actor/test_actor_charge.py +177 -0
  192. apify-3.0.5b8/tests/unit/actor/test_actor_create_proxy_configuration.py +152 -0
  193. apify-3.0.5b8/tests/unit/actor/test_actor_dataset.py +39 -0
  194. apify-3.0.5b8/tests/unit/actor/test_actor_env_helpers.py +133 -0
  195. apify-3.0.5b8/tests/unit/actor/test_actor_helpers.py +176 -0
  196. apify-3.0.5b8/tests/unit/actor/test_actor_key_value_store.py +108 -0
  197. apify-3.0.5b8/tests/unit/actor/test_actor_lifecycle.py +317 -0
  198. apify-3.0.5b8/tests/unit/actor/test_actor_log.py +102 -0
  199. apify-3.0.5b8/tests/unit/actor/test_actor_non_default_instance.py +19 -0
  200. apify-3.0.5b8/tests/unit/actor/test_actor_request_queue.py +28 -0
  201. apify-3.0.5b8/tests/unit/actor/test_configuration.py +243 -0
  202. apify-3.0.5b8/tests/unit/actor/test_request_list.py +242 -0
  203. apify-3.0.5b8/tests/unit/conftest.py +228 -0
  204. apify-3.0.5b8/tests/unit/events/__init__.py +0 -0
  205. apify-3.0.5b8/tests/unit/events/test_apify_event_manager.py +207 -0
  206. apify-3.0.5b8/tests/unit/scrapy/__init__.py +0 -0
  207. apify-3.0.5b8/tests/unit/scrapy/extensions/__init__.py +0 -0
  208. apify-3.0.5b8/tests/unit/scrapy/extensions/test_httpcache.py +71 -0
  209. apify-3.0.5b8/tests/unit/scrapy/middlewares/__init__.py +0 -0
  210. apify-3.0.5b8/tests/unit/scrapy/middlewares/test_apify_proxy.py +154 -0
  211. apify-3.0.5b8/tests/unit/scrapy/pipelines/__init__.py +0 -0
  212. apify-3.0.5b8/tests/unit/scrapy/pipelines/test_actor_dataset_push.py +87 -0
  213. apify-3.0.5b8/tests/unit/scrapy/requests/__init__.py +0 -0
  214. apify-3.0.5b8/tests/unit/scrapy/requests/test_to_apify_request.py +92 -0
  215. apify-3.0.5b8/tests/unit/scrapy/requests/test_to_scrapy_request.py +126 -0
  216. apify-3.0.5b8/tests/unit/scrapy/utils/__init__.py +0 -0
  217. apify-3.0.5b8/tests/unit/scrapy/utils/test_apply_apify_settings.py +59 -0
  218. apify-3.0.5b8/tests/unit/scrapy/utils/test_get_basic_auth_header.py +27 -0
  219. apify-3.0.5b8/tests/unit/storage_clients/__init__.py +0 -0
  220. apify-3.0.5b8/tests/unit/storage_clients/test_apify_request_queue_client.py +38 -0
  221. apify-3.0.5b8/tests/unit/storage_clients/test_file_system.py +92 -0
  222. apify-3.0.5b8/tests/unit/test_apify_storages.py +63 -0
  223. apify-3.0.5b8/tests/unit/test_crypto.py +137 -0
  224. apify-3.0.5b8/tests/unit/test_proxy_configuration.py +582 -0
  225. apify-3.0.5b8/uv.lock +2977 -0
  226. apify-3.0.5b8/website/.eslintrc.json +27 -0
  227. apify-3.0.5b8/website/babel.config.js +3 -0
  228. apify-3.0.5b8/website/build_api_reference.sh +4 -0
  229. apify-3.0.5b8/website/docusaurus.config.js +293 -0
  230. apify-3.0.5b8/website/generate_module_shortcuts.py +59 -0
  231. apify-3.0.5b8/website/package-lock.json +27887 -0
  232. apify-3.0.5b8/website/package.json +55 -0
  233. apify-3.0.5b8/website/roa-loader/index.js +95 -0
  234. apify-3.0.5b8/website/roa-loader/package.json +15 -0
  235. apify-3.0.5b8/website/sidebars.js +52 -0
  236. apify-3.0.5b8/website/src/components/ApiLink.jsx +10 -0
  237. apify-3.0.5b8/website/src/components/Gradients.jsx +20 -0
  238. apify-3.0.5b8/website/src/components/Highlights.jsx +104 -0
  239. apify-3.0.5b8/website/src/components/Highlights.module.css +46 -0
  240. apify-3.0.5b8/website/src/components/RunnableCodeBlock.jsx +42 -0
  241. apify-3.0.5b8/website/src/components/RunnableCodeBlock.module.css +39 -0
  242. apify-3.0.5b8/website/src/css/custom.css +12 -0
  243. apify-3.0.5b8/website/src/pages/home_page_example.py +14 -0
  244. apify-3.0.5b8/website/src/pages/index.js +81 -0
  245. apify-3.0.5b8/website/src/pages/index.module.css +226 -0
  246. apify-3.0.5b8/website/src/theme/DocItem/Content/index.js +6 -0
  247. apify-3.0.5b8/website/static/.nojekyll +0 -0
  248. apify-3.0.5b8/website/static/img/docs-og.png +0 -0
  249. apify-3.0.5b8/website/static/img/guides/redirected_logs_example.webp +0 -0
  250. apify-3.0.5b8/website/tools/docs-prettier.config.js +12 -0
  251. apify-3.0.5b8/website/tools/utils/externalLink.js +40 -0
  252. apify-1.3.0/PKG-INFO +0 -163
  253. apify-1.3.0/README.md +0 -90
  254. apify-1.3.0/pyproject.toml +0 -96
  255. apify-1.3.0/setup.cfg +0 -4
  256. apify-1.3.0/src/apify/__init__.py +0 -9
  257. apify-1.3.0/src/apify/_memory_storage/__init__.py +0 -3
  258. apify-1.3.0/src/apify/_memory_storage/file_storage_utils.py +0 -71
  259. apify-1.3.0/src/apify/_memory_storage/memory_storage_client.py +0 -206
  260. apify-1.3.0/src/apify/_memory_storage/resource_clients/__init__.py +0 -12
  261. apify-1.3.0/src/apify/_memory_storage/resource_clients/base_resource_client.py +0 -129
  262. apify-1.3.0/src/apify/_memory_storage/resource_clients/base_resource_collection_client.py +0 -100
  263. apify-1.3.0/src/apify/_memory_storage/resource_clients/dataset.py +0 -448
  264. apify-1.3.0/src/apify/_memory_storage/resource_clients/dataset_collection.py +0 -44
  265. apify-1.3.0/src/apify/_memory_storage/resource_clients/key_value_store.py +0 -503
  266. apify-1.3.0/src/apify/_memory_storage/resource_clients/key_value_store_collection.py +0 -44
  267. apify-1.3.0/src/apify/_memory_storage/resource_clients/request_queue.py +0 -455
  268. apify-1.3.0/src/apify/_memory_storage/resource_clients/request_queue_collection.py +0 -44
  269. apify-1.3.0/src/apify/_utils.py +0 -392
  270. apify-1.3.0/src/apify/actor.py +0 -1327
  271. apify-1.3.0/src/apify/config.py +0 -124
  272. apify-1.3.0/src/apify/consts.py +0 -65
  273. apify-1.3.0/src/apify/event_manager.py +0 -232
  274. apify-1.3.0/src/apify/log.py +0 -116
  275. apify-1.3.0/src/apify/proxy_configuration.py +0 -351
  276. apify-1.3.0/src/apify/scrapy/__init__.py +0 -4
  277. apify-1.3.0/src/apify/scrapy/middlewares.py +0 -100
  278. apify-1.3.0/src/apify/scrapy/scheduler.py +0 -122
  279. apify-1.3.0/src/apify/scrapy/utils.py +0 -151
  280. apify-1.3.0/src/apify/storages/__init__.py +0 -6
  281. apify-1.3.0/src/apify/storages/base_storage.py +0 -167
  282. apify-1.3.0/src/apify/storages/dataset.py +0 -486
  283. apify-1.3.0/src/apify/storages/key_value_store.py +0 -221
  284. apify-1.3.0/src/apify/storages/request_queue.py +0 -527
  285. apify-1.3.0/src/apify/storages/storage_client_manager.py +0 -65
  286. apify-1.3.0/src/apify.egg-info/PKG-INFO +0 -163
  287. apify-1.3.0/src/apify.egg-info/SOURCES.txt +0 -41
  288. apify-1.3.0/src/apify.egg-info/dependency_links.txt +0 -1
  289. apify-1.3.0/src/apify.egg-info/requires.txt +0 -50
  290. apify-1.3.0/src/apify.egg-info/top_level.txt +0 -1
  291. {apify-1.3.0 → apify-3.0.5b8}/LICENSE +0 -0
  292. /apify-1.3.0/src/apify/py.typed → /apify-3.0.5b8/docs/01_overview/code/actor_structure/__init__.py +0 -0
@@ -0,0 +1,15 @@
1
+ root = true
2
+
3
+ [*]
4
+ indent_style = space
5
+ indent_size = 4
6
+ charset = utf-8
7
+ trim_trailing_whitespace = true
8
+ insert_final_newline = true
9
+ end_of_line = lf
10
+
11
+ [Makefile]
12
+ indent_style = tab
13
+
14
+ [{*.yaml, *.yml}]
15
+ indent_size = 2
@@ -0,0 +1,4 @@
1
+ # Documentation codeowner
2
+
3
+ /docs/*.md @TC-MO
4
+ /docs/*.mdx @TC-MO
@@ -0,0 +1,87 @@
1
+ name: Build and deploy docs
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - master
7
+ workflow_dispatch:
8
+
9
+ env:
10
+ NODE_VERSION: 22
11
+ PYTHON_VERSION: 3.13
12
+
13
+ jobs:
14
+ build_and_deploy_docs:
15
+ environment:
16
+ name: github-pages
17
+ permissions:
18
+ contents: write
19
+ pages: write
20
+ id-token: write
21
+ runs-on: ubuntu-latest
22
+
23
+ steps:
24
+ - name: Checkout repository
25
+ uses: actions/checkout@v5
26
+ with:
27
+ token: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}
28
+
29
+ - name: Set up Node
30
+ uses: actions/setup-node@v6
31
+ with:
32
+ node-version: ${{ env.NODE_VERSION }}
33
+ cache: npm
34
+ cache-dependency-path: website/package-lock.json
35
+
36
+ - name: Install Node dependencies
37
+ run: |
38
+ npm install
39
+ npm update @apify/docs-theme
40
+ working-directory: ./website
41
+
42
+ # We do this as early as possible to prevent conflicts if someone else would push something in the meantime
43
+ - name: Commit the updated package.json and lockfile
44
+ run: |
45
+ git config user.name 'GitHub Actions'
46
+ git config user.email 'github-actions[bot]@users.noreply.github.com'
47
+ git add website/package.json
48
+ git add website/package-lock.json
49
+ git diff-index --quiet HEAD || git commit -m 'chore: Automatic docs theme update [skip ci]' || true
50
+ git push
51
+
52
+ - name: Set up Python
53
+ uses: actions/setup-python@v6
54
+ with:
55
+ python-version: ${{ env.PYTHON_VERSION }}
56
+
57
+ - name: Set up uv package manager
58
+ uses: astral-sh/setup-uv@v7
59
+ with:
60
+ python-version: ${{ env.PYTHON_VERSION }}
61
+
62
+ - name: Install Python dependencies
63
+ run: make install-dev
64
+
65
+ - name: Build generated API reference
66
+ run: make build-api-reference
67
+
68
+ - name: Build Docusaurus docs
69
+ run: make build-docs
70
+ env:
71
+ APIFY_SIGNING_TOKEN: ${{ secrets.APIFY_SIGNING_TOKEN }}
72
+
73
+ - name: Set up GitHub Pages
74
+ uses: actions/configure-pages@v5
75
+
76
+ - name: Upload GitHub Pages artifact
77
+ uses: actions/upload-pages-artifact@v4
78
+ with:
79
+ path: ./website/build
80
+
81
+ - name: Deploy artifact to GitHub Pages
82
+ uses: actions/deploy-pages@v4
83
+
84
+ - name: Invalidate CloudFront cache
85
+ run: gh workflow run invalidate.yaml --repo apify/apify-docs-private
86
+ env:
87
+ GITHUB_TOKEN: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}
@@ -0,0 +1,14 @@
1
+ name: Check PR title
2
+
3
+ on:
4
+ pull_request_target:
5
+ types: [opened, edited, synchronize]
6
+
7
+ jobs:
8
+ check_pr_title:
9
+ name: Check PR title
10
+ runs-on: ubuntu-latest
11
+ steps:
12
+ - uses: amannn/action-semantic-pull-request@v5.5.3
13
+ env:
14
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -0,0 +1,90 @@
1
+ name: Create a pre-release
2
+
3
+ on:
4
+ # Trigger a beta version release (pre-release) on push to the master branch.
5
+ push:
6
+ branches:
7
+ - master
8
+ tags-ignore:
9
+ - "**" # Ignore all tags to prevent duplicate builds when tags are pushed.
10
+
11
+ # Or it can be triggered manually.
12
+ workflow_dispatch:
13
+
14
+ concurrency:
15
+ group: release
16
+ cancel-in-progress: false
17
+
18
+ jobs:
19
+ release_metadata:
20
+ if: "!startsWith(github.event.head_commit.message, 'docs') && !startsWith(github.event.head_commit.message, 'ci') && startsWith(github.repository, 'apify/')"
21
+ name: Prepare release metadata
22
+ runs-on: ubuntu-latest
23
+ outputs:
24
+ version_number: ${{ steps.release_metadata.outputs.version_number }}
25
+ tag_name: ${{ steps.release_metadata.outputs.tag_name }}
26
+ changelog: ${{ steps.release_metadata.outputs.changelog }}
27
+ steps:
28
+ - uses: apify/workflows/git-cliff-release@main
29
+ id: release_metadata
30
+ name: Prepare release metadata
31
+ with:
32
+ release_type: prerelease
33
+ existing_changelog_path: CHANGELOG.md
34
+
35
+ lint_check:
36
+ name: Lint check
37
+ uses: apify/workflows/.github/workflows/python_lint_check.yaml@main
38
+ with:
39
+ python-versions: '["3.10", "3.11", "3.12", "3.13"]'
40
+
41
+ type_check:
42
+ name: Type check
43
+ uses: apify/workflows/.github/workflows/python_type_check.yaml@main
44
+ with:
45
+ python-versions: '["3.10", "3.11", "3.12", "3.13"]'
46
+
47
+ unit_tests:
48
+ name: Unit tests
49
+ uses: apify/workflows/.github/workflows/python_unit_tests.yaml@main
50
+ with:
51
+ python-versions: '["3.10", "3.11", "3.12", "3.13"]'
52
+
53
+ integration_tests:
54
+ name: Integration tests
55
+ uses: apify/workflows/.github/workflows/python_integration_tests.yaml@main
56
+ secrets: inherit
57
+ with:
58
+ python-versions: '["3.10", "3.13"]'
59
+
60
+ update_changelog:
61
+ name: Update changelog
62
+ needs: [release_metadata, lint_check, type_check, unit_tests, integration_tests]
63
+ uses: apify/workflows/.github/workflows/python_bump_and_update_changelog.yaml@main
64
+ with:
65
+ version_number: ${{ needs.release_metadata.outputs.version_number }}
66
+ changelog: ${{ needs.release_metadata.outputs.changelog }}
67
+ secrets:
68
+ APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}
69
+
70
+ publish_to_pypi:
71
+ name: Publish to PyPI
72
+ needs: [release_metadata, update_changelog]
73
+ runs-on: ubuntu-latest
74
+ permissions:
75
+ contents: write
76
+ id-token: write # Required for OIDC authentication.
77
+ environment:
78
+ name: pypi
79
+ url: https://pypi.org/project/apify
80
+ steps:
81
+ - name: Prepare distribution
82
+ uses: apify/workflows/prepare-pypi-distribution@main
83
+ with:
84
+ package_name: apify
85
+ is_prerelease: "yes"
86
+ version_number: ${{ needs.release_metadata.outputs.version_number }}
87
+ ref: ${{ needs.update_changelog.outputs.changelog_commitish }}
88
+ # Publishes the package to PyPI using PyPA official GitHub action with OIDC authentication.
89
+ - name: Publish package to PyPI
90
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,124 @@
1
+ name: Create a release
2
+
3
+ on:
4
+ # Trigger a stable version release via GitHub's UI, with the ability to specify the type of release.
5
+ workflow_dispatch:
6
+ inputs:
7
+ release_type:
8
+ description: Release type
9
+ required: true
10
+ type: choice
11
+ default: auto
12
+ options:
13
+ - auto
14
+ - custom
15
+ - patch
16
+ - minor
17
+ - major
18
+ custom_version:
19
+ description: The custom version to bump to (only for "custom" type)
20
+ required: false
21
+ type: string
22
+ default: ""
23
+
24
+ concurrency:
25
+ group: release
26
+ cancel-in-progress: false
27
+
28
+ jobs:
29
+ release_metadata:
30
+ name: Prepare release metadata
31
+ runs-on: ubuntu-latest
32
+ outputs:
33
+ version_number: ${{ steps.release_metadata.outputs.version_number }}
34
+ tag_name: ${{ steps.release_metadata.outputs.tag_name }}
35
+ changelog: ${{ steps.release_metadata.outputs.changelog }}
36
+ release_notes: ${{ steps.release_metadata.outputs.release_notes }}
37
+ steps:
38
+ - uses: apify/workflows/git-cliff-release@main
39
+ name: Prepare release metadata
40
+ id: release_metadata
41
+ with:
42
+ release_type: ${{ inputs.release_type }}
43
+ custom_version: ${{ inputs.custom_version }}
44
+ existing_changelog_path: CHANGELOG.md
45
+
46
+ lint_check:
47
+ name: Lint check
48
+ uses: apify/workflows/.github/workflows/python_lint_check.yaml@main
49
+ with:
50
+ python-versions: '["3.10", "3.11", "3.12", "3.13"]'
51
+
52
+ type_check:
53
+ name: Type check
54
+ uses: apify/workflows/.github/workflows/python_type_check.yaml@main
55
+ with:
56
+ python-versions: '["3.10", "3.11", "3.12", "3.13"]'
57
+
58
+ unit_tests:
59
+ name: Unit tests
60
+ uses: apify/workflows/.github/workflows/python_unit_tests.yaml@main
61
+ with:
62
+ python-versions: '["3.10", "3.11", "3.12", "3.13"]'
63
+
64
+ update_changelog:
65
+ name: Update changelog
66
+ needs: [release_metadata, lint_check, type_check, unit_tests]
67
+ uses: apify/workflows/.github/workflows/python_bump_and_update_changelog.yaml@main
68
+ with:
69
+ version_number: ${{ needs.release_metadata.outputs.version_number }}
70
+ changelog: ${{ needs.release_metadata.outputs.changelog }}
71
+ secrets:
72
+ APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}
73
+
74
+ create_github_release:
75
+ name: Create github release
76
+ needs: [release_metadata, update_changelog]
77
+ runs-on: ubuntu-latest
78
+ env:
79
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
80
+ steps:
81
+ - name: Create release
82
+ uses: softprops/action-gh-release@v2
83
+ with:
84
+ tag_name: ${{ needs.release_metadata.outputs.tag_name }}
85
+ name: ${{ needs.release_metadata.outputs.version_number }}
86
+ target_commitish: ${{ needs.update_changelog.outputs.changelog_commitish }}
87
+ body: ${{ needs.release_metadata.outputs.release_notes }}
88
+
89
+ publish_to_pypi:
90
+ name: Publish to PyPI
91
+ needs: [release_metadata, update_changelog]
92
+ runs-on: ubuntu-latest
93
+ permissions:
94
+ contents: write
95
+ id-token: write # Required for OIDC authentication.
96
+ environment:
97
+ name: pypi
98
+ url: https://pypi.org/project/apify
99
+ steps:
100
+ - name: Prepare distribution
101
+ uses: apify/workflows/prepare-pypi-distribution@main
102
+ with:
103
+ package_name: apify
104
+ is_prerelease: ""
105
+ version_number: ${{ needs.release_metadata.outputs.version_number }}
106
+ ref: ${{ needs.update_changelog.outputs.changelog_commitish }}
107
+ # Publishes the package to PyPI using PyPA official GitHub action with OIDC authentication.
108
+ - name: Publish package to PyPI
109
+ uses: pypa/gh-action-pypi-publish@release/v1
110
+
111
+ trigger_docker_build:
112
+ name: Trigger Docker image build
113
+ needs: [release_metadata, update_changelog]
114
+ runs-on: ubuntu-latest
115
+ steps:
116
+ - # Trigger building the Python Docker images in apify/apify-actor-docker repo
117
+ name: Trigger Docker image build
118
+ run: |
119
+ gh api -X POST "/repos/apify/apify-actor-docker/dispatches" \
120
+ -F event_type=build-python-images \
121
+ -F client_payload[release_tag]=latest \
122
+ -F client_payload[apify_version]=${{ needs.release_metadata.outputs.version_number }}
123
+ env:
124
+ GH_TOKEN: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}
@@ -0,0 +1,43 @@
1
+ name: Run code checks
2
+
3
+ on:
4
+ # Trigger code checks on opening a new pull request.
5
+ # Secrets are only made available to the integration tests job, with a manual approval
6
+ # step required for PRs from forks. This prevents their potential exposure.
7
+ pull_request:
8
+
9
+ # Trigger for pushing to the master branch is handled by the pre-release workflow.
10
+
11
+ # It should also be possible to trigger checks manually
12
+ workflow_dispatch:
13
+
14
+ jobs:
15
+ lint_check:
16
+ name: Lint check
17
+ uses: apify/workflows/.github/workflows/python_lint_check.yaml@main
18
+ with:
19
+ python-versions: '["3.10", "3.11", "3.12", "3.13"]'
20
+
21
+ type_check:
22
+ name: Type check
23
+ uses: apify/workflows/.github/workflows/python_type_check.yaml@main
24
+ with:
25
+ python-versions: '["3.10", "3.11", "3.12", "3.13"]'
26
+
27
+ unit_tests:
28
+ name: Unit tests
29
+ uses: apify/workflows/.github/workflows/python_unit_tests.yaml@main
30
+ with:
31
+ python-versions: '["3.10", "3.11", "3.12", "3.13"]'
32
+
33
+ docs_check:
34
+ name: Docs check
35
+ uses: apify/workflows/.github/workflows/python_docs_check.yaml@main
36
+ secrets: inherit
37
+
38
+ integration_tests:
39
+ name: Integration tests
40
+ uses: apify/workflows/.github/workflows/python_integration_tests.yaml@main
41
+ secrets: inherit
42
+ with:
43
+ python-versions: '["3.10", "3.13"]'
@@ -0,0 +1,25 @@
1
+ name: Update new issue
2
+
3
+ on:
4
+ issues:
5
+ types:
6
+ - opened
7
+
8
+ jobs:
9
+ label_issues:
10
+ name: Label issues
11
+ runs-on: ubuntu-latest
12
+ permissions:
13
+ issues: write
14
+
15
+ steps:
16
+ # Add the "t-tooling" label to all new issues
17
+ - uses: actions/github-script@v8
18
+ with:
19
+ script: |
20
+ github.rest.issues.addLabels({
21
+ issue_number: context.issue.number,
22
+ owner: context.repo.owner,
23
+ repo: context.repo.repo,
24
+ labels: ["t-tooling"]
25
+ })
@@ -0,0 +1,49 @@
1
+ # Cache
2
+ __pycache__
3
+ .mypy_cache
4
+ .pytest_cache
5
+ .ruff_cache
6
+
7
+ # Virtual envs
8
+ .venv
9
+ .direnv
10
+ .envrc
11
+ .python-version
12
+
13
+ # Mise
14
+ mise.toml
15
+ .mise.toml
16
+
17
+ # Egg and build artifacts
18
+ *.egg-info/
19
+ *.egg
20
+ dist/
21
+ build/
22
+
23
+ # Coverage reports
24
+ .coverage*
25
+ htmlcov
26
+
27
+ # IDE, editors
28
+ .vscode
29
+ .idea
30
+ .DS_Store
31
+ .nvim.lua
32
+ Session.vim
33
+
34
+ # Docs
35
+ docs/changelog.md
36
+
37
+ # Website build artifacts, node dependencies
38
+ website/build
39
+ website/node_modules
40
+ website/.yarn
41
+ website/.docusaurus
42
+ website/api-typedoc-generated.json
43
+ website/apify-shared-docspec-dump.jsonl
44
+ website/docspec-dump.jsonl
45
+ website/module_shortcuts.json
46
+ website/typedoc-types*
47
+
48
+ # Default directory for memory storage
49
+ storage/
@@ -0,0 +1,5 @@
1
+ default: true
2
+ line-length:
3
+ line_length: 150
4
+ ul-style: dash
5
+ no-inline-html: false
@@ -0,0 +1,14 @@
1
+ repos:
2
+ - repo: local
3
+ hooks:
4
+ - id: lint-check
5
+ name: Lint check
6
+ entry: make lint
7
+ language: system
8
+ pass_filenames: false
9
+
10
+ - id: type-check
11
+ name: Type check
12
+ entry: make type-check
13
+ language: system
14
+ pass_filenames: false