In a thread over at [sage-support] William wrote:
> I've suggested numerous times that we should massively refactor the
> sage library to be a bunch of smaller Python libraries, develop them
> say on github (?), use Pypi and pip. If people would realize how
> important it is that we revamp how Sage development is done in a much
> less monolithic way, and better using existing tools, then I would be
> happy and enjoy watching as people do the revamp (e.g., like happened
> with switching from Mercurial to Git, which I didn't do much on, but
> definitely supported).
I don’t mean to restart a general strategy/development discussion here,
but perhaps turning Sage into a bunch of smaller Python libraries is
something which can be accomplished step-by-step.
In particular, I am *very* interested in turning Sage’s interrupt
handling into something that can be easily installed from PyPI. For
those who don’t know what Sage’s interrupt handling does: it allows that
you can press Ctrl-C to interrupt long running C code and that crashes
in a library do not necessarily crash your Python shell. It is a
difference between night and day to interface with external C/C++ code
From Python without and with it.
Having this code available outside of Sage enables, for example, to turn
some of our C/C++ library interfaces into stand-alone libraries[^1], like
I’ve done with our fplll interface at
Sage’s interrupt handling lives at
I think the technical challenges are manageable. I’m using a copy of it
without issues. Making this code independent would mean one big patch
to the library, though, where we replace all
with an appropriate new line depending on where we’d install the file.
My question is: am I overlooking some technical challenge or another
reason why making this code independent could be a problem?
I’m happy to put some work into this, in case you’re wondering.
[^1]: Okay, there’s also the small issue of how to do type conversion
Sage ←→ library in a nice modular yet fast way, but one step at a time.
_otr: 47F43D1A 5D68C36F 468BAEBA 640E8856 D7951CCF