ENH: Rename exps_comm_* commission cells to commissions_*#102
Merged
Conversation
Continues the cell-naming standardization started in 3f738b3. The umbrella cell ``commissions(t)`` already aggregates initial and renewal commissions, but the components still carried the legacy ``exps_comm_*`` prefix. Rename them so the family mirrors the ``claims_*`` / ``claims_*_pp`` pattern: - ``exps_comm_init`` -> ``commissions_init`` - ``exps_comm_ren`` -> ``commissions_ren`` - ``exps_comm_init_pp`` -> ``commissions_init_pp`` - ``exps_comm_ren_pp`` -> ``commissions_ren_pp`` Updates the call sites in ``commissions`` and ``expenses``, the ``Exps`` docstring example (now ``exps_maint``, since no ``exps_comm_*`` cell remains), and the autosummary / autofunction entries in ``BaseProj.rst``. Verified by ``test_tradlife_a`` (3/3 pass) and a smoke check under ``Projection[1]`` confirming ``commissions(0)``, ``commissions_init``, ``commissions_ren`` and the ``_pp`` siblings produce the expected non-zero values. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
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.
Summary
3f738b3cell-naming standardization inTradLife_A.BaseProjby bringing the commission components under the existingcommissions(t)umbrella, mirroring theclaims_*/claims_*_pppattern.exps_comm_init→commissions_init,exps_comm_ren→commissions_ren,exps_comm_init_pp→commissions_init_pp,exps_comm_ren_pp→commissions_ren_pp. Updates call sites incommissions/expensesand the autosummary/autofunction entries inBaseProj.rst.Expsdocstring example toexps_maint(noexps_comm_*cell remains as a representative).Notes for reviewers
data.pickleand the_data/directory were intentionally untouched — modelx reads cell definitions from__init__.py, and the prior standardization commit followed the same approach.tradlife_a-space-overview.ipynbis left to regenerate naturally on the next notebook execution.Test plan
pytest lifelib/tests/libraries/test_tradlife_a.py— 3/3 passProjection[1]exercise:commissions_init(0) = 588.47,commissions_ren(1) = 135.31,commissions_init_pp(0) = 588.47,commissions_ren_pp(1) = 147.12, withcommissions(0) = commissions_init(0)as expected🤖 Generated with Claude Code