-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add the "Python 3.6 + Anaconda 5.2 EXPERIMENTAL!" mode of PythonTutor (recent feature) #10
Comments
Using this code as an example, I get the following iframe:
The interesting part is From what I can read on the code Line 140 in 66fb98a
Line 173 in 66fb98a
it should be easy to add this py3anaconda language code in the "whitelist" that you wrote!I'll try to hack this on my local installation of the magic, and reload my notebook. |
Here is the durty hack I just wrote: tutormagic.py: 140,141c140,141
< if args.lang[0].lower() in ['python2', 'python3',
< 'java',
---
> if args.lang[0].lower() in ['python2', 'python3', 'py3anaconda',
> 'java',
152c152
< "'typescript', 'ruby', 'c', 'c++'".format(args.lang[0]))
---
> "'typescript', 'ruby', 'c', 'c++', 'py3anaconda'".format(args.lang[0]))
177a178,179
> elif lang == "py3anaconda":
> url += "py=py3anaconda" |
This should fix kikocorreoso#10! It was very easy!
I was not aware of the py36anaconda option. From the pythontutor.com web page it says 'unsopported'. I can include it here from your PR #11 but take into account this could break your code at any moment (from 3rd parties I don't manage, pythontutor.com). As a general advice, you shouldn't rely on 'unsupported' stuff. |
Hi again,
I'll keep in mind the tiny lolviz Jupyter IPython extension, as it allows basic but nice illustrations of simple data-structures and pointers. It's far from close to PyTutor but well it can help. |
When I started this package pythontutor was opensource. I don' know why now it isn't anymore 😞
I didn't know about |
I think PythonTutor's author was tired of maintaining as open source, as his website is used by millions of users I can expect the number of issues to be large. |
Regarding |
Hm your https://github.com/kikocorreoso/pizarra-nb is awesome! Did you know about RISE which allows to turn classical notebook in live slideshow (live as in I can type and execute code, in any kernel) ? RISE has a tiny and unknown feature that is it includes a chalkboard and a "pen" tool to write on any slide! See https://rise.readthedocs.io/en/stable/customize.html#enable-chalkboard-capabilities |
@kikocorreoso any update? |
It is merged and you can install it from PyPI using Thanks. |
Oh great, thanks @kikocorreoso ! |
Hello there @kikocorreoso,
I noticed that your extension only recognizes the following mode of using http://PythonTutor.com/:
'python2', 'python3', 'java', 'javascript', 'typescript', 'ruby', 'c', 'c++'
But a recent new feature is "Python 3.6 + Anaconda 5.2 EXPERIMENTAL!".
It's very useful because it provides a teaching/debugging environment that supports lots of scientific packages, including numpy, scipy, etc (of course, no displaying of matplotlib, it gives this error and is a known missing features):
Do you think you could update your extension and allow a "anaconda" mode?
By reading the code of this extension, it would probably be easy!
Thanks in advance! Regards from France, @Naereen
The text was updated successfully, but these errors were encountered: