| 705 | return render_template("admin/attach_debugger", python_version) |
| 706 | |
| 707 | def POST(self): |
| 708 | import debugpy # noqa: T100 |
| 709 | |
| 710 | # Allow other computers to attach to ptvsd at this IP address and port. |
| 711 | web.debug("Enabling debugger attachment") |
| 712 | debugpy.listen(("0.0.0.0", 3000)) # noqa: T100 |
| 713 | web.debug("Waiting for debugger to attach...") |
| 714 | debugpy.wait_for_client() # noqa: T100 |
| 715 | web.debug("Debugger attached to port 3000") |
| 716 | add_flash_message("info", "Debugger attached!") |
| 717 | |
| 718 | return self.GET() |
| 719 | |
| 720 | |
| 721 | class solr: |