On Tue, Oct 8, 2024 at 2:38 PM Vincent Fazio <vfazio@xxxxxxxxxxx> wrote: > > It's mostly just a convenience/cosmetic thing. > > All of the other classes, including the Exceptions, were exported, I thought > maybe the intent was to expose everything and that the line Enums were simply > an oversight. I misinterpreted our conversation on GH: > Exceptions are fine, their names indicate what they mean. > Me: Right now, the objects in `gpiod.line` are hidden behind `line.X` or > require explicit import via `from gpiod.line import X, Y` > > You: And that is an omission from my side. > I'm not sure what I meant here anymore. :( > The main benefit is that all gpiod classes are directly available from the main > module so consumers don't have to hunt down the import path for the line Enums > or have extended type hints a la: > > def fn(arg: gpiod.line.Value) -> None: ... > > or > > def fn(arg: line.Value) -> None: ... > > It's cosmetic and can be solved with an additional import so isn't a huge deal. > > I can certainly restore the previous behavior for these Enums. > . Yes, I would like to keep these enums behind the line package. Bart