[IPython-dev] Pass variable to a ! command

Kenneth Tran one at kentran.net
Tue Sep 23 23:39:56 EDT 2014


Hi,

I'd like to pass Python variables as arguments to a system command.
However, perhaps due to the command line syntax of my program (which
accepts nested options via {}), this doesn't work.

[image: Inline image 1]

It looks like that when IPython fails to parse one of the variable names or
expressions, it treats the whole command line as raw string. Here's a
simpler example

[image: Inline image 2]

Should it try to parse variable names and/or expressions as much as it can?

What files should I look into if I want to fix this?

Thanks.
-Ken
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140923/c0fa435a/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 21702 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140923/c0fa435a/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 56740 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140923/c0fa435a/attachment-0001.png>


More information about the IPython-dev mailing list