browser-tools 0.3.0__tar.gz → 0.4.1__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 (206) hide show
  1. {browser_tools-0.3.0 → browser_tools-0.4.1}/.gitignore +3 -0
  2. browser_tools-0.4.1/PKG-INFO +251 -0
  3. browser_tools-0.4.1/README.md +212 -0
  4. {browser_tools-0.3.0 → browser_tools-0.4.1}/pyproject.toml +2 -4
  5. browser_tools-0.4.1/src/browser_tools/GUIDE.txt +505 -0
  6. browser_tools-0.4.1/src/browser_tools/__init__.py +59 -0
  7. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/cdp_client.py +124 -3
  8. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/cdp_handler.py +82 -19
  9. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/cli.py +335 -54
  10. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/attach.py +2 -2
  11. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/cdp_client.py +12 -0
  12. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/connection.py +10 -0
  13. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/launcher.py +22 -7
  14. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/registry.py +4 -4
  15. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/supervisor.py +143 -8
  16. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/curated.py +229 -87
  17. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/detect_interstitial.js +31 -8
  18. browser_tools-0.4.1/src/browser_tools/endpoint.py +166 -0
  19. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/events.py +152 -7
  20. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/extras.py +2 -2
  21. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/interstitial.py +124 -25
  22. browser_tools-0.4.1/src/browser_tools/lifecycle.py +1530 -0
  23. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/list_verbs.py +9 -6
  24. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/native_interaction.py +98 -46
  25. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/native_snapshot.py +170 -44
  26. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/one_shot.py +33 -7
  27. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/passthrough.py +71 -25
  28. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/process_utils.py +22 -44
  29. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/profiler.py +3 -3
  30. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/screencast.py +57 -10
  31. browser_tools-0.4.1/src/browser_tools/tool_registry.py +70 -0
  32. browser_tools-0.4.1/src/browser_tools/usage.py +23 -0
  33. browser_tools-0.4.1/tests/conftest.py +41 -0
  34. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/CORPUS.md +58 -68
  35. {browser_tools-0.3.0/src/browser_tools → browser_tools-0.4.1/tests/parity}/camoufox_session.py +11 -3
  36. {browser_tools-0.3.0/tests → browser_tools-0.4.1/tests/parity}/conftest.py +15 -26
  37. browser_tools-0.3.0/src/browser_tools/mcp_broker.py → browser_tools-0.4.1/tests/parity/node_broker.py +17 -12
  38. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/parity_engines.py +73 -7
  39. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/run_baseline.py +1 -1
  40. browser_tools-0.3.0/tests/test_camoufox.py → browser_tools-0.4.1/tests/parity/test_camoufox_session.py +28 -3
  41. {browser_tools-0.3.0/tests → browser_tools-0.4.1/tests/parity}/test_e2e_camoufox.py +1 -1
  42. browser_tools-0.4.1/tests/parity/test_node_broker.py +249 -0
  43. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/test_parity_baseline.py +1 -1
  44. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/test_parity_engine.py +16 -3
  45. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/test_parity_gate.py +23 -13
  46. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/test_parity_native_interaction.py +51 -9
  47. browser_tools-0.4.1/tests/test_async_discovery.py +196 -0
  48. browser_tools-0.4.1/tests/test_cli_grammar.py +331 -0
  49. browser_tools-0.4.1/tests/test_cli_surface.py +178 -0
  50. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_core_launcher.py +8 -5
  51. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_curated_verbs.py +123 -22
  52. browser_tools-0.4.1/tests/test_detached_tasks.py +185 -0
  53. browser_tools-0.4.1/tests/test_diagnostics_name_real_verbs.py +200 -0
  54. browser_tools-0.4.1/tests/test_endpoint.py +489 -0
  55. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_events.py +8 -2
  56. browser_tools-0.4.1/tests/test_guide.py +445 -0
  57. browser_tools-0.4.1/tests/test_interaction_targeting.py +170 -0
  58. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_interstitial.py +183 -2
  59. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_list_verbs.py +8 -2
  60. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_native_backend.py +9 -4
  61. browser_tools-0.4.1/tests/test_native_interaction.py +392 -0
  62. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_native_snapshot.py +206 -90
  63. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_new_tools.py +6 -2
  64. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_one_shot.py +15 -9
  65. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_packaging.py +98 -14
  66. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_passthrough.py +7 -4
  67. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_profile_liveness.py +6 -2
  68. browser_tools-0.4.1/tests/test_profile_path_hardening.py +243 -0
  69. browser_tools-0.4.1/tests/test_profile_root_move.py +424 -0
  70. browser_tools-0.4.1/tests/test_profile_verbs.py +322 -0
  71. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_profiler.py +2 -2
  72. browser_tools-0.4.1/tests/test_retained_contracts.py +171 -0
  73. browser_tools-0.4.1/tests/test_stop_target.py +323 -0
  74. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_supervisor_never_pauses.py +4 -1
  75. browser_tools-0.4.1/tests/test_supervisor_profile_preservation.py +152 -0
  76. browser_tools-0.4.1/tests/test_supervisor_visibility.py +223 -0
  77. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_window_marking.py +7 -6
  78. browser_tools-0.3.0/PKG-INFO +0 -203
  79. browser_tools-0.3.0/README.md +0 -164
  80. browser_tools-0.3.0/src/browser_tools/__init__.py +0 -66
  81. browser_tools-0.3.0/src/browser_tools/attach_chrome.sh +0 -124
  82. browser_tools-0.3.0/src/browser_tools/automation_backend.py +0 -125
  83. browser_tools-0.3.0/src/browser_tools/browser_session.py +0 -958
  84. browser_tools-0.3.0/src/browser_tools/browser_state.py +0 -224
  85. browser_tools-0.3.0/src/browser_tools/chrome_config.py +0 -49
  86. browser_tools-0.3.0/src/browser_tools/chrome_utils.py +0 -185
  87. browser_tools-0.3.0/src/browser_tools/core/session.py +0 -241
  88. browser_tools-0.3.0/src/browser_tools/daemon_client.py +0 -136
  89. browser_tools-0.3.0/src/browser_tools/daemon_supervisor.py +0 -405
  90. browser_tools-0.3.0/src/browser_tools/lifecycle.py +0 -913
  91. browser_tools-0.3.0/src/browser_tools/live_chrome.py +0 -107
  92. browser_tools-0.3.0/src/browser_tools/mcp_daemon.py +0 -591
  93. browser_tools-0.3.0/src/browser_tools/mcp_session.py +0 -204
  94. browser_tools-0.3.0/src/browser_tools/page_selection.py +0 -253
  95. browser_tools-0.3.0/src/browser_tools/persistent-session-template.mjs +0 -132
  96. browser_tools-0.3.0/src/browser_tools/persistent_browser.py +0 -823
  97. browser_tools-0.3.0/src/browser_tools/profile_catalog.py +0 -220
  98. browser_tools-0.3.0/src/browser_tools/project_identity.py +0 -83
  99. browser_tools-0.3.0/src/browser_tools/session_layout.py +0 -151
  100. browser_tools-0.3.0/src/browser_tools/session_reaper.py +0 -193
  101. browser_tools-0.3.0/src/browser_tools/session_store.py +0 -343
  102. browser_tools-0.3.0/src/browser_tools/tool_registry.py +0 -140
  103. browser_tools-0.3.0/tests/parity/conftest.py +0 -17
  104. browser_tools-0.3.0/tests/test_attach_browser.py +0 -775
  105. browser_tools-0.3.0/tests/test_auth_identity.py +0 -271
  106. browser_tools-0.3.0/tests/test_automation_backend.py +0 -152
  107. browser_tools-0.3.0/tests/test_browser_tools.py +0 -98
  108. browser_tools-0.3.0/tests/test_close_and_real_mode.py +0 -576
  109. browser_tools-0.3.0/tests/test_daemonless_cli.py +0 -111
  110. browser_tools-0.3.0/tests/test_dispatch.py +0 -237
  111. browser_tools-0.3.0/tests/test_e2e_backend_seam.py +0 -73
  112. browser_tools-0.3.0/tests/test_inspect_mode.py +0 -135
  113. browser_tools-0.3.0/tests/test_live_chrome.py +0 -122
  114. browser_tools-0.3.0/tests/test_mcp_daemon.py +0 -468
  115. browser_tools-0.3.0/tests/test_mcp_surface_contract.py +0 -1082
  116. browser_tools-0.3.0/tests/test_native_interaction.py +0 -336
  117. browser_tools-0.3.0/tests/test_page_selection.py +0 -209
  118. browser_tools-0.3.0/tests/test_persistent_browser.py +0 -507
  119. browser_tools-0.3.0/tests/test_profiles.py +0 -180
  120. browser_tools-0.3.0/tests/test_session_dispatch.py +0 -251
  121. browser_tools-0.3.0/tests/test_session_lifecycle.py +0 -270
  122. {browser_tools-0.3.0 → browser_tools-0.4.1}/LICENSE +0 -0
  123. {browser_tools-0.3.0 → browser_tools-0.4.1}/NOTICE +0 -0
  124. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/camoufox_runner.py +0 -0
  125. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/cdp_constants.py +0 -0
  126. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/__init__.py +0 -0
  127. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/__init__.py +0 -0
  128. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/accessibility.py +0 -0
  129. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/animation.py +0 -0
  130. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/audits.py +0 -0
  131. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/autofill.py +0 -0
  132. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/background_service.py +0 -0
  133. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/bluetooth_emulation.py +0 -0
  134. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/browser.py +0 -0
  135. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/cache_storage.py +0 -0
  136. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/cast.py +0 -0
  137. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/console.py +0 -0
  138. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/css.py +0 -0
  139. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/debugger.py +0 -0
  140. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/device_access.py +0 -0
  141. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/device_orientation.py +0 -0
  142. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/dom.py +0 -0
  143. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/dom_debugger.py +0 -0
  144. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/dom_snapshot.py +0 -0
  145. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/dom_storage.py +0 -0
  146. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/emulation.py +0 -0
  147. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/event_breakpoints.py +0 -0
  148. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/extensions.py +0 -0
  149. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/fed_cm.py +0 -0
  150. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/fetch.py +0 -0
  151. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/file_system.py +0 -0
  152. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/headless_experimental.py +0 -0
  153. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/heap_profiler.py +0 -0
  154. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/indexed_db.py +0 -0
  155. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/input.py +0 -0
  156. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/inspector.py +0 -0
  157. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/io.py +0 -0
  158. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/layer_tree.py +0 -0
  159. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/log.py +0 -0
  160. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/media.py +0 -0
  161. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/memory.py +0 -0
  162. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/network.py +0 -0
  163. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/overlay.py +0 -0
  164. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/page.py +0 -0
  165. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/performance.py +0 -0
  166. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/performance_timeline.py +0 -0
  167. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/preload.py +0 -0
  168. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/profiler.py +0 -0
  169. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/pwa.py +0 -0
  170. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/runtime.py +0 -0
  171. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/schema.py +0 -0
  172. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/security.py +0 -0
  173. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/service_worker.py +0 -0
  174. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/smart_card_emulation.py +0 -0
  175. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/storage.py +0 -0
  176. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/system_info.py +0 -0
  177. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/target.py +0 -0
  178. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/tethering.py +0 -0
  179. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/tracing.py +0 -0
  180. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/web_audio.py +0 -0
  181. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/domains/web_authn.py +0 -0
  182. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/errors.py +0 -0
  183. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/fingerprint.py +0 -0
  184. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/instance_status.py +0 -0
  185. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/protocol.py +0 -0
  186. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/core/utils.py +0 -0
  187. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/frame_manager.py +0 -0
  188. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/mcp_response.py +0 -0
  189. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/screenshot_utils.py +0 -0
  190. {browser_tools-0.3.0 → browser_tools-0.4.1}/src/browser_tools/user_settings.py +0 -0
  191. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/fixtures/dynamic.html +0 -0
  192. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/fixtures/form.html +0 -0
  193. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/fixtures/iframe.html +0 -0
  194. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/fixtures/iframe_child.html +0 -0
  195. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/fixtures/plain.html +0 -0
  196. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/fixtures/shadow.html +0 -0
  197. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/live_chromium.py +0 -0
  198. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/parity_comparison.py +0 -0
  199. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/parity_corpus.py +0 -0
  200. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/test_parity_corpus.py +0 -0
  201. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/test_parity_native.py +0 -0
  202. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/parity/test_parity_operator.py +0 -0
  203. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_cdp_client.py +0 -0
  204. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_cli_lifecycle.py +0 -0
  205. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_frame_manager.py +0 -0
  206. {browser_tools-0.3.0 → browser_tools-0.4.1}/tests/test_supervisor_document_liveness.py +0 -0
