Skip to main content

A Django-based frontend for Mathics3

Project description

CI status PyPI Installs Latest Version Supported Python Versions

Packaging status

This is the Django front-end to Mathics3.

Features:

  • Extensive online documentation

  • Integrated graphics, via three.js, and MathML mathematics output

  • Notebook-like sessions

See also Mathics3-live for a Webassembly-powered Python core backed by Pyodide, and this for other notebook front-ends.

ScreenShot

mathicsserver: a Django-based Web interface

mathicssserver

Installing

This package needs a working Mathics3 core engine, installed as well as a recent version of Django. For Django, you will need mysql or mariadb installed, since that is where worksheets are stored.

See the Installing Mathics3 for instructions on installing Mathics3.

If you are a novice at installing Python packages, consider using either a pre-built OS package if available under “Packaging status” above, or the Mathics3 docker image.

Ubuntu/Debian Specific OS dependent packages

On Ubuntu or Debian:

apt install default-libmysqlclient-dev.

Install from PyPI

Once Mathics3 is installed, run:

pip install Mathics3-Django

Install from the GitHub source

From the place root directory where GitHub was checked out:

make install

Running

This is a Django project, so Django’s manage.py script is used.

To start the webserver:

Mathics3Server

This runs the server in development mode. Here, when changes to the source code are made, the running server detects them and reloads the modified source.

To run Mathics3 Django in production mode and you have the Django ASGI server Daphne installed, run:

Mathics3Server --production

To get a list of the available Django commands, type:

Mathics3Server help

To get help on a specific Django command, give that command at the end. For example, two useful commands are the runserver and testserver commands:

python mathics_django/manage.py help runserver

To get a list of the available options for the Mathics3 Webserver, type:

Mathics3Server --help

Once the server is started, you will see a URL listed that might look like this:

...
Starting development server at http://localhost:8000/
Quit the server with CONTROL-C.

Point your browser to the URL listed above. Here it is http://localhost:8000

Environment Variables

There are two special environment variables of note that control where the Mathics3 database is located. This database saves authentication and worksheet information.

By default, the database used is DATADIR + mathics.sqlite where DATADIR is under AppData/Python/Mathics3/ for MS-Windows and ~/.local/var/Mathics3/ for all others. If you want to specify your own database file, set the environment variable MATHICS3_DJANGO_DB_PATH.

If you just want to set the mathics3.sqlite portion, you can use the environment variable MATHICS3_DJANGO_DB.

Information for the online documentation comes from one of two places, DOC_USER_HTML_DATA_PATH if that exists and DOC_SYSTEM_HTML_DATA_PATH as a fallback if that doesn’t exist. The latter is created when the package is built. The former allows the user or developer to update this information. In the future, it will take into account plugins that have been added.

Contributing

We encourage you to contribute to Mathics3! Create your own fork, make the desired changes, commit, and make a pull request.

License

Mathics3-django is released under the GNU General Public License Version 3 (GPL3).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mathics3_django-10.0.0.tar.gz (23.8 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mathics3_django-10.0.0-py3-none-any.whl (25.0 MB view details)

Uploaded Python 3

File details

Details for the file mathics3_django-10.0.0.tar.gz.

File metadata

  • Download URL: mathics3_django-10.0.0.tar.gz
  • Upload date:
  • Size: 23.8 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for mathics3_django-10.0.0.tar.gz
Algorithm Hash digest
SHA256 0db730d7dc9799bee34e95c12130be6b021d506e1beb362fd9544a433eaeb4f2
MD5 445be5a6ee8024d63cedc402cffca8b2
BLAKE2b-256 a9789d1453f26d3a3a9158c2b96bef313d84e9f804b1af8bfc831433803c919d

See more details on using hashes here.

File details

Details for the file mathics3_django-10.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for mathics3_django-10.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6049777cd2ceb98dfa7af6ebb5c6b1ebd7dcbd1ae075761cc88627fbbe845dfd
MD5 4eb9529151456f023c2e0b7a9996805f
BLAKE2b-256 fe8a1a54766d6ebec9bc8b506d29479463f02cedbc95122e3203cbf364c5b79b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page