Repairing Broken Code

19 views
Skip to first unread message

Ingo Dahn

unread,
Feb 18, 2020, 12:24:07 PM2/18/20
to sage-cell
If your SageCell code broke recently, you may want to go to the SageCellDoctorPage for a suggestion to repair it.

If your problem isn't listed there, try to isolate the problem in a code snippet and submit that code and the resulting error message.

Initially, that site lists 6 problems and 3 solutions.

If you by chance have a solution for one of the open problems, please post it in this thread and I'll copy it over to the SageCellDoctorPage.
If you are available for regularly suggesting solutions (great!) I am happy to provide you with direct write access to the problem/solution spreadsheet.

I hope this is useful, in particular for non-expert users of SageCell.

Samuel Lelièvre

unread,
Feb 20, 2020, 7:39:46 PM2/20/20
to sage-cell
Tue 2020-02-18 17:24:07 UTC, Ingo Dahn:
Thanks for this excellent initiative!

The problem at line 5, where

    sage: show(plot(factorial(x), (x, 1, 5)))

raises

    AttributeError: 'float' object has no attribute 'gamma'

can be simplified to

    sage: plot(factorial(x), (x, 1, 5))

and even to

    sage: factorial(float(3.2))

That problem now has a proposed solution at

- Sage Trac ticket 26749
  Let `factorial` accept float arguments
  https://trac.sagemath.org/ticket/26749
 
Maybe columns E, F, G could have the following titles,
and be filled as follows for line 5:

- works in

    Sage <= 8.2

- fails in

    Sage 8.3 to 9.0

- Sage Trac ticket

    26749

Are you thinking of suppressing the issues once solved,
or of keeping lines unchanged so they can be referred to?

I'm interested in write access.

Samuel

Ingo Dahn

unread,
Feb 21, 2020, 3:30:39 AM2/21/20
to Samuel Lelièvre, sage-cell
Thanks, I have adapted the sheet and sent a link for write access directly. 
I intend to strike through problems that are no longer problems, i.e. if that code is working again in the current version of SageMath.

--
You received this message because you are subscribed to a topic in the Google Groups "sage-cell" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/sage-cell/fZU25_fYKXA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to sage-cell+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sage-cell/466840ad-0159-41b4-8848-fe0c2812c3fa%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages