Name | plan-d JSON |
Version |
0.2.3
JSON |
| download |
home_page | None |
Summary | Python Language's Another Nonpareil remote Debugger |
upload_time | 2024-12-31 06:38:23 |
maintainer | None |
docs_url | None |
author | ZhengYu, Xu |
requires_python | <4.0,>=3.8 |
license | MIT |
keywords |
debugger
remote
ipython
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# plan-d
[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
![PyPI - Version](https://img.shields.io/pypi/v/plan-d)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/plan-d)
![GitHub License](https://img.shields.io/github/license/zen-xu/plan-d)
Python Language's Another Nonpareil remote Debugger
## Table of Contents
- [plan-d](#plan-d)
- [Table of Contents](#table-of-contents)
- [Introduction](#introduction)
- [Features](#features)
- [Installation](#installation)
- [Gallery](#gallery)
- [Debugger commands](#debugger-commands)
- [Print object info](#print-object-info)
- [IPython magic command](#ipython-magic-command)
- [Auto launch debugger when exception](#auto-launch-debugger-when-exception)
- [FAQ](#faq)
- [How to exit the debugger?](#how-to-exit-the-debugger)
## Introduction
`plan-d` is a remote debugger for Python, designed to provide an unparalleled debugging experience. It allows developers to debug Python applications running on remote servers seamlessly.
## Features
- ⨠Provide a more pretty printing using `rich`
- đšī¸ Remote debugging capabilities
- â¨ī¸ Code autocompletion
- đ´ Breakpoint management
- đ Variable inspection
- đ Terminal size auto-adjustment
- đĒ Support for IPython magic commands
- đ Support for multiple Python versions
## Installation
To install `plan-d`, you can use pip:
```sh
pip install plan-d
```
## Gallery
On the server side, you can set a breakpoint with `plan_d.set_trace()`. When the server reaches the breakpoint, it will print the connection command.
<figure class="image">
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-connect.jpg">
</figure>
<figure class="image">
<figcaption style="text-align: center;">syntax highlight</figcaption>
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-highlight-output.jpg">
</figure>
<figure class="image">
<figcaption style="text-align: center;">support multiline</figcaption>
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-multilines.jpg">
</figure>
### Debugger commands
<figure class="image">
<figcaption style="text-align: center;">(h)elp</figcaption>
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-cmd-h.jpg">
</figure>
<figure class="image">
<figcaption style="text-align: center;">(v)ars</figcaption>
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-cmd-vars.jpg">
</figure>
<figure class="image">
<figcaption style="text-align: center;">vt|varstree</figcaption>
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-cmd-vt.jpg">
</figure>
<figure class="image">
<figcaption style="text-align: center;">(i)nspect</figcaption>
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-cmd-i.jpg">
</figure>
<figure class="image">
<figcaption style="text-align: center;">bt</figcaption>
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-cmd-bt.jpg">
</figure>
### Print object info
<figure class="image">
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-pinfo.jpg">
</figure>
<figure class="image">
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-pinfo2.jpg">
</figure>
### IPython magic command
<figure class="image">
<figcaption style="text-align: center;">magic command</figcaption>
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-magic.jpg">
</figure>
<figure class="image">
<figcaption style="text-align: center;">time</figcaption>
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-magic-time.jpg">
</figure>
## Auto launch debugger when exception
`plan-d` supports automatically launching the debugger when an exception occurs.
You can enclose code with the with statement to launch `plan-d` if an exception is raised:
```python
import plan_d
with plan_d.lpe():
[...]
```
Or you can use `lpe` as a function decorator to launch `plan-d` if an exception is raised:
```python
import plan_d
@plan_d.lpe()
def main():
[...]
```
When the client connects, the stack information will be displayed.
<figure class="image">
<img src="https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-decorator.jpg">
</figure>
## FAQ
### How to exit the debugger?
Exit by typing the command `exit` or pressing <kbd>ctrl+d</kbd>.
Raw data
{
"_id": null,
"home_page": null,
"name": "plan-d",
"maintainer": null,
"docs_url": null,
"requires_python": "<4.0,>=3.8",
"maintainer_email": null,
"keywords": "debugger, remote, ipython",
"author": "ZhengYu, Xu",
"author_email": "zen-xu@outlook.com",
"download_url": null,
"platform": null,
"description": "# plan-d\n\n[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)\n![PyPI - Version](https://img.shields.io/pypi/v/plan-d)\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/plan-d)\n![GitHub License](https://img.shields.io/github/license/zen-xu/plan-d)\n\nPython Language's Another Nonpareil remote Debugger\n\n## Table of Contents\n\n- [plan-d](#plan-d)\n - [Table of Contents](#table-of-contents)\n - [Introduction](#introduction)\n - [Features](#features)\n - [Installation](#installation)\n - [Gallery](#gallery)\n - [Debugger commands](#debugger-commands)\n - [Print object info](#print-object-info)\n - [IPython magic command](#ipython-magic-command)\n - [Auto launch debugger when exception](#auto-launch-debugger-when-exception)\n - [FAQ](#faq)\n - [How to exit the debugger?](#how-to-exit-the-debugger)\n\n## Introduction\n\n`plan-d` is a remote debugger for Python, designed to provide an unparalleled debugging experience. It allows developers to debug Python applications running on remote servers seamlessly.\n\n## Features\n\n- \u2728 Provide a more pretty printing using `rich`\n- \ud83d\udd79\ufe0f Remote debugging capabilities\n- \u2328\ufe0f Code autocompletion\n- \ud83d\udd34 Breakpoint management\n- \ud83d\udd0e Variable inspection\n- \ud83d\udd04 Terminal size auto-adjustment\n- \ud83e\ude84 Support for IPython magic commands\n- \ud83d\udc0d Support for multiple Python versions\n\n## Installation\n\nTo install `plan-d`, you can use pip:\n\n```sh\npip install plan-d\n```\n\n## Gallery\n\nOn the server side, you can set a breakpoint with `plan_d.set_trace()`. When the server reaches the breakpoint, it will print the connection command.\n\n<figure class=\"image\">\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-connect.jpg\">\n</figure>\n\n<figure class=\"image\">\n <figcaption style=\"text-align: center;\">syntax highlight</figcaption>\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-highlight-output.jpg\">\n</figure>\n\n<figure class=\"image\">\n <figcaption style=\"text-align: center;\">support multiline</figcaption>\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-multilines.jpg\">\n</figure>\n\n### Debugger commands\n\n<figure class=\"image\">\n <figcaption style=\"text-align: center;\">(h)elp</figcaption>\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-cmd-h.jpg\">\n</figure>\n\n<figure class=\"image\">\n <figcaption style=\"text-align: center;\">(v)ars</figcaption>\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-cmd-vars.jpg\">\n</figure>\n\n<figure class=\"image\">\n <figcaption style=\"text-align: center;\">vt|varstree</figcaption>\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-cmd-vt.jpg\">\n</figure>\n\n<figure class=\"image\">\n <figcaption style=\"text-align: center;\">(i)nspect</figcaption>\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-cmd-i.jpg\">\n</figure>\n\n<figure class=\"image\">\n <figcaption style=\"text-align: center;\">bt</figcaption>\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-cmd-bt.jpg\">\n</figure>\n\n### Print object info\n\n<figure class=\"image\">\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-pinfo.jpg\">\n</figure>\n\n<figure class=\"image\">\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-pinfo2.jpg\">\n</figure>\n\n### IPython magic command\n\n<figure class=\"image\">\n <figcaption style=\"text-align: center;\">magic command</figcaption>\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-magic.jpg\">\n</figure>\n\n<figure class=\"image\">\n <figcaption style=\"text-align: center;\">time</figcaption>\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-magic-time.jpg\">\n</figure>\n\n## Auto launch debugger when exception\n\n`plan-d` supports automatically launching the debugger when an exception occurs.\n\nYou can enclose code with the with statement to launch `plan-d` if an exception is raised:\n\n```python\nimport plan_d\n\nwith plan_d.lpe():\n [...]\n```\n\nOr you can use `lpe` as a function decorator to launch `plan-d` if an exception is raised:\n\n\n```python\nimport plan_d\n\n@plan_d.lpe()\ndef main():\n [...]\n```\nWhen the client connects, the stack information will be displayed.\n<figure class=\"image\">\n <img src=\"https://zenxu-github-asset.s3.us-east-2.amazonaws.com/plan-d/pland-decorator.jpg\">\n</figure>\n\n## FAQ\n\n### How to exit the debugger?\n\nExit by typing the command `exit` or pressing <kbd>ctrl+d</kbd>.\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Python Language's Another Nonpareil remote Debugger",
"version": "0.2.3",
"project_urls": null,
"split_keywords": [
"debugger",
" remote",
" ipython"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "9c4f404d253608a36b11845b70ed92a6ba0ba752fe2eb4a546de2da9eb2ac9e8",
"md5": "7c3641bebcdb70e5fe77788de8cdcf3d",
"sha256": "669755c32238aea96deaa247f66f0a76294ea2bfe5cad2a9d9d5e59d859b4a81"
},
"downloads": -1,
"filename": "plan_d-0.2.3-py3-none-any.whl",
"has_sig": false,
"md5_digest": "7c3641bebcdb70e5fe77788de8cdcf3d",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<4.0,>=3.8",
"size": 13762,
"upload_time": "2024-12-31T06:38:23",
"upload_time_iso_8601": "2024-12-31T06:38:23.954665Z",
"url": "https://files.pythonhosted.org/packages/9c/4f/404d253608a36b11845b70ed92a6ba0ba752fe2eb4a546de2da9eb2ac9e8/plan_d-0.2.3-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-12-31 06:38:23",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "plan-d"
}