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

Expand objdeque implementation #9065

Merged
merged 5 commits into from
Mar 26, 2024

Conversation

SAK917
Copy link

@SAK917 SAK917 commented Mar 20, 2024

Fixes #8874
This PR expands CP collections.deque functionality to be more congruent with the CPython implementation by adding iteration, subscription and initialization as well as pop(), appendleft() and extend(). Tests for the new functionality are also provided.

This code is a copy of MP PR #10724 that was coded/submitted by LordFlashmeow and recently merged into MP. I have built and tested versions of CP with this code for RP2040, ESP32S2 and atmel-samd M4 boards and everything compiles and works as expected. I also confirmed that collections.deque is still not included in M0 builds as intended.

As per discussion with tannewt in CP Issue #8874: Deque is not iterable and on the discord circuitpython-dev channel, I am submitting this PR in the hopes the new functionality might be integrated into CP more quickly than the normal MP release / CP upstream merge cycle will take as I am using it for a current project. But if this PR creates more work or headaches, I can certainly wait and keep using a custom version of CP until the functionality is officially integrated.

Last but not least, this is my first PR to a large open-source project so if you have any suggestions or requests for what I can / should do differently please feel free to let me know.

@SAK917
Copy link
Author

SAK917 commented Mar 21, 2024

It looks like for the 494 checks, all of the baseline checks and all but two of the board builds passed:

The nordic/hiibot_bluefi board failed initializing submodules; and,

The silabs/devkit_xg24_brd2601b board failed building the en_US version (with Exit Code 2?). Is it possible that this may be caused by the additional functionality increasing the size of the en_US build beyond some limit? I ask because RAM usage for successful check builds of this board for many other languages indicated 100% RAM usage in the respective memory usage summaries.

I am afraid I am not sure how to troubleshoot these issues further as I am not that familiar with submodules nor builds of something as complex as CP, and the failure for the en_US silabs board build doesn't provide much information for amateur diagnosis. If there is anything I can do to help get this across the finish line, please let me know and I am happy to do whatever I can.

@dhalbert
Copy link
Collaborator

@SAK917 I will re-run the failed jobs. It is not uncommon for there to be CI glitches.

@SAK917
Copy link
Author

SAK917 commented Mar 21, 2024

Looks like that did the trick @dhalbert, all checks passed! Thanks for rerunning and I appreciate your help.

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.

Thank you! This will go in 9.1.0.

@dhalbert dhalbert merged commit c035ade into adafruit:main Mar 26, 2024
12 checks passed
This pull request was closed.
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.

Deque is not iterable
3 participants