GH-103319: Fix `inspect.getsourcelines()` to return 1-based line numbers by artemmukhin · Pull Request #103226 · python/cpython
The doc of inspect says this function Return a list of source lines and starting line number for an object. In my opinion, starting line number should not be 0. How is "starting from 0" and "starting from 1" different? They all include line 1 and there's no line 0. The fundamental of 0-based is that [0] means something and that's not the case in line number.
I would think this as a bug, but it's true that this is a breaking behavior. If we kept it as it is in inspect, I'd like to fix it in pdb.