Skip to content
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

IPython magic shell commands #6

Closed
hugobowne opened this issue May 24, 2016 · 6 comments
Closed

IPython magic shell commands #6

hugobowne opened this issue May 24, 2016 · 6 comments

Comments

@hugobowne
Copy link

With IPython, you call execute Shell commands by prefacing them with !, e.g. ! ls for directory contents.

I use this in my course and Hamel will use it in his Cleaning Data in Python course.

We will need some test functions for this.

@vvnkr
Copy link
Member

vvnkr commented May 25, 2016

Is this only ! ls? You can use test_student_typed() for this.

@hugobowne
Copy link
Author

there'll be more cases. Hamel will use commands from csvkit and csvfix for his course:

http://csvkit.readthedocs.io/en/0.9.1/tutorial.html

http://neilb.bitbucket.org/csvfix/

the 1st has a python package but it may have less functionality than the shell toolkit. i'll know more when he gets back from vacation

@vvnkr
Copy link
Member

vvnkr commented May 26, 2016

I'll look in to it. Also if you want to use another "magic" command than ! for system operations, be sure to first check with product on the pythonbackend GitHub. Some of these might not be supported.

@filipsch
Copy link
Contributor

@vincentvankrunkelsven @hugobowne this can become challenging as ast, the syntax parser that we use to parse a submission, does not recognize IPython commands (give a syntax error in this case). So we need to make sure to work around them.

@hugobowne
Copy link
Author

ahhhh wait I just raised this in a new issue: #31

because the error message is now thrown. feel free to merge issues

@vvnkr
Copy link
Member

vvnkr commented Jun 21, 2016

Moved to #33

@vvnkr vvnkr closed this as completed Jun 21, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants