Skip to content

Remove CIRCUITPY_8_9_WARNINGS and its usage. #10137

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Mar 18, 2025

Conversation

eightycc
Copy link
Collaborator

@eightycc eightycc commented Mar 18, 2025

Removes CIRCUITPY_8_9_WARNINGS and its usage.

Resolves #9596. Because the CIRCUITPY_8_9_WARNINGS macro was defined to (0) this change is ready to merge now.

@eightycc eightycc requested a review from dhalbert March 18, 2025 16:20
Copy link
Member

@tannewt tannewt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we actually want to enable this (and rename to CIRCUITPY_9_10_WARNINGS.)

In 10 we intended to remove these APIs and we want to start warning about it in 9.

// Remove these in CircuitPython 10
#if CIRCUITPY_BUSDISPLAY
{ MP_ROM_QSTR(MP_QSTR_Display), MP_ROM_PTR(&busdisplay_busdisplay_type) },
#endif
#if CIRCUITPY_EPAPERDISPLAY
{ MP_ROM_QSTR(MP_QSTR_EPaperDisplay), MP_ROM_PTR(&epaperdisplay_epaperdisplay_type) },
#endif
#if CIRCUITPY_FOURWIRE
{ MP_ROM_QSTR(MP_QSTR_FourWire), MP_ROM_PTR(&fourwire_fourwire_type) },
#endif
#if CIRCUITPY_I2CDISPLAYBUS
{ MP_ROM_QSTR(MP_QSTR_I2CDisplay), MP_ROM_PTR(&i2cdisplaybus_i2cdisplaybus_type) },
#endif

@tannewt
Copy link
Member

tannewt commented Mar 18, 2025

These warnings were disabled because we added them too early. Following their advice broke compatibility with CP 8. Now that we're done with 8, we can enable it. Once main is CP 10 then we can remove the old APIs.

@eightycc
Copy link
Collaborator Author

Made changes requested by @tannewt: Renamed CIRCUITPY_8_9_WARNINGS to CIRCUITPY_9_10_WARNINGS and turned it on for CP 9. Will create an additional PR for CP10 that removes the warnings and the attribute aliases.

@eightycc eightycc requested a review from tannewt March 18, 2025 22:46
@dhalbert
Copy link
Collaborator

NB: In #9096, we disabled the warnings, because they were intrusive, and I aid we'd turn them back on when 8.x bundles were no longer being built.

Copy link
Collaborator

@dhalbert dhalbert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and works as expected, with warnings showing when old bindings are used. Thanks!

@dhalbert dhalbert dismissed tannewt’s stale review March 18, 2025 23:27

request satisfied

@dhalbert dhalbert merged commit ed2ae0d into adafruit:main Mar 18, 2025
611 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CircuitPython 10: remove CIRCUITPY_8_9_WARNINGS
3 participants