Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Ensures native attr handlers process subclass attribute stores#18594

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Draft
cnadler86 wants to merge1 commit intomicropython:master
base:master
Choose a base branch
Loading
fromcnadler86:fix/18592

Conversation

@cnadler86
Copy link

Summary

Fixes incorrect delegation of attribute assignment in subclasses of native types with custom attribute handlers by ensuring the handler is invoked before storing attributes in the instance dictionary. Adds tests to verify correct behavior for both native and subclassed types.

Fixes#18592

Testing

See test added

Trade-offs and Alternatives

TBD

Fixes incorrect delegation of attribute assignment in subclassesof native types with custom attribute handlers by ensuring thehandler is invoked before storing attributes in the instancedictionary. Adds tests to verify correct behavior for bothnative and subclassed types.
@codecov
Copy link

codecovbot commentedDec 19, 2025

Codecov Report

❌ Patch coverage is86.66667% with2 lines in your changes missing coverage. Please review.
✅ Project coverage is 98.37%. Comparing base (6341258) to head (c37c94f).

Files with missing linesPatch %Lines
py/objtype.c86.66%2 Missing⚠️
Additional details and impacted files
@@            Coverage Diff             @@##           master   #18594      +/-   ##==========================================- Coverage   98.38%   98.37%   -0.01%==========================================  Files         171      171                Lines       22298    22313      +15     ==========================================+ Hits        21937    21950      +13- Misses        361      363       +2

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report?Share it here.

🚀 New features to boost your workflow:
  • ❄️Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions
Copy link

Code size report:

Reference:  esp32/mpconfigport: Enable Zcmp opcodes for ESP32P4. [6341258]Comparison: Ensures native attr handlers process subclass attribute stores [merge of c37c94f]  mpy-cross:  +192 +0.051%    bare-arm:  +112 +0.198% minimal x86:  +207 +0.110%    unix x64:  +296 +0.034% standard      stm32:  +104 +0.026% PYBV10     mimxrt:   +96 +0.025% TEENSY40        rp2:  +104 +0.011% RPI_PICO_W       samd:  +104 +0.038% ADAFRUIT_ITSYBITSY_M4_EXPRESS  qemu rv32:  +122 +0.027% VIRT_RV32

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Python subclass of native type with attr handler cannot properly store attributes

1 participant

@cnadler86

[8]ページ先頭

©2009-2025 Movatter.jp