[sage-support] Re: json and sage

2010-02-23 Thread Jason Grout
On 02/20/2010 12:57 PM, jpc wrote: It follows my work: import json class TrivialSageJSON(json.JSONEncoder): """ http://docs.python.org/library/json.html#encoders-and-decoders sage/devel/sage-main/sage/server/simple/twist.py (here there's a "simple_jsonize") """ def defaul

[sage-support] Re: json and sage

2010-02-20 Thread jpc
It follows my work: import json class TrivialSageJSON(json.JSONEncoder): """ http://docs.python.org/library/json.html#encoders-and-decoders sage/devel/sage-main/sage/server/simple/twist.py (here there's a "simple_jsonize") """ def default(self,o): try: if isi