#14036: gap_console() fails
------------------------+---------------------------------------------------
   Reporter:  gtoal     |             Owner:  tbd     
       Type:  defect    |            Status:  new     
   Priority:  major     |         Milestone:  sage-5.7
  Component:  packages  |          Keywords:  gap.py  
Work issues:            |   Report Upstream:  N/A     
  Reviewers:            |           Authors:          
  Merged in:            |      Dependencies:          
   Stopgaps:            |  
------------------------+---------------------------------------------------
 I'm in IT support at a University and I was asked to install SAGE a few
 days ago for one of our mathematicians.  There didn't seem to be a
 suitable binary so I built from source as per
 http://www.sagemath.org/doc/installation/source.html using the current
 official release. ("Sage Version 5.5, Release Date: 2012-12-22",
 "GAP4, Version: 4.4.12 of 17-Dec-2008, x86_64-unknown-linux-gnu-gcc")

 When running sage, we found that the gap_console() command failed with
 symptoms identical to what is reported here:

   https://groups.google.com/forum/?fromgroups=#!topic/sage-
 support/bfswsbOuHn8

 Although that ticket refers to a solution ("Fixed in
 http://trac.sagemath.org/13211";) I wasn't able to locate the relevant
 patch or any other details at the latter address, just a comment "Also
 gap_console() was broken. Fixed it and added a meaningful doctest."

 It may have slipped by regression testing as it is still present in the
 source.  I tracked it down and the cause is that when the command line to
 call gap is generated, there is a space missing between the "-L
 <workspace>" option and the following console.g script name.

 The problem is in gap.py, and can be fixed in two ways.

 1) if you prefer to consistently plant a space after every command-line
 item, then change the line
 {{{#!C
              return "%s -L %s"%(gap_cmd, WORKSPACE), False
 }}}
 to
 {{{#!C
              return "%s -L %s "%(gap_cmd, WORKSPACE), False
 }}}
 or

 2) if you would rather add the spaces before each item, then modify
 {{{#!C
     cmd, _ = gap_command(use_workspace_cache=use_workspace_cache)
     cmd += os.path.join(SAGE_EXTCODE,'gap','console.g')
     os.system(cmd)
 }}}
 to
 {{{#!C
     cmd, _ = gap_command(use_workspace_cache=use_workspace_cache)
     cmd += ' '
     cmd += os.path.join(SAGE_EXTCODE,'gap','console.g')
     os.system(cmd)
 }}}
 (Personally I prefer the first option)

 Could you also add a regression test to see that this doesn't come up
 again please?


 thanks,


 Graham

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/14036>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to