bindings: python: convert lines to offsets in LineRequest
Remove `_check_line_name` in favor of a new function, `_line_to_offset`,
that converts a line reference to an offset.
This new function helps narrow types and simplifies the iteration logic
that is used to build objects to interface with `_ext.Request`.
Signed-off-by: Vincent Fazio <vfazio@xes-inc.com>
Link: https://lore.kernel.org/r/20241114145116.2123714-13-vfazio@xes-inc.com
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>