Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow sage -i python to actually install the right version of Python #19105

Closed
jdemeyer opened this issue Aug 27, 2015 · 20 comments
Closed

Allow sage -i python to actually install the right version of Python #19105

jdemeyer opened this issue Aug 27, 2015 · 20 comments

Comments

@jdemeyer
Copy link

CC: @jhpalmieri

Component: scripts

Branch/Commit: u/jdemeyer/ticket/19105 @ 74c78c1

Reviewer: Jeroen Demeyer

Issue created by migration from https://trac.sagemath.org/ticket/19105

@jdemeyer jdemeyer added this to the sage-6.9 milestone Aug 27, 2015
@vbraun
Copy link
Member

vbraun commented Aug 28, 2015

comment:1

I don't understand what the ticket proposes.

  • Renaming python2 -> python is backward
  • Renaming python3 -> python is too soon
  • Adding more spaghetti code to the install script to special-case python sucks
    IMHO the current behavior is ideal, throw an error and point the user to either python2 or python3

@jdemeyer
Copy link
Author

comment:2

Replying to @vbraun:

I don't understand what the ticket proposes.

  • Renaming python2 -> python is backward
  • Renaming python3 -> python is too soon
  • Adding more spaghetti code to the install script to special-case python sucks

Luckily, none of the above applies.

There is already code in build/make/install which deals with Python 2 vs. Python 3. The resulting file build/make/Makefile contains what is needed to make this work very easily.

@jdemeyer
Copy link
Author

comment:3

Admittedly, making ./sage -f python work is a lot harder than making ./sage -i python work. Unfortunately, it is ./sage -f python which is actually needed (for example, after installing openssl).

@vbraun
Copy link
Member

vbraun commented Aug 28, 2015

comment:4

IMHO it is not needed, just make up your mind which python version you want to install.

@jdemeyer
Copy link
Author

jdemeyer commented Sep 9, 2015

Changed dependencies from #19101, #19103, #19104 to #19119

@jdemeyer
Copy link
Author

Branch: u/jdemeyer/ticket/19105

@jdemeyer
Copy link
Author

New commits:

93ec09bChange sage -p to always install a package
c6ddd0eBetter help
f3d7ef3Remove -f option to sage-spkg when running sage -i
752e269Use PKG-clean target to implement sage -f PKG
1812e4fMerge tag '6.9.beta6' into t/19119/ticket/19119
74c78c1Allow "sage -i python" and "sage -f python"

@jdemeyer
Copy link
Author

Commit: 74c78c1

@jdemeyer
Copy link
Author

comment:8

Note that this is the only commit for this ticket, the rest comes from dependencies:

New commits:

74c78c1Allow "sage -i python" and "sage -f python"

@vbraun
Copy link
Member

vbraun commented Sep 11, 2015

comment:9

So the solution is C: Adding more spaghetti code to the install script to special-case python

@jhpalmieri
Copy link
Member

comment:10

Another possible solution: don't search on-line standard packages.

diff --git a/build/bin/sage-spkg b/build/bin/sage-spkg
index f4b085b..356efb9 100755
--- a/build/bin/sage-spkg
+++ b/build/bin/sage-spkg
@@ -331,7 +331,7 @@ if [ ! -f "$PKG_SRC" ]; then
             if [ $? -ne 0 ]; then
                 exit 1
             fi
-            for repo in optional experimental standard huge archive; do
+            for repo in optional experimental huge archive; do
                 # Download the list of packages.
                 echo ">>> Checking online list of $repo packages."
                 # File inside DOT_SAGE should be writable

That's where the problematic Python package is, right? And with recent versions of Sage, is there any reason to search "standard" packages? I think that all of those are either outdated or have more recent new-style replacements.

@jdemeyer
Copy link
Author

comment:11

Replying to @jhpalmieri:

And with recent versions of Sage, is there any reason to search "standard" packages?

As you recall from #19004, we aren't searching anything anymore.

There are two partially separate issues here:

  1. make sure that sage -i python does not install the wrong Python package.
  2. make sure that sage -i python does install the correct Python package.

This patch here is more about the second point.

@jhpalmieri
Copy link
Member

comment:12

There was also talk of rolling back #19004, in which case my suggestion would apply. But I guess not here. Is that a worthwhile change to make in any case? Should I open a ticket?

@jdemeyer
Copy link
Author

comment:13

Replying to @jhpalmieri:

Should I open a ticket?

For what exactly?

@jhpalmieri
Copy link
Member

comment:14

Never mind. If you take any efforts to roll back #19004, consider making those changes.

@jdemeyer
Copy link
Author

comment:15

Replying to @jhpalmieri:

If you take any efforts to roll back #19004

Well, there is this huge thread on sage-devel discussing that. Some people are in favour, some against, no clear consensus. There is also a ticket for the rollback: #19158.

@jdemeyer
Copy link
Author

Changed dependencies from #19119 to none

@jdemeyer
Copy link
Author

Reviewer: Jeroen Demeyer

@jdemeyer
Copy link
Author

Changed author from Jeroen Demeyer to none

@jdemeyer
Copy link
Author

comment:16

Close as "nobodycares".

@jdemeyer jdemeyer removed this from the sage-6.9 milestone Jan 25, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants