Ticket #7897 (needs_review defect)

Opened 2 months ago

Last modified 6 weeks ago

Macaulay2 interface update/improvement for version 1.3.1

Reported by: novoselt Owned by: was
Priority: major Milestone:
Component: interfaces Keywords: Macaulay2, interface
Cc: Author(s): Andrey Novoseltsev
Report Upstream: N/A Reviewer(s):
Merged in: Work issues:

Description (last modified by novoselt) (diff)

See also #5467 and #7915 (!).

These patches change the prompt detection/stripping and update doctests to cause no errors with Macaulay2 1.3.1.

Improvements/fixes achieved:

  • examples in Macaulay2 documentation (which include input prompts) do not break the interaction with Sage;
  • empty/whitespace/comment lines can be executed;
  • multiline commands can be executed;
  • stripping output prompts will not cut error messages if they occur (e.g. the first call "help Thing" currently shows some errors in Macaulay2);
  • "macaulay2.restart()" does not print a useless variable name.

This is done by:

  • changing input and input continuation prompts;
  • starting with a big line number to make all output labels of the same width;
  • making sure that only output labels and spaces are stripped from the output.

These patches make tickets #7882 and #7888 unnecessary.

Attachments

macaulay2_doctests_update.patch Download (9.1 KB) - added by novoselt 2 months ago.
improve_macaulay2_prompt_detection.patch Download (4.2 KB) - added by novoselt 2 months ago.
trac_7897_improve_macaulay2_prompt_detection.patch Download (4.4 KB) - added by novoselt 7 weeks ago.
trac_7897_macaulay2_doctests_update.patch Download (9.4 KB) - added by novoselt 7 weeks ago.

Change History

Changed 2 months ago by novoselt

Changed 2 months ago by novoselt

  • status changed from new to needs_review

Changed 2 months ago by novoselt

Changed 2 months ago by novoselt

  • description modified (diff)

I changed my mind about importance of "restart" command in the middle of the code after seeing a talk today. So the patch is rewritten to allow it everywhere. All doctests still pass with both patches applied.

Changed 7 weeks ago by novoselt

Changed 7 weeks ago by novoselt

Changed 7 weeks ago by novoselt

Renamed patches and commit messages to follow conventions. Apply both patches starting with "trac_7897"

Changed 6 weeks ago by was

  • description modified (diff)

Changed 6 weeks ago by novoselt

  • description modified (diff)
Note: See TracTickets for help on using tickets.