#5079: [with patch, needs work] overly greedy RealNumber handling in preparser
------------------------+---------------------------------------------------
Reporter: boothby | Owner: boothby
Type: defect | Status: new
Priority: major | Milestone: sage-3.3
Component: interfaces | Resolution:
Keywords: |
------------------------+---------------------------------------------------
Changes (by mabshoff):
* summary: [with patch, positive review] overly greedy RealNumber
handling in preparser => [with patch, needs
work] overly greedy RealNumber handling in
preparser
Comment:
This patch causes various test failures all seemingly of the type
{{{
mabsh...@geom:/scratch/mabshoff/sage-3.3.alpha2$ ./sage -t -long
devel/sage/sage/server/notebook/twist.py
sage -t -long "devel/sage/sage/server/notebook/twist.py"
**********************************************************************
File
"/scratch/mabshoff/sage-3.3.alpha2/devel/sage/sage/server/notebook/twist.py",
line 1459:
sage: W = n.new_worksheet_with_title_from_text('Sage', owner='sage')
Exception raised:
Traceback (most recent call last):
File "/scratch/mabshoff/sage-3.3.alpha2/local/bin/ncadoctest.py",
line 1231, in run_one_test
self.run_one_example(test, example, filename, compileflags)
File "/scratch/mabshoff/sage-3.3.alpha2/local/bin/sagedoctest.py",
line 38, in run_one_example
OrigDocTestRunner.run_one_example(self, test, example, filename,
compileflags)
File "/scratch/mabshoff/sage-3.3.alpha2/local/bin/ncadoctest.py",
line 1172, in run_one_example
compileflags, 1) in test.globs
File "<doctest __main__.example_21[4]>", line 1, in <module>
W = n.new_worksheet_with_title_from_text('Sage',
owner='sage')###line 1459:
sage: W = n.new_worksheet_with_title_from_text('Sage', owner='sage')
File "/scratch/mabshoff/sage-3.3.alpha2/local/lib/python2.5/site-
packages/sage/server/notebook/notebook.py", line 930, in
new_worksheet_with_title_from_text
W = self.create_new_worksheet(name, owner)
File "/scratch/mabshoff/sage-3.3.alpha2/local/lib/python2.5/site-
packages/sage/server/notebook/notebook.py", line 623, in
create_new_worksheet
auto_publish = False)
File "/scratch/mabshoff/sage-3.3.alpha2/local/lib/python2.5/site-
packages/sage/server/notebook/worksheet.py", line 248, in __init__
self.save_snapshot(owner)
File "/scratch/mabshoff/sage-3.3.alpha2/local/lib/python2.5/site-
packages/sage/server/notebook/worksheet.py", line 1640, in save_snapshot
E = self.edit_text()
File "/scratch/mabshoff/sage-3.3.alpha2/local/lib/python2.5/site-
packages/sage/server/notebook/worksheet.py", line 1823, in edit_text
t = C.edit_text().strip()
File "/scratch/mabshoff/sage-3.3.alpha2/local/lib/python2.5/site-
packages/sage/server/notebook/cell.py", line 783, in edit_text
s = self.plain_text(ncols, prompts, max_out)
File "/scratch/mabshoff/sage-3.3.alpha2/local/lib/python2.5/site-
packages/sage/server/notebook/cell.py", line 760, in plain_text
out = self.output_text(ncols, raw=True, html=False,
allow_interact=False)
File "/scratch/mabshoff/sage-3.3.alpha2/local/lib/python2.5/site-
packages/sage/server/notebook/cell.py", line 1240, in output_text
is_interact = self.is_interactive_cell()
File "/scratch/mabshoff/sage-3.3.alpha2/local/lib/python2.5/site-
packages/sage/server/notebook/cell.py", line 917, in is_interactive_cell
s, _ = strip_string_literals(self.input_text())
ValueError: too many values to unpack
**********************************************************************
}}}
The failures are in
{{{
sage -t -long devel/sage/sage/server/notebook/cell.py # 85
doctests failed
sage -t -long devel/sage/sage/server/notebook/worksheet.py # 289
doctests failed
sage -t -long devel/sage/sage/server/notebook/twist.py # 3
doctests failed
sage -t -long devel/sage/sage/server/notebook/notebook.py # 19
doctests failed
}}}
Cheers,
Michael
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/5079#comment:3>
Sage <http://sagemath.org/>
Sage - Open Source Mathematical Software: Building the Car Instead of
Reinventing the Wheel
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---