Opened 13 years ago

Closed 11 years ago

Last modified 11 years ago

#3091 closed enhancement (duplicate)

help() should give Sage help, not Python

Reported by: gnprice Owned by: was
Priority: major Milestone: sage-duplicate/invalid/wontfix
Component: user interface Keywords:
Cc: jhpalmieri Merged in:
Authors: Reviewers:
Report Upstream: N/A Work issues: Close as fixed
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description

When I fired up Sage having never used it before, the first thing I tried after '1+1' and 'f(x) = x + x' followed by 'f(2)' was 'help'. I was disappointed to see that it gave the Python help system. I know Python, and I suspect even most Sage users who don't are more likely to want Sage help than Python help when they start out.

sage: help
Type help() for interactive help, or help(object) for help about object.
sage: help()

Welcome to Python 2.5!  This is the online help utility.

If this is your first time using Python, you should definitely check out
the tutorial on the Internet at http://www.python.org/doc/tut/.

Enter the name of any module, keyword, or topic to get help on writing
Python programs and using Python modules.  To quit this help utility and
return to the interpreter, just type "quit".

To get a list of available modules, keywords, or topics, type "modules",
"keywords", or "topics".  Each module also comes with a one-line summary
of what it does; to list the modules whose summaries contain a given word
such as "spam", type "modules spam".

help> 

I wound up using 'locals()' to see what was around -- a Python trick -- then 'help' on individual values that looked interesting. I still don't know how to find introductory, overview help on Sage from the interactive prompt, or a list of functions without using tricks from a Python background. I'm sure there's documentation on the web, but it's nice to be able to get to it while at the prompt.

Of course the native Python 'help' function is invaluable for printing and paging through docstrings, once one knows the name of something. I'm referring to its behavior with no arguments -- it should begin to give a clue about syntax, what's available, and where to look on the web, for Sage rather than for Python.

Thanks!

Change History (6)

comment:1 Changed 13 years ago by mabshoff

  • Milestone set to sage-3.0.2

comment:2 Changed 13 years ago by gnprice

I just watched another first-time Sage user try typing 'help()' at the prompt. =)

Greg

comment:3 Changed 11 years ago by mpatel

  • Work issues set to Close as fixed

I think we can close this ticket.

comment:4 Changed 11 years ago by mpatel

  • Cc jhpalmieri added
  • Report Upstream set to N/A
  • Status changed from new to needs_info
  • Summary changed from help() should give Sage help, not Python to [PLEASE CLOSE] help() should give Sage help, not Python

With #6820 merged, should we close this ticket?

comment:5 Changed 11 years ago by jhpalmieri

  • Milestone changed from sage-4.3.1 to sage-duplicate/invalid/wontfix
  • Resolution set to duplicate
  • Status changed from needs_info to closed

comment:6 Changed 11 years ago by mvngu

  • Summary changed from [PLEASE CLOSE] help() should give Sage help, not Python to help() should give Sage help, not Python
Note: See TracTickets for help on using tickets.