Jump to content

Recommended Posts

Posted
Hello
 
I think error logs in cPanel is give me too little information about errors that I face. Sometimes I check the errors in my PC, but when everything is good in my PC, there are still error in Heliohost server that I dont know what exactly is it, because error logs only tell me about 404.shtml file not found.
 
Please upgrade the error logs, so I know what the error in my program. Or, any other way to check the error like in Python IDLE?
 
Warm regards
 
PS : I use Tommy server, and my program at http://muhamm10.heliohost.org/helio.py

 

 

Posted

Unfortunately a 500 error is the best you're going to get for most python scripts. In your particular case you're using an incorrect shebang. If you want to use python3.6 use

#!/usr/bin/python3.6
  • 4 months later...
Posted (edited)

what is closest application to python that heliohost use? so i can check where the problem is in my PC?

I use python 3.6.3 on Windows 7, I run my script there, and everything is run well, but when I upload it yo heliohost, I always get error message

Edited by man95
Posted

Tommy no longer has python 3.6. This post that you responded to is 5 months old. We upgraded Tommy to python 3.7 which is available at /usr/bin/python3.7

Posted

I know, Python 2.7 also installed at Python. I use Python 2.7 on Windows 7 and run CGIHTTPServer, and it is OK. When I upload my code to Heliohost, it is give me error, altough I've add shebang #!/usr/bin/python2.7.

 

I inspect my code, the problem is at end of my code, there is a "Tab". When I delete it, the code run well.

I run on my laptop the code with "Tab" at the end of my code, it is running well

 

I want to know what is the best way to get where the error line from my code, since there are different result between my laptop and heliohost

Posted

There really isn't a good way to get the error on the server other than asking an admin.

OMG, how if I need it fastly or the code consists thousand lines ? 

Posted

Odds are, you're always going to have to change at least the shebang line and line endings if you develop on Windows for a linux target.

 

Other than that, adding your own logging to your code will typically help you locate what's blowing up and where. Have it log to your home folder somewhere so you can get the logs.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...