Author Topic: Messages when debugging Python  (Read 483 times)

ebbe

  • Community Member
  • Posts: 38
  • Hero Points: 2
Messages when debugging Python
« on: February 15, 2023, 12:36:19 pm »
I get the following messages that seem to be caused by python code that is supplied by SE. What is the explanation here?

Code: [Select]
C:\Users\ebbe\projects\myproject\test>C:\Python311\python.exe -u -Xfrozen_modules=off  "C:\Program Files\SlickEdit Pro 27.0.1\resource/tools/ptvsd" --host 127.0.0.1 --port 5678 --wait "C:\Program Files\SlickEdit Pro 27.0.1\resource/tools/ptvsd/se_wrapper_script.py" C:\Users\ebbe\projects\myproject\test\test_config\test_config.py ConfigLoad
C:\Program Files\SlickEdit Pro 27.0.1\resource\tools\ptvsd\_vendored\pydevd\pydevd.py:1326: DeprecationWarning: currentThread() is deprecated, use current_thread() instead
  curr_thread_id = get_current_thread_id(threadingCurrentThread())
C:\Program Files\SlickEdit Pro 27.0.1\resource\tools\ptvsd\_vendored\pydevd\pydevd.py:1030: DeprecationWarning: isDaemon() is deprecated, get the daemon attribute instead
  if not t.isDaemon() or hasattr(t, "__pydevd_main_thread"):

SE running on Windows 10, fully updated including hotfix 2.

And in case someone is wondering about this option:
Code: [Select]
-Xfrozen_modules=off It  turns off a bunch of warnings about not being able to find frozen files. It is a workaround for a bug in pydev and it was suggested by than Guido van Rossum (no less).

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1810
  • Hero Points: 151
Re: Messages when debugging Python
« Reply #1 on: February 15, 2023, 02:03:38 pm »
The Pydev debugging backend was put in a couple of years ago.  This is the first time I've seen a report on these deprecations, and looking at the versions of Python I have on my dev systems, I'm going to guess these came into effect for Python >= 3.10. 

I'll take a closer look at it later.  I'm not up to date on what's happened with the pydevd backend since Microsoft decided to switch away from it to what appeared to be a renamed fork.  So I might be able to pull updates that address the warnings, or I might just need to patch it myself.

Thanks for the report. 

ebbe

  • Community Member
  • Posts: 38
  • Hero Points: 2
Re: Messages when debugging Python
« Reply #2 on: September 07, 2023, 06:54:04 am »
Seeing that python is now at version 3.11.5, has anything been done about this?
Maybe in SE 28 - which I'll admit I haven't looked at yet.

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1810
  • Hero Points: 151
Re: Messages when debugging Python
« Reply #3 on: September 08, 2023, 02:14:27 pm »
I just built Python 3.11.5 and checked with v28, and no warnings.

I am missing the change to have the debugger add that -Xfrozen_modules flag automatically for 3.10 and above if it's not already in the command line.   I'll check that in for the next beta drop.

ebbe

  • Community Member
  • Posts: 38
  • Hero Points: 2
Re: Messages when debugging Python
« Reply #4 on: September 11, 2023, 10:02:04 am »
Thank you