Solution to issue cannot be found in the documentation.
[X] I checked the documentation.
Issue
matplotlib removed the OldScalarFormatter in 3.5.0. This is used by SageMath<9.2. Consequently some plotting is broken resulting in:
doctest:warning
File "/usr/share/miniconda/envs/test/bin/sage-runtests", line 179, in <module>
err = DC.run()
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/control.py", line 1232, in run
self.run_doctests()
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/control.py", line 933, in run_doctests
self.dispatcher.dispatch()
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/forker.py", line 2033, in dispatch
self.parallel_dispatch()
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/forker.py", line 1925, in parallel_dispatch
w.start() # This might take some time
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/forker.py", line 2200, in start
super(DocTestWorker, self).start()
File "/usr/share/miniconda/envs/test/lib/python3.7/multiprocessing/process.py", line 112, in start
self._popen = self._Popen(self)
File "/usr/share/miniconda/envs/test/lib/python3.7/multiprocessing/context.py", line 223, in _Popen
return _default_context.get_context().Process._Popen(process_obj)
File "/usr/share/miniconda/envs/test/lib/python3.7/multiprocessing/context.py", line 277, in _Popen
return Popen(process_obj)
File "/usr/share/miniconda/envs/test/lib/python3.7/multiprocessing/popen_fork.py", line 20, in __init__
self._launch(process_obj)
File "/usr/share/miniconda/envs/test/lib/python3.7/multiprocessing/popen_fork.py", line 74, in _launch
code = process_obj._bootstrap()
File "/usr/share/miniconda/envs/test/lib/python3.7/multiprocessing/process.py", line 297, in _bootstrap
self.run()
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/forker.py", line 2172, in run
task(self.options, self.outtmpfile, msgpipe, self.result_queue)
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/forker.py", line 2504, in __call__
doctests, extras = self._run(runner, options, results)
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/forker.py", line 2553, in _run
result = runner.run(test)
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/forker.py", line 897, in run
return self._run(test, compileflags, out)
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/forker.py", line 681, in _run
self.compile_and_execute(example, compiler, test.globs)
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/doctest/forker.py", line 1123, in compile_and_execute
exec(compiled, globs)
File "<doctest flatsurf.geometry.hyperbolic.HyperbolicConvexSet.plot[2]>", line 1, in <module>
H.vertical(Integer(0)).plot()
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/repl/rich_output/display_manager.py", line 811, in displayhook
plain_text, rich_output = self._rich_output_formatter(obj, dict())
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/repl/rich_output/display_manager.py", line 625, in _rich_output_formatter
rich_output = self._call_rich_repr(obj, rich_repr_kwds)
File "/usr/share/miniconda/envs/test/lib/python3.7/site-packages/sage/repl/rich_output/display_manager.py", line 592, in _call_rich_repr
RichReprWarning,
File "/usr/share/miniconda/envs/test/lib/python3.7/warnings.py", line 110, in _showwarnmsg
msg.file, msg.line)
:
sage.repl.rich_output.display_manager.RichReprWarning: Exception in _rich_repr_ while displaying object: cannot import name 'OldScalarFormatter' from 'matplotlib.ticker' (/usr/share/miniconda/envs/test/lib/python3.7/site-packages/matplotlib/ticker.py)
We should probably patch the metadata and add a run constraint.
Solution to issue cannot be found in the documentation.
Issue
matplotlib removed the
OldScalarFormatter
in 3.5.0. This is used by SageMath<9.2. Consequently some plotting is broken resulting in:We should probably patch the metadata and add a run constraint.
Installed packages
Environment info