Opened 15 years ago

Closed 15 years ago

#406 closed defect (fixed)

[with patch; positive review] notebook -- make tab completion not stick gap. when using the notebook in gap mode

Reported by: William Stein Owned by: Kelly Boothby
Priority: blocker Milestone: sage-3.0.2
Component: notebook Keywords:
Cc: Merged in:
Authors: Reviewers:
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description (last modified by William Stein)

On 7/26/07, Dan Christensen <jdc@uwo.ca> wrote:
> 3) When I try to use tab completion, it inserts "gap." before the
> command (and probably ignores functions not wrapper by sage).

Attachments (1)

sage-406.patch (7.0 KB) - added by William Stein 15 years ago.

Download all attachments as: .zip

Change History (8)

comment:1 Changed 15 years ago by Dan Christensen

4) If I use GAP Print(...) commands in a short notebook entry, I see the output. But if the entry is longer, I don't see the output.

comment:2 Changed 15 years ago by Michael Abshoff

Milestone: sage-3

comment:3 Changed 15 years ago by William Stein

Description: modified (diff)
Summary: notebook -- improve support for other system modesnotebook -- make tab completion not stick gap. when using the notebook in gap mode

In order to focus this ticket, I've broken up each issue into separate tickets and made this ticket just issue 3 in the original description, which is below

On 7/26/07, Dan Christensen <jdc@uwo.ca> wrote:
> Some other minor issues about using GAP within the notebook, under
> 2.7.1.  I've put my entire worksheet in GAP mode using the menu at
> the top.  The following things don't work correctly:
> 
> 0) If I type something that gives an error in GAP, the error
> message is buried in a python exception/backtrace.
> 
> 1) If I type "?SymmetricGroup" (which works within GAP), all I see
> is
> 
>    Help: Showing `Reference: SymmetricGroup'
>    Page from 104
> 
> It's similar with other "?foo" commands.
> 
> 2) If I type "SymmetricGroup?" and hit tab, it shows me help about
> sage's wrapped SymmetricGroup function.  I don't think this will
> be helpful for functions not wrapped by sage.
> 
> 3) When I try to use tab completion, it inserts "gap." before the
> command (and probably ignores functions not wrapper by sage).

I am aware of each of these issues (which also happen with
the other interfaces).  They are *not* features in my mind, but
bugs, and they need to be fixed by somebody (either me or
somebody else). 

William

Changed 15 years ago by William Stein

Attachment: sage-406.patch added

comment:4 Changed 15 years ago by William Stein

Milestone: sage-featuresage-3.0.2
Priority: majorblocker
Summary: notebook -- make tab completion not stick gap. when using the notebook in gap mode[with patch; needs review] notebook -- make tab completion not stick gap. when using the notebook in gap mode
Type: enhancementdefect

Trac #406:

  1. Fix the problem where hitting tab when switched into another worksheet mode sticks system. at the front of each completion. Similar fixes for help via foo([tab key}] and source code via foo??[tab].
  1. When switching systems, get rid of the very annoying confirmation dialog. (Just commented it out for now.)
  1. Fix *very serious* bug that prevented loading a worksheet that was set to an optional mode. In sage-3.0.1 loading a worksheet that is in an optional mode (e.g., mathematica or maple or Magma, say) was completely broken. This patch fixes that problem.

NOTE: This patch has no new tests illustrating that ift fixes anything, since we have no automated way of testing any of the above right now.

comment:5 Changed 15 years ago by Nils Bruin

Summary: [with patch; needs review] notebook -- make tab completion not stick gap. when using the notebook in gap mode[with patch; needs more qualified review] notebook -- make tab completion not stick gap. when using the notebook in gap mode

Patch works for me -- I have only tested that tab completion for magma is now useful. In terms of refereeing the patch, I only understood the x[len(prepend):] bit and that seems plausible to me.

comment:6 Changed 15 years ago by mhampton

Summary: [with patch; needs more qualified review] notebook -- make tab completion not stick gap. when using the notebook in gap mode[with patch; positive review] notebook -- make tab completion not stick gap. when using the notebook in gap mode

This seems to fix the problem (part 3, that is, the others are #3152). I tested it in R mode, latex mode, gap mode, and python mode. All of these saved/reloaded OK, and were robust under switching between modes. Command completion appears fixed in R and gap (btw it would be pretty cool to have latex command completion but I assume that would be a pain). Since this is a second opinion I think it is time to give a full positive review and start merging it in.

comment:7 Changed 15 years ago by Michael Abshoff

Resolution: fixed
Status: newclosed

Merged in Sage 3.0.2.alpha1

Note: See TracTickets for help on using tickets.