Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replacing a
BoxListitem with a dictionary stores a plaindict, so attribute access no longer works. For example, afterrows[0] = {"label": "updated"},rows[0].labelraisesAttributeError. Appending that same dictionary converts it to aBoxcorrectly.Apply the existing conversion helper to item and slice assignments, including a direct dotted index such as
"[0]". Replacements then receive the same nested conversion and options as appended values. The tests also check custom Box classes, intact types, slice iterators, invalid slice lengths, and frozen lists. Invalid slice steps are still rejected before reading replacement values. This addresses the behavior previously described in the closed PR #329.All 183 tests pass on Windows with Python 3.12, both from Python source and with Cython 3.3.0 extensions compiled and loaded. Twelve of the added cases fail on unchanged
develop; the twelve compatibility cases pass there. Black, mypy, the package build and Twine checks pass. Other Python versions, PyPy, Linux and macOS remain untested locally. Includes the changelog and contributor entries requested by the contribution guide, and targetsdevelop.