def python_debugger(event: PodEvent, params: DebuggerParams):
    """
    Attach a python debugger to a running pod. No need to modify the application's code or restart it.

    Steps:
        1. :ref:`Install Robusta <install>`
        2. Manually trigger this action using the Robusta CLI and the pod's name:

        .. code-block:: bash

             robusta playbooks trigger python_debugger name=podname namespace=default

        2. Follow the instructions you receive and run `kubectl port-forward`
        3. In Visual Studio Code do a Remote Attach as per the instructions

    Now you can use break points and log points in VSCode.
    """
    if "debug-toolkit:v6.0" not in PYTHON_DEBUGGER_IMAGE:
        logging.error(f"The python_debugger action is deprecated and might not work on all platforms. "
                      f"to enable it set the PYTHON_DEBUGGER_IMAGE environment variable to debug-toolkit:v6.0.")
        return
    pod = event.get_pod()
    logging.warning(f"The python_debugger action is deprecated and might not work on all platforms.")
    if not pod:
        logging.info(f"python_debugger - pod not found for event: {event}")
        return

    finding = Finding(
        title=f"Python debugging session on pod {pod.metadata.name} in namespace {pod.metadata.namespace}:",
        source=FindingSource.MANUAL,
        aggregation_key="PythonDebugger",
        subject=PodFindingSubject(pod),
        finding_type=FindingType.REPORT,
        failure=False,
    )

    process_finder = ProcessFinder(pod, params, ProcessType.PYTHON)
    process = process_finder.get_match_or_report_error(finding, "Debug", python_debugger, python_process_inspector)
    if process is None:
        event.add_finding(finding)
        return

    cmd = f"debug-toolkit debugger {process.pid} --port {params.port}"
    output = load_json(
        RobustaPod.exec_in_debugger_pod(
            pod.metadata.name, pod.spec.nodeName, cmd, custom_annotations=params.custom_annotations
        )
    )
    finding.add_enrichment(
        [
            MarkdownBlock(
                f"""
                1. Run: `kubectl port-forward -n {pod.metadata.namespace} {pod.metadata.name} {params.port}:{params.port}`
                2. In VSCode do a Remote Attach to `localhost` and port {params.port}
                3. If breakpoints don't work in VSCode you will need to set `pathMappings` in launch.json. See attached files for assistance.
                4. Use VSCode logpoints to debug without pausing your application. Happy debugging!
                """,
                dedent=True,
            )
        ]
    )

    warnings = get_debugger_warnings(output)
    if warnings is not None:
        finding.add_enrichment([HeaderBlock("Warning"), MarkdownBlock(warnings)])

    finding.add_enrichment(
        [
            FileBlock(
                "launch.json",
                json.dumps(get_example_launch_json(params), indent=4).encode(),
            ),
            FileBlock("loaded-modules.txt", get_loaded_module_info(output).encode()),
        ]
    )
    logging.info("Done! See instructions for connecting to the debugger in Slack or Robusta UI")
    event.add_finding(finding)

    Attach a python debugger to a running pod. No need to modify the application's code or restart it.

    Steps:
        1. :ref:`Install Robusta <install>`
        2. Manually trigger this action using the Robusta CLI and the pod's name:

        .. code-block:: bash

             robusta playbooks trigger python_debugger name=podname namespace=default

        2. Follow the instructions you receive and run `kubectl port-forward`
        3. In Visual Studio Code do a Remote Attach as per the instructions

    Now you can use break points and log points in VSCode.
    
playbooks/robusta_playbooks/pod_troubleshooting.py