You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Expose user friendly way to attach debugger to running Actor #1110
It has been shown that it is possible to attach a debugger to an Actor running on the Apify platform and control the execution of the Actor code from a local IDE.
Here are sample Actors showing a crude way to do this: https://github.com/Pijukatel/actor-debug
Local debugger setup where the developer maps the local code folder to the Actor folders
Injected start-up code in the Actor that waits for the debugger to connect
Copy-pasting the connection string from the Actor to the local machine to be able to connect
Figure out a way to make this as simple as possible so that the basic Actor creator is able to smoothly debug the Actors.
Random ideas:
include the tool wstunnel in each Docker image? or have a debug variant for each image?
Try to find if there is a Python-only package that can handle the tunnel creation and turn this into an optional dependency of Apify, Add debug to Actor.configuration and if True, the actor will automatically start in debug mode and wait for debugger attachment
...
Prototype for Python and implement for JS/TS actors as well.
Security risk:
Current method prints the debugger connection to the log. If the log is shared with anyone (not the owner of the actor) while the actor run is still running, then this person can execute code in another person's actor and thus even grant access to many secrets. So we have to consider how to handle this to avoid users accidentally compromising themselves
TS/JS shortcut:
Most actors are TS/JS based, so this could be implemented as debugging in the browser that attaches to any TS/JS actor (it would not work for Python). So this could be purely an in-browser workflow with the simplest user interaction and reuse the existing browser-based debugger.
Activity
Pijukatel commentedon Sep 21, 2026
Guide that describes the drop-in debugger and the manual tunnel approach:
apify/apify-docs#2999
Drop-in debugger published for both Python and JS/Ts actors:
https://www.npmjs.com/package/actor-debugger?activeTab=readme
https://pypi.org/project/actor-debugger/
Closing for now until further native platform debugging support is requested.