@@ -30,3 +30,6 @@ Thumbs.db
30
30
 
31
31
  # Agent worktrees (transient)
32
32
  .claude/worktrees/
33
+
34
+ # Task scratch: ledgers, briefs, delegation reports, repro scripts.
35
+ .scratch/
@@ -0,0 +1,251 @@
1
+ Metadata-Version: 2.5
2
+ Name: browser-tools
3
+ Version: 0.4.1
4
+ Summary: Browser automation, debugging, and anti-detect browsing CLI
5
+ Project-URL: Homepage, https://github.com/dungle-scrubs/browser-tools
6
+ Project-URL: Repository, https://github.com/dungle-scrubs/browser-tools
7
+ Project-URL: Issues, https://github.com/dungle-scrubs/browser-tools/issues
8
+ Project-URL: Changelog, https://github.com/dungle-scrubs/browser-tools/blob/main/CHANGELOG.md
9
+ License-Expression: MIT
10
+ License-File: LICENSE
11
+ License-File: NOTICE
12
+ Keywords: anti-detect,browser-automation,camoufox,cdp,chrome-devtools,playwright,web-scraping
13
+ Classifier: Development Status :: 3 - Alpha
14
+ Classifier: Environment :: Console
15
+ Classifier: Intended Audience :: Developers
16
+ Classifier: License :: OSI Approved :: MIT License
17
+ Classifier: Operating System :: MacOS
18
+ Classifier: Operating System :: POSIX :: Linux
19
+ Classifier: Programming Language :: Python :: 3
20
+ Classifier: Programming Language :: Python :: 3 :: Only
21
+ Classifier: Programming Language :: Python :: 3.13
22
+ Classifier: Topic :: Internet :: WWW/HTTP :: Browsers
23
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
24
+ Classifier: Topic :: Software Development :: Testing
25
+ Classifier: Topic :: Utilities
26
+ Classifier: Typing :: Typed
27
+ Requires-Python: >=3.13
28
+ Requires-Dist: websockets>=16.0
29
+ Provides-Extra: all
30
+ Requires-Dist: aiohttp>=3.14.1; extra == 'all'
31
+ Requires-Dist: camoufox[geoip]>=0.4.11; extra == 'all'
32
+ Requires-Dist: pillow>=10.0.0; extra == 'all'
33
+ Provides-Extra: camoufox
34
+ Requires-Dist: aiohttp>=3.14.1; extra == 'camoufox'
35
+ Requires-Dist: camoufox[geoip]>=0.4.11; extra == 'camoufox'
36
+ Provides-Extra: profiling
37
+ Requires-Dist: pillow>=10.0.0; extra == 'profiling'
38
+ Description-Content-Type: text/markdown
39
+
40
+ # Browser Tools
41
+
42
+ [![CI](https://github.com/dungle-scrubs/browser-tools/actions/workflows/ci.yml/badge.svg)](https://github.com/dungle-scrubs/browser-tools/actions/workflows/ci.yml)
43
+ [![Python 3.13+](https://img.shields.io/badge/python-3.13+-blue.svg)](https://www.python.org/downloads/)
44
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
45
+ [![Code style: ruff](https://img.shields.io/badge/code%20style-ruff-000000.svg)](https://docs.astral.sh/ruff/)
46
+
47
+ Browser automation, debugging, and anti-detect browsing CLI. Provides:
48
+
49
+ - **Raw CDP passthrough** - Any `Domain.method` goes straight to the running
50
+ browser, with protocol help read live from it
51
+ - **Snapshot-based page automation** - Accessibility-tree snapshots and UID
52
+ interaction (`snapshot`, `click --uid`, `fill --uid`), in Python over CDP
53
+ - **Named browser instances** - Long-lived Chrome with a registry and named
54
+ profiles that keep a login across restarts
55
+ - **External browsers** - `--endpoint http://127.0.0.1:9222` drives a browser
56
+ you already have open and logged in, writing nothing to the registry
57
+ - **Frame-aware tools** - Iframe/CDP frame tree management, execution context
58
+ resolution, and storage inspection
59
+ - **Interstitial detection** - Multi-signal heuristic detection for Cloudflare,
60
+ DataDome, Akamai, PerimeterX, Imperva, AWS WAF, and other challenge pages
61
+ - **Camoufox anti-detect browsing** - Fingerprint-injected Firefox-based
62
+ browsing for bot-protected sites
63
+ - **Anything else CDP can do** - File upload, viewport emulation, cookies,
64
+ PDF export and page management have no curated verb and need none; `bt
65
+ guide` has a worked example of each
66
+ - **CPU profiling** - `browser-tools-profiler`, a second command installed
67
+ alongside `bt`, with timed capture and threshold-triggered capture
68
+
69
+ ## Quick Start
70
+
71
+ ### Installation
72
+
73
+ ```bash
74
+ # Using uv (recommended)
75
+ uv tool install browser-tools
76
+
77
+ # Or with pip
78
+ pip install browser-tools
79
+ ```
80
+
81
+ ### Usage
82
+
83
+ ```bash
84
+ # Run the CLI (`bt` is an alias for `browser-tools`)
85
+ bt --help
86
+
87
+ # Launch a browser. It is registered by name and outlives this command, so
88
+ # later verbs drive the same Chrome and share its page and login state.
89
+ bt launch
90
+
91
+ # Navigate through the raw CDP passthrough, then read the page.
92
+ bt Page.navigate '{"url": "https://example.com"}'
93
+ bt snapshot
94
+
95
+ # Interact by UID from that snapshot.
96
+ bt click --uid 1-13
97
+
98
+ # When the page is blocking, ask directly.
99
+ bt detect
100
+
101
+ bt status # registered instances and their page targets
102
+ bt stop # close the browser and retire its registry entry
103
+ ```
104
+
105
+ Omit `INSTANCE` while exactly one instance is running; with several, every verb
106
+ names the candidates rather than guessing. `bt help Domain.method` reads the
107
+ protocol schema from the running browser.
108
+
109
+ **`bt guide` is the manual.** It is the complete CLI surface -- every verb,
110
+ every refusal with its exit code, the login walkthrough, the UID rule, and the
111
+ `--endpoint` rules -- and reading it is enough to drive a browser with this
112
+ tool. A test fails the build when a verb has no entry in it.
113
+
114
+ To drive a browser you started yourself, pass its debugging port instead of an
115
+ instance name:
116
+
117
+ ```bash
118
+ # Chrome started with --remote-debugging-port=9222, already logged in.
119
+ bt snapshot --endpoint http://127.0.0.1:9222
120
+ bt click --uid 0BDAEF756714-14 --endpoint http://127.0.0.1:9222
121
+ ```
122
+
123
+ Nothing is written to the registry, so `status` does not list it and `stop` and
124
+ `cleanup` cannot reach it -- which is what keeps them away from your real Chrome
125
+ profile directory. Only `127.0.0.1` and `::1` are accepted; forward a remote
126
+ browser with `ssh -L 9222:127.0.0.1:9222 <host>`. `Browser.close` and
127
+ `Browser.crash` are refused over `--endpoint`.
128
+
129
+ ### Development setup
130
+
131
+ ```bash
132
+ # Clone and install in editable mode
133
+ git clone https://github.com/dungle-scrubs/browser-tools.git
134
+ cd browser-tools
135
+ uv sync
136
+ ```
137
+
138
+ Runtime requirements:
139
+
140
+ - **Chrome Canary** by default (the default channel is `canary`). Use another
141
+ installed channel with `--channel stable|beta|dev`, e.g. `--channel stable`
142
+ for regular Google Chrome.
143
+ - **Camoufox** (`camoufox fetch`) for anti-detect Firefox workflows, with the
144
+ `camoufox` extra
145
+
146
+ The default install depends on `websockets` only. There is no Node.js
147
+ dependency: the Node `chrome-devtools-mcp` path was removed in RFC-01.
148
+
149
+ ## Architecture
150
+
151
+ Five layers. Each upper layer consumes only the layer below it, and every
152
+ curated tool calls the same CDP `send` path the raw passthrough uses -- so any
153
+ method the installed browser supports works through `bt Domain.method` whether
154
+ or not a verb exists for it.
155
+
156
+ | Layer | Name | Contents |
157
+ |---|---|---|
158
+ | 4 | Front | CLI verbs (the only surface), `bt guide`, the agent skill that points at it |
159
+ | 3 | Policy | Named profiles and the profile root, fingerprint profiles, engine routing |
160
+ | 2 | Native toolset | Curated tools as plain CDP consumers; profiling; window marking |
161
+ | 1 | Core (vendored) | Registry, liveness, launcher, supervisor, attach, passthrough, live-schema help |
162
+ | 0 | Browser | Chrome/Chromium over CDP; Camoufox for anti-detect paths |
163
+
164
+ ```
165
+ cli.py CLI entry point (argparse, verb dispatch, exit codes)
166
+ |
167
+ +-- lifecycle.py launch / status / stop / cleanup over the registry
168
+ | +-- camoufox_runner.py Camoufox host process (`launch --engine camoufox`)
169
+ | +-- process_utils.py Chrome process and port utilities
170
+ |
171
+ +-- endpoint.py `--endpoint URL`: loopback check, refusals
172
+ +-- passthrough.py Raw `Domain.method` send + the focus guard
173
+ +-- curated.py The curated verbs over one short-lived CDP handler
174
+ +-- one_shot.py Connect, resolve a page target, attach, detach
175
+ +-- events.py attach / wait / console-list / network-list
176
+ +-- list_verbs.py frames / storage
177
+ +-- user_settings.py The persistent settings file (window border)
178
+ |
179
+ +-- core/ Vendored chrome-agent core (RFC-01; see NOTICE)
180
+ | +-- registry.py Named instances, liveness, retirement
181
+ | +-- launcher.py Chrome launch (windowless, background first window)
182
+ | +-- supervisor.py Per-instance window marking and retirement
183
+ | +-- cdp_client.py CDP WebSocket client and target discovery
184
+ | +-- attach.py Isolated event subscriptions
185
+ | +-- protocol.py Live protocol schema for `help`
186
+ | +-- fingerprint.py Launch-flag fingerprint profiles
187
+ |
188
+ +-- cdp_handler.py CDP tool implementations (snapshot, click, fill, ...)
189
+ | +-- native_snapshot.py Accessibility-tree snapshot and UID scheme
190
+ | +-- native_interaction.py UID click / fill
191
+ | +-- frame_manager.py Frame tree management
192
+ | +-- interstitial.py Challenge detection and the retry policy
193
+ | +-- screencast.py Screencast capture state machine
194
+ | +-- screenshot_utils.py Blank-frame detection
195
+ | +-- tool_registry.py Single source of truth for CDP tool routing
196
+ | +-- mcp_response.py Response envelope builders
197
+ |
198
+ +-- profiler.py Standalone CPU profiler (`browser-tools-profiler`)
199
+ ```
200
+
201
+ The CLI is the only surface. The optional MCP front and the persistent-session
202
+ stack behind it were deleted in RFC-01 Phase 5; there is no daemon, no broker,
203
+ and no listening socket.
204
+
205
+ ## Keeping login state across calls
206
+
207
+ Login state lives in a browser profile directory and survives only while the
208
+ same directory is reused. To keep a session logged in:
209
+
210
+ - **Use a named profile**: `bt launch --profile <name>`. Named profiles persist
211
+ across restarts and are unaffected by headed/headless switches, viewport, or
212
+ which directory you invoke from.
213
+ - A profile is held by at most one live instance. Launching into a profile
214
+ another instance holds fails naming the holder rather than opening a second
215
+ browser on the same directory.
216
+ - Without `--profile`, a launch gets a fresh ephemeral directory and starts
217
+ logged out.
218
+ - `bt profile list` shows every profile with its path and its live holder, and
219
+ `bt profile delete NAME` removes one. Deleting a profile deletes its login
220
+ state; `cleanup` never removes a profile on age.
221
+
222
+ Profiles live in durable storage: `$BROWSER_TOOLS_PROFILES_DIR`, else
223
+ `$XDG_DATA_HOME/browser-tools/profiles`, else
224
+ `~/.local/share/browser-tools/profiles`. They used to live under `/tmp`, where
225
+ the operating system deleted every signed-in session at boot, silently. A
226
+ profile still there is listed with `"legacy": true`; `bt profile migrate`
227
+ moves them all across (`--dry-run` first, `--back` to reverse it), and
228
+ `launch --profile NAME` brings that one forward by itself.
229
+ - **Camoufox** persists login state only when you pass `--profile`; without it,
230
+ every launch starts logged out.
231
+
232
+ ## Development
233
+
234
+ ```bash
235
+ uv sync
236
+ uv run ruff check src/ tests/
237
+ uv run pytest
238
+ ```
239
+
240
+ ## License
241
+
242
+ MIT - see [LICENSE](LICENSE).
243
+
244
+ ## Contributing
245
+
246
+ See [CONTRIBUTING.md](CONTRIBUTING.md) for development setup and guidelines.
247
+ All contributors are expected to follow the [Code of Conduct](CODE_OF_CONDUCT.md).
248
+
249
+ ## Security
250
+
251
+ Found a vulnerability? See [SECURITY.md](SECURITY.md) for responsible disclosure.
@@ -0,0 +1,212 @@
1
+ # Browser Tools
2
+
3
+ [![CI](https://github.com/dungle-scrubs/browser-tools/actions/workflows/ci.yml/badge.svg)](https://github.com/dungle-scrubs/browser-tools/actions/workflows/ci.yml)
4
+ [![Python 3.13+](https://img.shields.io/badge/python-3.13+-blue.svg)](https://www.python.org/downloads/)
5
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
6
+ [![Code style: ruff](https://img.shields.io/badge/code%20style-ruff-000000.svg)](https://docs.astral.sh/ruff/)
7
+
8
+ Browser automation, debugging, and anti-detect browsing CLI. Provides:
9
+
10
+ - **Raw CDP passthrough** - Any `Domain.method` goes straight to the running
11
+ browser, with protocol help read live from it
12
+ - **Snapshot-based page automation** - Accessibility-tree snapshots and UID
13
+ interaction (`snapshot`, `click --uid`, `fill --uid`), in Python over CDP
14
+ - **Named browser instances** - Long-lived Chrome with a registry and named
15
+ profiles that keep a login across restarts
16
+ - **External browsers** - `--endpoint http://127.0.0.1:9222` drives a browser
17
+ you already have open and logged in, writing nothing to the registry
18
+ - **Frame-aware tools** - Iframe/CDP frame tree management, execution context
19
+ resolution, and storage inspection
20
+ - **Interstitial detection** - Multi-signal heuristic detection for Cloudflare,
21
+ DataDome, Akamai, PerimeterX, Imperva, AWS WAF, and other challenge pages
22
+ - **Camoufox anti-detect browsing** - Fingerprint-injected Firefox-based
23
+ browsing for bot-protected sites
24
+ - **Anything else CDP can do** - File upload, viewport emulation, cookies,
25
+ PDF export and page management have no curated verb and need none; `bt
26
+ guide` has a worked example of each
27
+ - **CPU profiling** - `browser-tools-profiler`, a second command installed
28
+ alongside `bt`, with timed capture and threshold-triggered capture
29
+
30
+ ## Quick Start
31
+
32
+ ### Installation
33
+
34
+ ```bash
35
+ # Using uv (recommended)
36
+ uv tool install browser-tools
37
+
38
+ # Or with pip
39
+ pip install browser-tools
40
+ ```
41
+
42
+ ### Usage
43
+
44
+ ```bash
45
+ # Run the CLI (`bt` is an alias for `browser-tools`)
46
+ bt --help
47
+
48
+ # Launch a browser. It is registered by name and outlives this command, so
49
+ # later verbs drive the same Chrome and share its page and login state.
50
+ bt launch
51
+
52
+ # Navigate through the raw CDP passthrough, then read the page.
53
+ bt Page.navigate '{"url": "https://example.com"}'
54
+ bt snapshot
55
+
56
+ # Interact by UID from that snapshot.
57
+ bt click --uid 1-13
58
+
59
+ # When the page is blocking, ask directly.
60
+ bt detect
61
+
62
+ bt status # registered instances and their page targets
63
+ bt stop # close the browser and retire its registry entry
64
+ ```
65
+
66
+ Omit `INSTANCE` while exactly one instance is running; with several, every verb
67
+ names the candidates rather than guessing. `bt help Domain.method` reads the
68
+ protocol schema from the running browser.
69
+
70
+ **`bt guide` is the manual.** It is the complete CLI surface -- every verb,
71
+ every refusal with its exit code, the login walkthrough, the UID rule, and the
72
+ `--endpoint` rules -- and reading it is enough to drive a browser with this
73
+ tool. A test fails the build when a verb has no entry in it.
74
+
75
+ To drive a browser you started yourself, pass its debugging port instead of an
76
+ instance name:
77
+
78
+ ```bash
79
+ # Chrome started with --remote-debugging-port=9222, already logged in.
80
+ bt snapshot --endpoint http://127.0.0.1:9222
81
+ bt click --uid 0BDAEF756714-14 --endpoint http://127.0.0.1:9222
82
+ ```
83
+
84
+ Nothing is written to the registry, so `status` does not list it and `stop` and
85
+ `cleanup` cannot reach it -- which is what keeps them away from your real Chrome
86
+ profile directory. Only `127.0.0.1` and `::1` are accepted; forward a remote
87
+ browser with `ssh -L 9222:127.0.0.1:9222 <host>`. `Browser.close` and
88
+ `Browser.crash` are refused over `--endpoint`.
89
+
90
+ ### Development setup
91
+
92
+ ```bash
93
+ # Clone and install in editable mode
94
+ git clone https://github.com/dungle-scrubs/browser-tools.git
95
+ cd browser-tools
96
+ uv sync
97
+ ```
98
+
99
+ Runtime requirements:
100
+
101
+ - **Chrome Canary** by default (the default channel is `canary`). Use another
102
+ installed channel with `--channel stable|beta|dev`, e.g. `--channel stable`
103
+ for regular Google Chrome.
104
+ - **Camoufox** (`camoufox fetch`) for anti-detect Firefox workflows, with the
105
+ `camoufox` extra
106
+
107
+ The default install depends on `websockets` only. There is no Node.js
108
+ dependency: the Node `chrome-devtools-mcp` path was removed in RFC-01.
109
+
110
+ ## Architecture
111
+
112
+ Five layers. Each upper layer consumes only the layer below it, and every
113
+ curated tool calls the same CDP `send` path the raw passthrough uses -- so any
114
+ method the installed browser supports works through `bt Domain.method` whether
115
+ or not a verb exists for it.
116
+
117
+ | Layer | Name | Contents |
118
+ |---|---|---|
119
+ | 4 | Front | CLI verbs (the only surface), `bt guide`, the agent skill that points at it |
120
+ | 3 | Policy | Named profiles and the profile root, fingerprint profiles, engine routing |
121
+ | 2 | Native toolset | Curated tools as plain CDP consumers; profiling; window marking |
122
+ | 1 | Core (vendored) | Registry, liveness, launcher, supervisor, attach, passthrough, live-schema help |
123
+ | 0 | Browser | Chrome/Chromium over CDP; Camoufox for anti-detect paths |
124
+
125
+ ```
126
+ cli.py CLI entry point (argparse, verb dispatch, exit codes)
127
+ |
128
+ +-- lifecycle.py launch / status / stop / cleanup over the registry
129
+ | +-- camoufox_runner.py Camoufox host process (`launch --engine camoufox`)
130
+ | +-- process_utils.py Chrome process and port utilities
131
+ |
132
+ +-- endpoint.py `--endpoint URL`: loopback check, refusals
133
+ +-- passthrough.py Raw `Domain.method` send + the focus guard
134
+ +-- curated.py The curated verbs over one short-lived CDP handler
135
+ +-- one_shot.py Connect, resolve a page target, attach, detach
136
+ +-- events.py attach / wait / console-list / network-list
137
+ +-- list_verbs.py frames / storage
138
+ +-- user_settings.py The persistent settings file (window border)
139
+ |
140
+ +-- core/ Vendored chrome-agent core (RFC-01; see NOTICE)
141
+ | +-- registry.py Named instances, liveness, retirement
142
+ | +-- launcher.py Chrome launch (windowless, background first window)
143
+ | +-- supervisor.py Per-instance window marking and retirement
144
+ | +-- cdp_client.py CDP WebSocket client and target discovery
145
+ | +-- attach.py Isolated event subscriptions
146
+ | +-- protocol.py Live protocol schema for `help`
147
+ | +-- fingerprint.py Launch-flag fingerprint profiles
148
+ |
149
+ +-- cdp_handler.py CDP tool implementations (snapshot, click, fill, ...)
150
+ | +-- native_snapshot.py Accessibility-tree snapshot and UID scheme
151
+ | +-- native_interaction.py UID click / fill
152
+ | +-- frame_manager.py Frame tree management
153
+ | +-- interstitial.py Challenge detection and the retry policy
154
+ | +-- screencast.py Screencast capture state machine
155
+ | +-- screenshot_utils.py Blank-frame detection
156
+ | +-- tool_registry.py Single source of truth for CDP tool routing
157
+ | +-- mcp_response.py Response envelope builders
158
+ |
159
+ +-- profiler.py Standalone CPU profiler (`browser-tools-profiler`)
160
+ ```
161
+
162
+ The CLI is the only surface. The optional MCP front and the persistent-session
163
+ stack behind it were deleted in RFC-01 Phase 5; there is no daemon, no broker,
164
+ and no listening socket.
165
+
166
+ ## Keeping login state across calls
167
+
168
+ Login state lives in a browser profile directory and survives only while the
169
+ same directory is reused. To keep a session logged in:
170
+
171
+ - **Use a named profile**: `bt launch --profile <name>`. Named profiles persist
172
+ across restarts and are unaffected by headed/headless switches, viewport, or
173
+ which directory you invoke from.
174
+ - A profile is held by at most one live instance. Launching into a profile
175
+ another instance holds fails naming the holder rather than opening a second
176
+ browser on the same directory.
177
+ - Without `--profile`, a launch gets a fresh ephemeral directory and starts
178
+ logged out.
179
+ - `bt profile list` shows every profile with its path and its live holder, and
180
+ `bt profile delete NAME` removes one. Deleting a profile deletes its login
181
+ state; `cleanup` never removes a profile on age.
182
+
183
+ Profiles live in durable storage: `$BROWSER_TOOLS_PROFILES_DIR`, else
184
+ `$XDG_DATA_HOME/browser-tools/profiles`, else
185
+ `~/.local/share/browser-tools/profiles`. They used to live under `/tmp`, where
186
+ the operating system deleted every signed-in session at boot, silently. A
187
+ profile still there is listed with `"legacy": true`; `bt profile migrate`
188
+ moves them all across (`--dry-run` first, `--back` to reverse it), and
189
+ `launch --profile NAME` brings that one forward by itself.
190
+ - **Camoufox** persists login state only when you pass `--profile`; without it,
191
+ every launch starts logged out.
192
+
193
+ ## Development
194
+
195
+ ```bash
196
+ uv sync
197
+ uv run ruff check src/ tests/
198
+ uv run pytest
199
+ ```
200
+
201
+ ## License
202
+
203
+ MIT - see [LICENSE](LICENSE).
204
+
205
+ ## Contributing
206
+
207
+ See [CONTRIBUTING.md](CONTRIBUTING.md) for development setup and guidelines.
208
+ All contributors are expected to follow the [Code of Conduct](CODE_OF_CONDUCT.md).
209
+
210
+ ## Security
211
+
212
+ Found a vulnerability? See [SECURITY.md](SECURITY.md) for responsible disclosure.
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "browser-tools"
3
- version = "0.3.0"
3
+ version = "0.4.1"
4
4
  description = "Browser automation, debugging, and anti-detect browsing CLI"
5
5
  readme = "README.md"
6
6
  license = "MIT"
@@ -13,7 +13,6 @@ keywords = [
13
13
  "camoufox",
14
14
  "playwright",
15
15
  "web-scraping",
16
- "mcp",
17
16
  ]
18
17
  classifiers = [
19
18
  "Development Status :: 3 - Alpha",
@@ -81,8 +80,7 @@ build-backend = "hatchling.build"
81
80
  packages = ["src/browser_tools"]
82
81
  artifacts = [
83
82
  "src/browser_tools/*.js",
84
- "src/browser_tools/*.mjs",
85
- "src/browser_tools/*.sh",
83
+ "src/browser_tools/GUIDE.txt",
86
84
  ]
87
85
 
88
86
  [tool.hatch.build.targets.sdist]