Re: [PATCH v1] py-gdb-readline: replace deprecated interfaces in GdbRemoveReadlineFinder
Tom de Vries <[email protected]> Wed, 5 Aug 2026 15:17:40 +0200
| Newsgroups | gmane.comp.gdb.patches |
|---|---|
| Message-ID | <[email protected]> |
On 1/13/26 5:25 PM, Tom Tromey wrote: >>>>>> "Matthieu" == Matthieu Longo <[email protected]> writes: > > Matthieu> A previous patch [1] enabled readline in Python in a GDB-specific way > Matthieu> and blocked the standard Python readline module to prevent conflicts > Matthieu> with GDB by adding a custom importer raising an exception for the readline > Matthieu> module. > > I wonder if gdb could do better here. To be clear, not your problem. > > Matthieu> This patch uses Patryk Sondej's approach detailed in bug 32473, but with > Matthieu> a slight variation regarding the finder insertion in sys.meta_path. > Matthieu> It also adds a new test to prevent future regression. > > Seems reasonable to me, though this isn't an area I know very well. > > Approved-By: Tom Tromey <[email protected]> I reproduced this regression on the gdb-17-branch with python 3.6 (and later as well), and can confirm that backporting the patch to the gdb-17-branch fixes it. I'm not able to test with python 3.4 though, otherwise I would apply it to the branch. Thanks, - Tom > > Tom