HungryHobo
HungryHobo

Reputation: 75

Getting "EOFError" when running Python code on Atom

I'm trying to run python code with the atom-runner for atom, but it returns an EOF error. I did what other answers to similar questions said to do, and put raw_input() instead of input(), but it still returns and EOF error.

Here is my code:

tempf = int(raw_input("What is the temperature in fahrenheit?  "))
tempc = (tempf - 32) * 5 / 9
print("The temperature in celsius is", tempc, "degrees.")

Here is the error:

What is the temperature in fahrenheit?  
Traceback (most recent call last):
File "C:\Documents\Programming\Python\f2c.py", line 1, in <module>
    tempf = int(raw_input("What is the temperature in fahrenheit?  "))
EOFError: EOF when reading a line

Upvotes: 3

Views: 4331

Answers (1)

Richard Slater
Richard Slater

Reputation: 6378

Drawing together the answers from the comments, as it stands atom-runner does not support STDIN, the linked issue was responded to with:

Thanks! If someone wanted to put together a pull request to support this it would probably be accepted (if it looked good and didn't break anything, that is).

However, as quite rightly pointed out you can probably acheive what you are looking for by using the script package.

Upvotes: 1

Related Questions