1

I've never used python before, but I have to in order to enable push notifications on my android app. When I type

python D:\Project\UAirship\clientauth.py

I get a syntax error with an error pointing to the drive letter. I've read support articles on urban airships website, and this is the way they execute this script so I'm not sure what I'm doing wrong. Thanks for your help.

asked Mar 17, 2012 at 0:17

2 Answers 2

1

You're supposed to type that in your shell/command interpreter, not the Python REPL.

answered Mar 17, 2012 at 0:22
Sign up to request clarification or add additional context in comments.

3 Comments

How do I get to the interpreter? I see >>> on the command line and when I type exit() the window closes.
Pick the option from the start menu that reads something like "Command Prompt". Failing that, run cmd.exe.
Oh... I didn't know they were one and the same. Thanks
1
  1. Check to make sure you've added Python to your path. At the C:> prompt type

    python

    and see what happens. If you get the Python shell, great. Else do what the faq says.

  2. edit: just fired up a windows box to check, and the D: shouldn't be a problem, never mind the thought that was previously occupying this space.

  3. It seems likely that ignacio is right in his answer: you're typing a command-prompt command into the python shell. Your cursor should be flashing after something that looks like this

    C:\>

    if it looks like this

    >>>

    type exit() to get out of the python shell and try again.

answered Mar 17, 2012 at 0:28

1 Comment

I do see >>>, but when I type exit() or ctrl+z and enter as the documentation said the window closes so I'm not sure how I'm supposed to get to the interpreter.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.