From bbad30faf47c3b459789f73f8395abf3e8e88da7 Mon Sep 17 00:00:00 2001 From: rocky Date: Fri, 1 May 2026 11:57:48 -0400 Subject: [PATCH 1/3] bump version --- mathicsscript/version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mathicsscript/version.py b/mathicsscript/version.py index 34a121a..e6e15ac 100644 --- a/mathicsscript/version.py +++ b/mathicsscript/version.py @@ -4,4 +4,4 @@ # well as importing into Python. That's why there is no # space around "=" below. # fmt: off -__version__="10.0.0" # noqa +__version__="10.0.1.dev0" # noqa From 871038646aeeb077b4376dec9c66d52281fe3471 Mon Sep 17 00:00:00 2001 From: rocky Date: Fri, 1 May 2026 11:39:49 -0400 Subject: [PATCH 2/3] Misc small changes: format.py: boxes_to_xxx ->to_xxx. Therefore until the next mathics-core release, .github/workflows/* needs to build from GitHub pyproject.toml: add pyright config section --- .github/workflows/macos.yaml | 6 +----- .github/workflows/ubuntu.yml | 7 +------ .github/workflows/windows.yml | 6 +----- mathicsscript/format.py | 2 +- pyproject.toml | 11 +++++++++++ 5 files changed, 15 insertions(+), 17 deletions(-) diff --git a/.github/workflows/macos.yaml b/.github/workflows/macos.yaml index 1a99f73..eb8ee5c 100644 --- a/.github/workflows/macos.yaml +++ b/.github/workflows/macos.yaml @@ -33,11 +33,7 @@ jobs: # We can comment out after next Mathics3-pygments release # python -m pip install -e git+https://github.com/Mathics3/Mathics3-pygments#egg=Mathics3-pygments # We can comment out after next mathics-core release - # git clone --depth 1 https://github.com/Mathics3/mathics-core.git - # cd mathics-core/ - # pip install --no-build-isolation -e . - # bash -x admin-tools/make-JSON-tables.sh - # cd .. + pip install git+https://github.com/Mathics3/mathics-core.git - name: Install mathicsscript run: | make diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index be11464..2f8fccd 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -32,12 +32,7 @@ jobs: # We can comment out after next Mathics3-pygments release # python -m pip install -e git+https://github.com/Mathics3/Mathics3-pygments#egg=Mathics3-pygments # We can comment out after next mathics-core release - # cd .. - # git clone --depth 1 https://github.com/Mathics3/mathics-core.git - # cd mathics-core/ - # pip install --no-build-isolation -e . - # bash -x admin-tools/make-JSON-tables.sh - # cd .. + pip install git+https://github.com/Mathics3/mathics-core.git - name: Install mathicsscript run: | make diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 95e02a3..d79edea 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -33,11 +33,7 @@ jobs: # We can comment out after next Mathics3-pygments release # python -m pip install -e git+https://github.com/Mathics3/Mathics3-pygments#egg=Mathics3-pygments # We can comment out after next mathics-core release - # git clone --depth 1 https://github.com/Mathics3/mathics-core.git - # cd mathics-core/ - # pip install --no-build-isolation -e . - # bash -x admin-tools/make-JSON-tables.sh - # cd .. + pip install git+https://github.com/Mathics3/mathics-core.git - name: Install mathicsscript run: | make diff --git a/mathicsscript/format.py b/mathicsscript/format.py index 35a90eb..b2e06f6 100644 --- a/mathicsscript/format.py +++ b/mathicsscript/format.py @@ -224,7 +224,7 @@ def eval_boxed(result, fn: Callable, obj, **options): raise ValueError try: - boxes = result.boxes_to_text(evaluation=obj) + boxes = result.to_text(evaluation=obj) except BoxError: boxes = None if not hasattr(obj, "seen_box_error"): diff --git a/pyproject.toml b/pyproject.toml index 157bd17..5626d72 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -64,6 +64,17 @@ full = [ [project.urls] Homepage = "https://mathics.org/" +[tool.pyright] +include = ["mathicsscript"] +exclude = [ + "**/.pyodide*", + "**/node_modules", + "**/__pycache__" +] + +reportMissingImports = true +typeCheckingMode = "basic" + [tool.setuptools] packages = [ "mathicsscript", From e3fcfb72eba544963c662197f6d2802caabea3e6 Mon Sep 17 00:00:00 2001 From: rocky Date: Fri, 1 May 2026 11:57:15 -0400 Subject: [PATCH 3/3] lint --- mathicsscript/format.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/mathicsscript/format.py b/mathicsscript/format.py index b2e06f6..d539b12 100644 --- a/mathicsscript/format.py +++ b/mathicsscript/format.py @@ -22,7 +22,6 @@ SymbolInterpretationBox, SymbolMathMLForm, SymbolOutputForm, - SymbolPaneBox, SymbolPlot, SymbolStandardForm, SymbolTeXForm, @@ -148,7 +147,7 @@ def eval_boxed(result, fn: Callable, obj, **options): png_expr = Expression( SymbolExport, String(temp_png.name), expr, String("PNG") ) - result = png_expr.evaluate(obj) + png_expr.evaluate(obj) plt.axes().set_axis_off() img = mpimg.imread(temp_png) cmap = "gray" if expr.color_space == "Grayscale" else None