Closed pjritee closed 9 years ago
Looks like Python 3.3 was already on the zone (maybe I or someone else installed it some time in the past). I've symlinked the binaries so that python3
runs Python 3.3.0, and python2
runs Python 2.7.3. From what I can tell, Python 3.4 isn't available in the SmartOS package manager (though I don't believe that will affect our use case), if 3.4 is really needed, then ask ITIG for help.
In terms of getting the visualiser to run python 3, see if there's any documentation/example at http://www.pythontutor.com/.
I changed the default option on the OPT html page to 3.3 a while back.
Cool, but it doesn't work for me: http://csse1001.uqcloud.net/opt/visualize.html; click "visualise". I get a popup saying the server isn't configured to run python 3.
Yeah, I mean I literally changed the default option in the HTML page. If it doesn't work now, it would have never worked with python 3.
If it is anything like moss, the following may be helpful (instructions I wrote for installing my CSSE2310 test suite).
https://github.com/athleticus/pyra/blob/master/install-python-on-moss.md
Does apache need to be configured to allow python3 cgi scripts?
Using the URL: http://csse1001.uqcloud.net/opt/visualize.html#&py=3 seems to work
That could easily be prepended to the URL string we use in the app.
On Thursday, February 12, 2015, Peter Robinson notifications@github.com wrote:
Using the URL: http://csse1001.uqcloud.net/opt/visualize.html#&py=3 seems to work
— Reply to this email directly or view it on GitHub https://github.com/CSSE1001/MyPyTutor/issues/89#issuecomment-74002778.
"not configured to run python 3" - the error message comes from js/iframe-embed.js (in /opt/local/share/httpd/htdocs/opt)
Further to my previous comment - earlier in the file there are the lines var python2_backend_script = 'exec'; var python3_backend_script = null;
I not sure what null should be replaced with
This issue is probably more appropriately discussed over in https://github.com/CSSE1001/csse1001-website
Solved. It was in /opt/js/opt-frontend.js
I've just updated this issue to focus on the particular bug with MPT linking to the Python 2 visualisations of OPT.
I don't know if this particular issue has been resolved, so reopening until someone else confirms this.
For MPT visualization (and for visualizations in notes) we need OPT to default to Python3 - I guess that means we need to install Python3 on the zone. It also seems to default to Python2 at them moment but I don't see why.
EDIT(@jgat): The goal of this issue is now to ensure that links to the OPT from within MPT are sent to the Python 3 version. Discussion about other OPT issues at https://github.com/CSSE1001/csse1001-website/issues/20.