Repository navigation
feat(GG-3824): Add LogBase and explicit errors for impossible calculations - #3
Open
yohanpainchaud-gg wants to merge 1 commit into
Open
yohanpainchaud-gg wants to merge 1 commit into
yohanpainchaud-gg wants to merge 1 commit into
Conversation
yohanpainchaud-gg
force-pushed
the
feature/GG-3824
branch
from
November 25, 2026 07:51
1ec1b9c to
c64b8b1
Compare
…tions - ["LogBase", x, b]: logarithm in base b, exact for bases 10 and 2. ["Log", x] stays the natural logarithm, whatever its base. - MathJSONDomainError: logarithm of a number <= 0, base <= 0 or equal to 1, even or fractional root of a negative number, power of a negative number with a non-integer exponent. No complex result any more; an odd root of a negative number is real. - MathJSONOverflowError / MathJSONUnderflowError: finite operands giving a non-finite, too large or too small (0.0) result. Infinite and NaN values coming from the parameters raise neither. - MathJSONUnsupportedOperator: in strict mode, a formula whose operator is unknown. Lists given as parameter values stay data. - If and Map let these errors through instead of swallowing them. - Power of integers still gives an integer. Package version 1.14.0.post5, for tag 1.10.0-5. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
yohanpainchaud-gg
force-pushed
the
feature/GG-3824
branch
from
November 25, 2026 19:48
c64b8b1 to
cb0cc40
Compare
yohanpainchaud-gg
changed the base branch from
main
to
ci/GG-3824-python-3.14
November 25, 2026 19:48
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.
Niveau : critique — moteur de calcul des résultats diagnostiques (SOUP)
Contrat : https://app.clickup.com/t/1240ccep35e
Version paquet
1.14.0.post5, tag à publier1.10.0-5. Basée sur la PR de CI.Ce qui change
["LogBase", x, b], exacte en bases 10 et 2 ;["Log", x]reste un ln.Root(-8, 3)= −2.infouNaNvenu des paramètres se propage sans erreur ; seuls des opérandes finis déclenchent.IfetMaplaissent passer ces erreurs :IfsurLog10(0)n'emprunte plus la branche « sinon ».Échecs couverts
Log10(0),Ln(0),LogBase(10, 1),Sqrt(-4),Root(-16, 4),Power(-8, 0.5)MathJSONDomainErrortest_domain_errorRoot(-8, 3),LogBase(8, 2),LogBase(1000, 10)test_calculator_operationsPower(10, 400),Exp(1000),Multiply(1e300, 1e300)MathJSONOverflowErrortest_overflow_errorPower(10, -400),Exp(-1000)MathJSONUnderflowErrortest_underflow_errorinfvenu des données × 100 < 50test_non_finite_data_go_throughFloor,Sinen strictMathJSONUnsupportedOperatortest_unsupported_operator_raises_in_strict_modeConstantsou le contexte, en stricttest_list_parameters_are_data_in_strict_modeIfouMaptest_if_and_map_let_calculation_errors_throughPower(2, 3),Switchsur une puissancetest_integer_power_stays_an_integerLire dans cet ordre
src/mathjson_solver/__main__.py—power,root,log_base,finite, puis les opérateurs etIf/Maptests/test_with_pytest.py— scénarios du contrat et non-régressionCHANGELOG.md— changements de comportement à connaître côté backREADME.md— erreurs et mode strictPreuves de revue
REVIEW_GATE: NEEDS_HUMAN
SCOPE: ci/GG-3824-python-3.14...feature/GG-3824
REVIEWERS: delivery-auditor, change-reviewer, finding-verifier
CHECKS: git diff --check : OK ; python -m pytest -q tests : 346 passed ; suite dpcr-back (837 tests) avec ce solver installé : 837 passed
REASON: fiche SOUP et SBOM de la nouvelle version à mettre à jour hors du dépôt ; classement des nouvelles erreurs côté back (GG-3825) à livrer avec la montée de version
🤖 Generated with Claude Code