Hi all I have a weird issue where my script will o...
# general
q
Hi all I have a weird issue where my script will only run with the
--debug-adapter
flag set. If I run without that then the script fails (with no error, even if I set
--print-stacktrace -ldebug
) on the line
import open_clip
. I guess its due to something weird that this library is doing but the fact that it works in debug mode is really screwing with me. Has anyone else encountered anything like this before?
s
This is a wild guess but I think
debug.pex
contains all of your resolve. When running with debug-adapter you might be importing a library that's not included otherwise. Is it possible
open_clip
(or some other library) depends on something you need to manually set?
h
Good guess @silly-queen-7197!
@quick-flag-69355 it would be helpful to know what the error message is.
And you can check if your script does in fact have the necessary dependency path via
pants dependencies --from=path/to/main.py --to=3rdparty/python#open_clip
or whatever the open_clip target is
q
Thanks for the assistance @happy-kitchen-89482 and @silly-queen-7197. I've had to just leave it in debug mode for now so I can move on to other pressing things but will circle back to these suggestions in the next day or two. Unfortunately as mentioned in the initial post I haven't been able to get an error message out of it at all. It just stops. Even with all the verbosity flags I could find.
h
Let us know how that pans out!