adafruit / Adafruit_CircuitPython_DisplayIO_SSD1306

DisplayIO driver for SSD1306 monochrome OLED displays
MIT License
60 stars 24 forks source link

update needed for CP 9 to use busdisplay to eliminate FutureWarnings #37

Closed jerryneedell closed 7 months ago

jerryneedell commented 10 months ago

When this library is used with CP9 some "FutureWarnings" are generated due to this line

https://github.com/adafruit/Adafruit_CircuitPython_DisplayIO_SSD1306/blob/main/adafruit_displayio_ssd1306.py#L62 class SSD1306(displayio.Display): I think it just needs to be changed to: class SSD1306(busdisplay.BusDisplay): as well as importing busdisplay instead of displayio

Is this already planned for update when CP9 is released? I suppose it will need to check for the CP release for backward compatibility.

I imagine there will be many guide updates as well when CP9 is released. https://learn.adafruit.com/adafruit-oled-featherwing/python-usage and had to make a new changes to code.py but also had to update the library as noted to eliminate all warnings.

I just wanted to open this as a warning to other users. Feel free to close it if this is being dealt with in another way.

Since the FutureWarnings are just Warnings, it works fine as is but the warnings can be annoying.

tannewt commented 9 months ago

Ya, the plan is to update everything once 9.0 is stable and it's been long enough for folks to be using it by default. You can disable the warning output in the meantime.