https://pantsbuild.org/ logo
f

future-oxygen-10553

08/05/2022, 3:32 PM
Is there a way to attach a debugger to the pants process? I’m trying to debug a plugin and I’d like to set a breakpoint in my plugin code.
👀 1
h

hundreds-father-404

08/05/2022, 3:40 PM
I believe yes thanks to @bitter-ability-32190 🙂 https://github.com/pantsbuild/pants/pull/15951
f

future-oxygen-10553

08/05/2022, 3:41 PM
Ooo! Is that released, or do I need to set the PANTS_SHA?
h

hundreds-father-404

08/05/2022, 3:43 PM
wait to clarify, do you want to debug Pants itself? Or something like
run
? Because in sibling PRs, Josh added support to that too
Is that released
Looks like this particular PR is in 2.14.0.dev2 and newer
b

bitter-ability-32190

08/05/2022, 3:43 PM
Right now you can't easily debug a pants plugin, but it's maybe 1 PR away
f

future-oxygen-10553

08/05/2022, 3:44 PM
I’m writing a plugin as a first step towards parsing PEP621, and I’m getting an error I don’t understand. I wanted to drop a breakpoint at the spot where the error is raising in my code
🎉 Thanks @bitter-ability-32190
❤️ 1
Then let me start a new thread and ask my actual question 😄
b

bitter-ability-32190

08/05/2022, 5:06 PM
Well let me clarify, debugging a plugin in your own repo isn't supported yet. If you're doing it in the pants repo you can run pants with PANTS_DEBUG=1
5 Views