Skip to content

Debugger crash with Python 3.14 #25299

@PJ-BR

Description

@PJ-BR

Context :
OS = Fedora 43
Python = 3.14
Spyder = 6.1.0 (installed from RPM) , previous version got same issue

Each time I try to debug a cell or script I got that in console and script doesn't run.

%debugcell -n inz ********.py
---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
File /usr/lib/python3.14/site-packages/IPython/core/debugger.py:496, in Pdb.print_stack_trace(self, context)
    495     if context <= 0:
--> 496         raise ValueError("Context must be a positive integer")
    497 except (TypeError, ValueError) as e:

ValueError: Context must be a positive integer

The above exception was the direct cause of the following exception:

ValueError                                Traceback (most recent call last)
File /usr/lib64/python3.14/bdb.py:899, in Bdb.run(self, cmd, globals, locals)
    897 self.start_trace()
    898 try:
--> 899     exec(cmd, globals, locals)
    900 except BdbQuit:
    901     pass

File ~/Dvt/Python/vlc_ubik.py:9
      7 raise RuntimeError('Must be run by cells')
      8 #%% inz
----> 9 import datetime
     10 import vlc
     11 import music.index

File /usr/lib64/python3.14/bdb.py:284, in Bdb.trace_dispatch(self, frame, event, arg)
    282     return # None
    283 if event == 'line':
--> 284     return self.dispatch_line(frame)
    285 if event == 'call':
    286     return self.dispatch_call(frame, arg)

File /usr/lib64/python3.14/bdb.py:310, in Bdb.dispatch_line(self, frame)
    303 """Invoke user function and return trace function for line event.
    304 
    305 If the debugger stops on the current line, invoke
    306 self.user_line(). Raise BdbQuit if self.quitting is set.
    307 Return self.trace_dispatch to continue tracing in this scope.
    308 """
    309 if self.stop_here(frame) or self.break_here(frame):
--> 310     self.user_line(frame)
    311     self.restart_events()
    312     if self.quitting: raise BdbQuit

File /usr/lib64/python3.14/pdb.py:547, in Pdb.user_line(self, frame)
    545         return
    546 self.bp_commands(frame)
--> 547 self.interaction(frame, None)

File /usr/lib/python3.14/site-packages/IPython/core/debugger.py:466, in Pdb.interaction(self, frame, tb_or_exc)
    464             OldPdb.interaction(self, frame, tb)
    465     else:
--> 466         OldPdb.interaction(self, frame, tb_or_exc)
    468 except KeyboardInterrupt:
    469     self.stdout.write("\n" + self.shell.get_exception_only())

File /usr/lib64/python3.14/pdb.py:736, in Pdb.interaction(self, frame, tb_or_exc)
    730 # We should print the stack entry if and only if the user input
    731 # is expected, and we should print it right before the user input.
    732 # We achieve this by appending _pdbcmd_print_frame_status to the
    733 # command queue. If cmdqueue is not exhausted, the user input is
    734 # not expected and we will not print the stack entry.
    735 self.cmdqueue.append('_pdbcmd_print_frame_status')
--> 736 self._cmdloop()
    737 # If _pdbcmd_print_frame_status is not used, pop it out
    738 if self.cmdqueue and self.cmdqueue[-1] == '_pdbcmd_print_frame_status':

File /usr/lib64/python3.14/pdb.py:1037, in Pdb.onecmd(self, line)
   1035         command, arg, line = self.parseline(line)
   1036         if hasattr(self, command):
-> 1037             return getattr(self, command)(arg)
   1038     return cmd.Cmd.onecmd(self, line)
   1039 else:

File /usr/lib64/python3.14/pdb.py:1217, in Pdb._pdbcmd_print_frame_status(self, arg)
   1216 def _pdbcmd_print_frame_status(self, arg):
-> 1217     self.print_stack_trace(0)
   1218     self._validate_file_mtime()
   1219     self._show_display()

File /usr/lib/python3.14/site-packages/IPython/core/debugger.py:498, in Pdb.print_stack_trace(self, context)
    496         raise ValueError("Context must be a positive integer")
    497 except (TypeError, ValueError) as e:
--> 498         raise ValueError("Context must be a positive integer") from e
    499 try:
    500     skipped = 0

ValueError: Context must be a positive integer

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions