Skip to content
4 changes: 2 additions & 2 deletions build/bin/sage-print-system-package-command
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ do
PROMPT="${1#--prompt=}"
;;
--prompt)
PROMPT=' $ '
CONTINUATION=' '
PROMPT='$ '
CONTINUATION=' '
;;
--continuation=*)
CONTINUATION="${1#--continuation=}"
Expand Down
24 changes: 12 additions & 12 deletions src/doc/en/developer/coding_in_other.rst
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ The ``gen`` class is defined in
:sage_root:`src/sage/libs/cypari2/gen.pyx`, and this is where we
add the method ``matfrobenius``:

.. CODE-BLOCK:: cython
.. code-block:: cython

def matfrobenius(self, flag=0):
r"""
Expand Down Expand Up @@ -102,7 +102,7 @@ class where we call the ``matfrobenius()`` method on the PARI object
associated to the matrix after doing some sanity checking. Then we
convert output from PARI to Sage objects:

.. CODE-BLOCK:: cython
.. code-block:: cython

def frobenius_form(self, flag=0, var='x'):
"""
Expand Down Expand Up @@ -171,7 +171,7 @@ For example, suppose we want to make a wrapper for the computation of
the Cartan matrix of a simple Lie algebra. The Cartan matrix of `G_2`
is available in GAP using the commands:

.. CODE-BLOCK:: gap
.. code-block:: gap

gap> L:= SimpleLieAlgebra( "G", 2, Rationals );
<Lie algebra of dimension 14 over Rationals>
Expand Down Expand Up @@ -202,7 +202,7 @@ can convert back to sage using the method ``sage`` if it works.

.. skip

.. CODE-BLOCK:: python
.. code-block:: python

def cartan_matrix(typ, rank):
"""
Expand Down Expand Up @@ -326,7 +326,7 @@ to carry this out.

Here is an example on how to use this command in Singular:

.. CODE-BLOCK:: text
.. code-block:: text

A Computer Algebra System for Polynomial Computations / version 3-0-0
0<
Expand Down Expand Up @@ -449,7 +449,7 @@ just that.

.. skip

.. CODE-BLOCK:: python
.. code-block:: python

def points_parser(string_points, F):
"""
Expand Down Expand Up @@ -509,7 +509,7 @@ ourselves to points of degree one.

.. skip

.. CODE-BLOCK:: python
.. code-block:: python

def places_on_curve(f, F):
"""
Expand Down Expand Up @@ -593,7 +593,7 @@ Next, we implement the general function (for brevity we omit the
docstring, which is the same as above). Note that the ``point_parser``
function is not required:

.. CODE-BLOCK:: python
.. code-block:: python

def places_on_curve(f, F):
p = F.characteristic()
Expand Down Expand Up @@ -634,7 +634,7 @@ For example, here is part of the file
defines an interface between Sage and Octave, an open source program
for doing numerical computations, among other things:

.. CODE-BLOCK:: python
.. code-block:: python

import os
from expect import Expect, ExpectElement
Expand All @@ -648,7 +648,7 @@ basic class for interfaces. The third line defines the class
``Octave``; it derives from ``Expect`` as well. After this comes a
docstring, which we omit here (see the file for details). Next comes:

.. CODE-BLOCK:: python
.. code-block:: python

def __init__(self, script_subdirectory="", logfile=None,
server=None, server_tmpdir=None):
Expand All @@ -666,7 +666,7 @@ docstring, which we omit here (see the file for details). Next comes:

This uses the class ``Expect`` to set up the Octave interface:

.. CODE-BLOCK:: python
.. code-block:: python

def set(self, var, value):
"""
Expand All @@ -692,7 +692,7 @@ These let users type ``octave.set('x', 3)``, after which
``octave.get('x')`` returns ``' 3'``. Running ``octave.console()``
dumps the user into an Octave interactive shell:

.. CODE-BLOCK:: python
.. code-block:: python

def solve_linear_system(self, A, b):
"""
Expand Down
12 changes: 7 additions & 5 deletions src/doc/en/developer/coding_in_python.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ Python language standard
Sage follows the time window-based support policy
`SPEC 0 — Minimum Supported Dependencies <https://scientific-python.org/specs/spec-0000/>`_
for Python versions.
The current minimum supported Python version can be found in the
``pyproject.toml`` file. Accordingly, only language and library features
available in this version can be used. If a feature is deprecated in a newer
The current minimum supported Python version can be found in the
``pyproject.toml`` file. Accordingly, only language and library features
available in this version can be used. If a feature is deprecated in a newer
supported version, it must be ensured that deprecation warnings issued by
Python do not lead to failures in doctests.

Expand Down Expand Up @@ -274,9 +274,11 @@ preparsed version of ``foo.sage`` is created with the name
This file was *autogenerated* from the file foo.sage.

You can explicitly preparse a file with the ``--preparse``
command-line option: running ::
command-line option: running

sage --preparse foo.sage
.. code-block:: console

$ sage --preparse foo.sage

creates the file ``foo.sage.py``.

Expand Down
Loading
Loading