Repository navigation
fix(corekit): resolve PortEnumField misses for any proto; restate its peek (#1774) - #1781
Merged
Merged
Conversation
… peek (#1774) PortEnumField.post_process peeks at the registry rows and _missing_'s spans before calling AppType.get. Its Notes said this stops get minting a member per ephemeral port; since #860 get no longer mints, and neither path grows the registry (measured on TCP, UDP, SCTP and DCCP). The peek is still needed: get's miss member has no __reduce_ex__, so pickle.loads raises "'unknown [50000 - tcp]' is not a valid TCP", and is named 'unknown', so it dumps as TCP::unknown, not TCP::<unassigned>. - Notes: give that reason, and drop EnumField._unregistered_member's claim that get mints PORT_54321_tcp. - Miss branch: take the transport from owner.__transport__, as get does. A str proto ('tcp') or a composite (tcp | udp, a bare int) has no .name, so a miss raised AttributeError. - New tests fail with the peek or the transport fix reverted. Closes #1774
Owner
Author
|
Verdict: GOOD TO GO at |
This was referenced Oct 15, 2026
JarryShaw
added a commit
that referenced
this pull request
Oct 15, 2026
…1803) Entries: - add #1791 (breaking: pack() leaves its instance unchanged), #1778 (Protocol in protocol.__all__), #1781 (PortEnumField miss with a nameless proto), #1779 (vendor.ipx _path), #1780 (examples READMEs to Markdown, build leftovers) and #1790 (36 ambiguous cross-references) - fold #1776 into the RPL 0x23 entry and #1381 into the dump-schema one Accuracy: - the benchmark and legacy_smoke READMEs are README.md since #1780 - EngineBase stays out of __all__, as #1016 settled - the #575 peek calls get() only once the value resolves - the #647 and #764 entries point at #775/#860, under which nothing mints - the #861 entry names #869 and #874 for the EnumRegistry move Figures: - preamble: 685 citations, #340 to #1791 - process.rst pin: 298 entries; CHANGELOG.md regenerated Refs #1103
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.
Please follow the guide below
You will be asked some questions, please read them carefully and answer honestly
Put an
xinto all the boxes [ ] relevant to your pull request (like that [x])Use Preview tab to see how your pull request will actually look like
Searched for similar pull requests
Followed the coding style (
make pylint,make mypy,make isort)make testpasses, and a test case covers the change. Narrow runs only, listed below.Added a changelog entry under
docs/source/changelog/and regeneratedCHANGELOG.md, if the change is user-visible: N/A — centralised in docs(changelog): shared 1.5.0 changelog — long-lived, merges last (#610, #616, #617, #618, #620) #657What is the purpose of your pull request?
Tick the commit type your subject line carries.
fix— corrects a defectfeat— adds a featureperf— changes performance, not behaviourrefactor— changes neither behaviour nor performancetest— tests onlydocs— documentation onlyci— workflows or build toolingrelease— bumps the version or rolls up a distributionchore— anything elseSummary
PortEnumField.post_processpeeks at the registry before callingAppType.get. Its Notes said the peek stopsgetminting a member per ephemeral port, but since #860getno longer mints. The peek is still needed for a different reason:get's miss member does not pickle, and it dumps asTCP::unknown, notTCP::<unassigned>.owner.__transport__, asgetdoes. Astrproto ('tcp') or a composite (tcp | udp, a bare int) has no.name, so a miss raisedAttributeError.EnumField._unregistered_memberdrops the claim thatgetmintsPORT_54321_tcp. Rebased ontomainpast docs(corekit): version directives and render fixes (#1103) #1762's edits to the same docstrings.tests/projectgreen.Closes #1774