#12627: The spkg/bin/sage script engraves paths to executables
--------------------------------+-------------------------------------------
Reporter: Snark | Owner: leif
Type: defect | Status: needs_info
Priority: major | Milestone: sage-5.0
Component: scripts | Resolution:
Keywords: rd2 | Work issues:
Report Upstream: N/A | Reviewers: R. Andrew Ohana
Authors: Julien Puydt | Merged in:
Dependencies: | Stopgaps:
--------------------------------+-------------------------------------------
Comment (by leif):
Replying to [comment:17 jdemeyer]:
> Replying to [comment:16 Snark]:
> > First, you still mention "test -x" although I pointed out it's not the
recommended way to check for an executable.
That's simply bu!**sh!**. First of all, I did mention `command -v` as
well, and more importantly, `test -x` and `command` have different use
cases. Nobody claimed that `command` wasn't portable; we use it in many
places of Sage -- ''where it is appropriate''.
[[BR]]
> You "pointed out" without saying why. I think `test -x` is used
perfectly here.
It is.
[[BR]]
> > Second, as I already pointed out, my patch makes sage run sage
versions by default if available. And if not available in sage, if they
are available on the system, use that. The only error case is the one
where indeed, it is really not available.
> As I (and leif, for once I agree with him)
:-)
> have said, sage --COMMAND is supposed to run the Sage version of
COMMAND.
And if `sage --PROGRAM` should run external versions at all, then the help
messages would have to be changed as well, which your patch '''doesn't''',
although it changes the (btw. intuitive) behavior:
{{{
#!sh
echo " -kash [...] -- run Sage's Kash with given arguments"
...
echo " -M2 [...] -- run Sage's Macaulay2 with given
arguments"
}}}
(And if there happen to be system-wide versions along the path, there's no
mention that Sage's optional packages could be installed [in case they
aren't already]. People frequently have completely outdated, incompatible
or broken versions installed -- sometimes even not to their knowledge,
which is ''one'' reason Sage ships such a lot, or at least offers such
components as optional packages.)
[[BR]]
> > There seem to be a high dose of paranoia in sage developers about
everything that doesn't come out of sage.
Sometimes for good reason; see above.
And as mentioned, it's better to not blindly trust even the Sage
installation itself, since its integrity is not necessarily an invariant,
especially if users (and developers, which most people of the Sage
community intentionally don't differentiate) "play" with it.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/12627#comment:21>
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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.