In article <mailman.2117.1383796399.18130.python-l...@python.org>, Anthony Papillion <papill...@gmail.com> wrote:
> Hello Everyone, > > I'm writing a little helper script in Python that will access a JSON > formatted argument from the shell when it's called. The parameter will > look like this: > > {"url":"http://www.google.com"} > > So, if my program is called "getargfromcli.py" the call will look like this: > > getargfromcli.py {"url":"http://www.google.com"} > > In the case above, I assume my JSON string will be argv[1]. In fact, > when I do > > print sys.argv[1] > > It works as expected and prints out the JSON string as expected like > this: {url:http://www.google.com} Which is not valid JSON. You lost the quotes. I suspect you want to -- https://mail.python.org/mailman/listinfo/python-list