Skip to content

Conversation

pantheraleo-7
Copy link

@pantheraleo-7 pantheraleo-7 commented Dec 7, 2024

Addresses #100

This PR chooses one of the many ways described in the issue. This seems like the most intuitive way but if any of the other ways are selected (if at all!) then I'll change the PR accordingly.

If the PR gets accepted, I'll be willing to update examples, docs, etc.

Per this PR, the usage example would like this:

import board
from adafruit_ads1x15 import ADS1115, AnalogIn, ads1x15

i2c = board.I2C()
ads = ADS1115(i2c)
chan = AnalogIn(ads, ads1x15.PIN0)

I'd say this is more pythonic and readable. This change is completely backwards compatible.

@pantheraleo-7
Copy link
Author

Hmm.. seems like pylint doesn't recognise redundant aliases. Ruff, pyflake, etc. recommend redundant aliases for re-exports.

@pantheraleo-7 pantheraleo-7 marked this pull request as ready for review April 6, 2025 07:55
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.

1 participant