I'm using Python on my web server (which is Heliohost) and i'm not able to import some Python modules. Whenever i try to import them, i get a 500 internal server error.
The modules i'm not able to import are Numpy and tensorflow, which should be installed because running the script below that should print all the modules installed
#!/usr/bin/python3.6
import cgitb
import pip
print("Content-Type: text/html")
cgitb.enable(format='text')
installed_packages = pip.get_installed_distributions()
installed_packages_list = sorted(["%s==%s" % (i.key, i.version)
for i in installed_packages])
returns a lot of Python modules, with tensorflow and numpy as well.
Basically, the scripts work fine with any other Python module, it gives an error only with those two.
What could be the problem? Unluckily i can't access the server logs because my web server provider doesn't allow it, ans with cgitb enabled (that should print any error in the code), it just returns the error 500 without printing anything else.
Aucun commentaire:
Enregistrer un commentaire