Business Template : erp5_data_notebook (To execute remote python code from inside of erp5)
Merge work of Ayush Tiwari (@tiwariayush) to support ERP5-side code execution for Jupyter (= IPython) notebook: ---- 8< ---- Jupyter == IPython Notebook Features: 1. Module - Data Notebook (To save notebook according to reference from jupyter frontend) 2. Execute python code which might/might not be remote. 3. Save local_variables for specific notebook, i.e, you can use the python objects which were created during code execution. After making a successful connection(from frontend) to specific notebook, the variables which were saved earlier are available while for execution. Architecture: - Code from Jupyter cell is being received as string by Base_executeJupyter. - Code is executed in Base_runJupyter external method. - Local variables saved via CMFActivity. - Result as JSON is returned to frontend (contains mime_type of result string also). Example Notebook: http://nbviewer.ipython.org/urls/lab.nexedi.com/nexedi/erp5/uploads/6778782d5753873583bd4843772cf502/Proof_of_concept_Notebook.ipynb https://lab.nexedi.com/nexedi/erp5/uploads/6778782d5753873583bd4843772cf502/Proof_of_concept_Notebook.ipynb ---- 8< ---- Current state is: erp5-data-notebook somehow works on server side, but is known (see nexedi/slapos!43) to have at least the following limitations: - errors are not reported properly to users; - state is not fully saved to ZODB. the latter point means notebook works only if it is connected to Zope family with only 1 zope process. @Tyagov reviewed this work. I'm the person who does the merge. Slapos part to integrate erp5-data-notebook bt5 and Jupyter frontend will come in via nexedi/slapos!43 . /reviewed-by @Tyagov (on nexedi/erp5!29 and on a lot of other places)
Showing
This source diff could not be displayed because it is too large. You can view the blob instead.
Please register or sign in to comment