python help

hey guy, i have a python, that imports, and threadpoool.pyc and a .txt to make it work, on my own pc it works perfectly, but on the pythonanywhere, it messes up somehow, i have no clue, is this way of using a py possible on pythonanywhere? i wonder or am i doing something wrong. lets put the stuff in a row

  • a python that imports, threadpool
  • a python that imports, information, from a .txt
  • works fine on my pc, not here


How does it not work? What error do you get?

let me try to firstly re-explain-

the main python script in the folder, imports, information from a .txt in the same folder, to work, it also imports threadpool.

the main python itself, also copy/paste information back, into another .txt in the same folder, on my pc it works fine, on here it doesnt, the error is

Preparing execution environment... OK Installing Flux capacitors... OK Loading Python2.7 interpreter...

and nothing more

Does it clear the screen after that output?

Can I suggest you open a bash console, navigate to the correct directory, and then try "python"

can you give me an example of a directory, cuz i tried few different ways it cant find the file hm /home/fatih03/pm/ didnt work hm what do i exactly type while using the bash

pm is the folder the py is in. tyvm

also it does not, clear, it just stays like that loading... etc

very strange

01:40 ~ $ /home/fatih03/pm/ bash: /home/fatih03/pm/: Is a directory 01:40 ~ $ /home/fatih03/pm/ bash: /home/fatih03/pm/ No such file or directory 01:40 ~ $

its clearly called hm and its there hm wierd

tried a different py, through bash hm

01:42 ~ $ /home/fatih03/pm/ bash: /home/fatih03/pm/ Permission denied 01:46 ~ $

but this one works fine, without bash.

That's because linux is case sensitive. so you needed to call instead of

Also, you may need to use chmod to give the correct permissions. (eg: chmod 777 before running it.

Even when you Chmod it the script still needs a shebang ( #!/bin/python ). Save yourself the trouble and just run python ./ Path of least resistance.