Skip to content
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

remove adafruit_itertools layer from import #16

Merged
merged 4 commits into from
Jul 22, 2022

Conversation

FoamyGuy
Copy link
Contributor

resolves #15

Before change import syntax is like this:

from adafruit_itertools.adafruit_itertools import count

with this change this is the import:

from adafruit_itertools import count

We may want to consider renaming adafruit_itertools_extras to just extras.py? That way it's import would end up like this:

from adafruit_itertools.extras import repeatfunc

This one is a bit outside the scope of matching CPython if I understand correctly. I haven't made that change, but can if we want it that way.

This PR is a breaking change if merged so it would need a major version bump and find/update usages in learn guide ode and anywhere else it's used.

@FoamyGuy
Copy link
Contributor Author

Latest commit resolves an issue with the extras module not importing the main module utilities successfully after the change.

I tested the version from latest commits successfully with a Feather ESP32-S2 TFT and the simpletest script from this repo.

@tekktrik tekktrik self-requested a review June 16, 2022 14:32
@tekktrik
Copy link
Member

Ooo looks fun! I can take a look at this.

Copy link
Member

@tekktrik tekktrik left a comment

Choose a reason for hiding this comment

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

Good idea removing that layer and moving it into __init__.py! Didn't test but looks good to me!

@dhalbert dhalbert merged commit 3217815 into adafruit:main Jul 22, 2022
adafruit-adabot added a commit to adafruit/Adafruit_CircuitPython_Bundle that referenced this pull request Jul 23, 2022
Updating https://github.com/adafruit/Adafruit_CircuitPython_BME680 to 3.4.7 from 3.4.6:
  > Merge pull request adafruit/Adafruit_CircuitPython_BME680#51 from tekktrik/dev/populate-version
  > Changed .env to .venv in README.rst

Updating https://github.com/adafruit/Adafruit_CircuitPython_CircuitPlayground to 5.2.4 from 5.2.3:
  > Merge pull request adafruit/Adafruit_CircuitPython_CircuitPlayground#119 from adafruit/pypi
  > Removed duplicate-code from library pylint disable

Updating https://github.com/adafruit/Adafruit_CircuitPython_CLUE to 3.0.9 from 3.0.8:
  > Merge pull request adafruit/Adafruit_CircuitPython_CLUE#55 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_floppy to 1.0.3 from 1.0.2:
  > Merge pull request adafruit/Adafruit_CircuitPython_floppy#6 from adafruit/pypi
  > Removed duplicate-code from library pylint disable
  > Updated readthedocs

Updating https://github.com/adafruit/Adafruit_CircuitPython_INA219 to 3.4.16 from 3.4.15:
  > Merge pull request adafruit/Adafruit_CircuitPython_INA219#33 from tekktrik/dev/populate-version
  > Changed .env to .venv in README.rst

Updating https://github.com/adafruit/Adafruit_CircuitPython_MONSTERM4SK to 0.3.8 from 0.3.5:
  > Updated release.yml to most common version for testing
  > Update release.yml
  > Merge pull request adafruit/Adafruit_CircuitPython_MONSTERM4SK#13 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_OV2640 to 1.1.5 from 1.1.4:
  > Merge pull request adafruit/Adafruit_CircuitPython_OV2640#18 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_OV5640 to 1.1.6 from 1.1.2:
  > New release.yml but with single quotes
  > Rolled back release.yml version
  > Update setup.py
  > Merge pull request adafruit/Adafruit_CircuitPython_OV5640#15 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_OV to 1.0.7 from 1.0.6:
  > Merge pull request adafruit/Adafruit_CircuitPython_OV#16 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_PyPortal to 6.2.4 from 6.2.3:
  > Merge pull request adafruit/Adafruit_CircuitPython_PyPortal#122 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_RFM9x to 2.2.9 from 2.2.8:
  > Merge pull request adafruit/Adafruit_CircuitPython_RFM9x#79 from tekktrik/dev/populate-version
  > Changed .env to .venv in README.rst

