#12530: Improve the sage-combinat script to support guards for developpers
versions
------------------------------+---------------------------------------------
Reporter: nthiery | Owner: leif
Type: enhancement | Status: needs_work
Priority: major | Milestone: sage-5.0
Component: scripts | Keywords:
Work_issues: | Upstream: N/A
Reviewer: Florent Hivert | Author: Nicolas M. ThiƩry
Merged: | Dependencies:
------------------------------+---------------------------------------------
Changes (by hivert):
* status: needs_review => needs_work
Comment:
Hi Nicolas,
I tried this patch after installing a {{{sage_5.0.beta4}}} and if broke
with
the following error message. I'm investigating::
{{{
[...]
Skip backward compatibility patches for sage 4.3.3
Traceback (most recent call last):
File "/home/data/Sage-Install/sage-5.0.beta4/local/bin/sage-combinat",
line 402, in <module>
qselect_backward_compatibility_patches()
File "/home/data/Sage-Install/sage-5.0.beta4/local/bin/sage-combinat",
line 303, in qselect_backward_compatibility_patches
hg_all_guards()))
File "/home/data/Sage-Install/sage-5.0.beta4/local/bin/sage-combinat",
line 294, in is_newversion_guard
if cmp_sage_versions(guard, sage_version) > 0:
File "/home/data/Sage-Install/sage-5.0.beta4/local/bin/sage-combinat",
line 200, in cmp_sage_versions
return cmp(encode_sage_version_for_comparison(version1),
encode_sage_version_for_comparison(version2))
File "/home/data/Sage-Install/sage-5.0.beta4/local/bin/sage-combinat",
line 174, in encode_sage_version_for_comparison
return [int(s) for s in re.split("\.|_", version)]+[0]
ValueError: invalid literal for int() with base 10: '3:'
popcorn-*e/sage-5.0.beta4 $ cd local/bin
}}}
Adding a print:
{{{
diff --git a/sage-combinat b/sage-combinat
--- a/sage-combinat
+++ b/sage-combinat
@@ -168,6 +168,7 @@ def encode_sage_version_for_comparison(v
sage: e("4.7.2.beta10") < e("4.7.2.rc0")
True
"""
+ print "DEBUG:::: %s"%version
version = version.replace("alpha", "-3.")
version = version.replace("beta", "-2.")
version = version.replace("rc", "-1.")
}}}
Shows
{{{
Skip backward compatibility patches for sage 4.3.2
DEBUG:::: 4_3_3
DEBUG:::: 5.0.beta4
Skip backward compatibility patches for sage 4.3.3
DEBUG:::: 4_3_3:
Traceback (most recent call last):
[...]
ValueError: invalid literal for int() with base 10: '3:'
}}}
The problem is in the queue: the following guard is invalid
{{{
trac_6520_weakref-cached-function-dr.patch #+4_3_3: needs rebase
}}}
I think we should throw an error in this case. What do you think ?
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/12530#comment:4>
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.