Skip to main content

Playwright 交互式调试工具

Project description

mp-repl

Playwright 交互式调试工具 - 提升自动化脚本开发效率

安装

pip install mp-repl
playwright install chromium

快速开始

# 启动 REPL
pw-repl

# 连接浏览器
pw> connect

# 页面操作
pw> go https://example.com
pw> btn 'Submit'
pw> fill '#email' 'test@example.com'

# 执行 Playwright 代码
pw> page.locator('button').click()

# 加载并执行脚本
pw> run my_script.py
pw> my_function()

功能

  • 命令式操作:btn, click, fill, go 等快捷命令
  • Playwright 直接执行:page.xxx, browser.xxx
  • 脚本执行:加载 Python 脚本,函数可直接调用
  • 多连接管理:同时连接多个浏览器
  • 会话管理:集成 s-mgr 账号切换

文档

详见 docs/design.md

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mp_repl-0.1.14.tar.gz (8.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mp_repl-0.1.14-py3-none-any.whl (9.0 kB view details)

Uploaded Python 3

File details

Details for the file mp_repl-0.1.14.tar.gz.

File metadata

  • Download URL: mp_repl-0.1.14.tar.gz
  • Upload date:
  • Size: 8.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.11

File hashes

Hashes for mp_repl-0.1.14.tar.gz
Algorithm Hash digest
SHA256 fc14fdbde9e0ce81f6a9727cf17847783fe06c1a7dc37e60ca0ec4e5ac6c5701
MD5 0152617c7a05739afa83d9d83885f908
BLAKE2b-256 e24d9b6fc4a5063c9ebd38135862fbccd9767c07cf46d5041f1a44a2c3ff3a64

See more details on using hashes here.

File details

Details for the file mp_repl-0.1.14-py3-none-any.whl.

File metadata

  • Download URL: mp_repl-0.1.14-py3-none-any.whl
  • Upload date:
  • Size: 9.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.11

File hashes

Hashes for mp_repl-0.1.14-py3-none-any.whl
Algorithm Hash digest
SHA256 4c86db8216802f1b87d62f78a2c6ee681c31522276030735df8bd7d0e192d38f
MD5 f037b8bc48cca5c165171e019faae3c6
BLAKE2b-256 55aab63009a5e43d1f9cbf9800bba1b8b8f04aba0810c4ecf27c4f70b2d80285

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page