Improve can.Bus typing by zariiii9003 · Pull Request #1557 · hardbyte/python-can
Conversation
Convert can.Bus into a function to clean up a lot of the messy typing. This should fix the pyright abstract class complaints.
I had to move the can.BusABC documentation from internal-api.rst to bus.rst, the private methods of can.BusABC are still documented in internal-api.rst.
zariiii9003
added
the
QA
label
Apr 4, 2023Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I took the liberty of reviewing the PR. I think this is a really nice change. I know that having both Bus and BusABC was something that confused me when I first started using python-can.
Thank you for taking a look. I will wait with merging until 4.2 is released.
I had the same experience with Bus and BusABC. 😄
I'd like to hear more opinions on this though.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job. I remember really struggling with the Bus/BusABC design many many years ago!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters