Opened 12 years ago
Closed 12 years ago
#1789 closed defect (fixed)
[with patch; with positive review] standalone Sage scripts don't work on Linux -- they work fine on OS X
Reported by: | was | Owned by: | was |
---|---|---|---|
Priority: | critical | Milestone: | sage-2.10.1 |
Component: | user interface | Keywords: | |
Cc: | Merged in: | ||
Authors: | Reviewers: | ||
Report Upstream: | Work issues: | ||
Branch: | Commit: | ||
Dependencies: | Stopgaps: |
Description
Hi Robert, 1. Is this a clean, from-source build of sage-2.9.3? Yes, i tried it out on two different systems now, Athlon XP, and Core Duo, both running on Debian Etch, and both show the same behaviour 2. What is the output of /usr/bin/env for you? Mine (Intel OS X 10.5.1) doesn't mention sage at all, although mysteriously things are working for me. the SAGE_ROOT directory is included in my path, i even defined a global variable with this name, i.e. SAGE_ROOT. > #!/usr/bin/env sage -python > import sys For me, I get $ ./BMV.sage $ you response encouraged me to try out some more things, and if i change the first line to #!/usr/bin/env sage-python instead of #!/usr/bin/env sage -python (note that there is no space anymore) things work as excepted (at least import sys and print "Hello World"), seems like my /usr/bin/env does not like the space between (#!/usr/bin/env "sage -python" does not work either) but however, using #!/path/to/sage_root/sage-python import sys still does not work and shows the same strange "mouse behaviour" as described in my original posting, on both systems!! no idea why the second one does not work on my systems!! However, when I run the sage itself, it looks like it's pointing at some weird version: $ /usr/bin/env sage ---------------------------------------------------------------------- | SAGE Version 2.9.2, Release Date: 2008-01-05 | | Type notebook() for the GUI, and license() for information. | ---------------------------------------------------------------------- Loading SAGE library. Current Mercurial branch is: demo $/usr/bin/env sage brings me to the sage prompt as expected Hopefully this helps, although I have a feeling this thread isn't over... Anyway, at least i found a partial solution to carry on with, but it seems as there are still some things to clarify, especially the mouse thing concerning the import sys Thank you very much, Georg
Attachments (1)
Change History (4)
Changed 12 years ago by
comment:1 Changed 12 years ago by
- Summary changed from standalone Sage scripts don't work on Linux -- they work fine on OS X to [with patch; needs review] standalone Sage scripts don't work on Linux -- they work fine on OS X
I've posted a patch that gets applied in the SAGE_ROOT/examples directory.
comment:2 Changed 12 years ago by
- Summary changed from [with patch; needs review] standalone Sage scripts don't work on Linux -- they work fine on OS X to [with patch; with positive review] standalone Sage scripts don't work on Linux -- they work fine on OS X
This seems like a reasonable change to make. The situation is tricky and it appears that the best thing to be done is to document how it can be made to work.
comment:3 Changed 12 years ago by
- Resolution set to fixed
- Status changed from new to closed
Merged in Sage 2.10.1.alpha0
Note: See
TracTickets for help on using
tickets.
fixes the examples and docs in the examples/programming/scripts to avoid a lot of confusion, e.g., so they work on both os x and linux instead of just os x.