Updating https://github.com/adafruit/Adafruit_CircuitPython_SHT31D to 2.3.15 from 2.3.14:
  > Merge pull request adafruit/Adafruit_CircuitPython_SHT31D#31 from tekktrik/dev/fix-toml
  > Merge pull request adafruit/Adafruit_CircuitPython_SHT31D#30 from tekktrik/dev/populate-version

Updating https://github.com/adafruit/Adafruit_CircuitPython_VEML7700 to 1.1.14 from 1.1.13:
  > Merge pull request adafruit/Adafruit_CircuitPython_VEML7700#22 from tekktrik/dev/populate-version
  > Changed .env to .venv in README.rst

Updating https://github.com/adafruit/Adafruit_CircuitPython_BoardTest to 1.2.13 from 1.2.12:
  > Merge pull request adafruit/Adafruit_CircuitPython_BoardTest#22 from adafruit/pypi
  > Removed duplicate-code from library pylint disable

Updating https://github.com/adafruit/Adafruit_CircuitPython_Colorsys to 2.0.10 from 2.0.9:
  > Merge pull request adafruit/Adafruit_CircuitPython_Colorsys#22 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_Dash_Dis to 1.1.9 from 1.1.8:
  > Merge pull request adafruit/Adafruit_CircuitPython_Dash_Dis#6 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_ESP32S2TFT to 1.1.3 from 1.1.1:
  > Rolled back release.yml
  > Merge pull request adafruit/Adafruit_CircuitPython_ESP32S2TFT#7 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_FunHouse to 2.1.15 from 2.1.14:
  > Merge pull request adafruit/Adafruit_CircuitPython_FunHouse#38 from adafruit/pypi
  > Removed duplicate-code from library pylint disable

Updating https://github.com/adafruit/Adafruit_CircuitPython_HTTPServer to 0.3.0 from 0.2.0:
  > Merge pull request adafruit/Adafruit_CircuitPython_HTTPServer#10 from karlfl/NonBlockingSocket

Updating https://github.com/adafruit/Adafruit_CircuitPython_IterTools to 2.0.0 from 1.1.10:
  > Merge pull request adafruit/Adafruit_CircuitPython_IterTools#16 from FoamyGuy/match_cpython_import
  > Merge pull request adafruit/Adafruit_CircuitPython_IterTools#17 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_MacroPad to 2.1.4 from 2.1.3:
  > Merge pull request adafruit/Adafruit_CircuitPython_MacroPad#42 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_MagTag to 2.1.12 from 2.1.11:
  > Merge pull request adafruit/Adafruit_CircuitPython_MagTag#87 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_MatrixPortal to 3.0.7 from 3.0.6:
  > Merge pull request adafruit/Adafruit_CircuitPython_MatrixPortal#87 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_PyBadger to 3.7.3 from 3.7.2:
  > Merge pull request adafruit/Adafruit_CircuitPython_PyBadger#60 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_PYOA to 2.5.7 from 2.5.6:
  > Merge pull request adafruit/Adafruit_CircuitPython_PYOA#35 from adafruit/pypi

Updating https://github.com/adafruit/Adafruit_CircuitPython_Bundle/circuitpython_library_list.md to NA from NA:
  > Added the following libraries: Adafruit_CircuitPython_CircuitPlayground, Adafruit_CircuitPython_CLUE, Adafruit_CircuitPython_floppy, Adafruit_CircuitPython_OV2640, Adafruit_CircuitPython_OV7670, Adafruit_CircuitPython_BoardTest, Adafruit_CircuitPython_Colorsys, Adafruit_CircuitPython_Dash_Display, Adafruit_CircuitPython_FunHouse, Adafruit_CircuitPython_IterTools, Adafruit_CircuitPython_MacroPad, Adafruit_CircuitPython_MagTag, Adafruit_CircuitPython_MatrixPortal, Adafruit_CircuitPython_PYOA
rtyley added a commit to rtyley/lego-tardis that referenced this pull request Oct 23, 2022
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.

Move library code out of inner directory
3 participants