Macaulay2 / Macaulay2/M2

Use single documentation database

Open
#1,643 3 comments 0 reactions 1 assignee View on GitHub

@mahrud is already working on this.

Since Dec 13, 2020.

Documentation
Dominant language
Macaulay2
Stars
435
Forks
297
Avg merge
4d 20h
Merged PRs (30d)
11

Description

Fixing arguably the slowest part of installing the packages happens here:
https://github.com/Macaulay2/M2/blob/1e47260755100936bafd60d64013672dedd3941f/M2/Macaulay2/m2/document.m2#L319-L323
This also leads to awkward situations:

i1 : time html help "packages provided with Macaulay2";
[lots of warnings]
     -- used 6.60568 seconds

This is even the case in v1.16, by the way, nothing new. The reason is that html TO for each of the package links in that node calls getPrimaryTag -> fetchRawDocumentation -> needsPackage, as it need to read a key from the raw documentation database.

Typically installing the packages doesn't occur often, so it's not a big deal, but apparently html TO occurs much more often in the WebApp mode, and every time a new package is involved it needs to be loaded for the reasons above, causing warnings and delays.

Using a single documentation database instead would resolve this, because then you don't need to load a new package for even tasks as simple as getPrimaryKey.

cc: @pzinn

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.