Python 2.5 not working

New releases and general discussions.

Post » Sat Apr 26, 2008 3:19 am

[code:1nesh7mv]from ftplib import FTP
f = FTP('hero2bash.max.io','hero2bash.max.io','ohsh..iforgottomask')
trick = f.pwd()

f.quit()[/code:1nesh7mv]

I don't know, but when I try to run the program with this script it alwasys displays an errror..
The script uis in the events set to always...

EDIT: any python script doesn;t work
B
16
S
10
G
5
Posts: 255
Reputation: 3,934

Post » Wed Jul 23, 2008 3:04 pm

Can we get confimation if Python is currently working or not in Construct 0.96.2 please.

My code will run, but I can't call functions from buttons etc. I get the error " 'connect' is not a recognised system expression or usable object name. ", even though I have "def connect():
s.connect(("localhost", 23))" in a script.
B
1
S
1
G
4
Posts: 1
Reputation: 1,177

Post » Thu Sep 18, 2008 10:15 am

Yeah i get this error everytime i try and use python.

"Traceback (most recent call last):
File "<string>", line 2, in <module>
ImportError: No module named zipfile"

The game still works. I just have an editbox and this is all thats in the event editor-
EditBox.SetText("Hi")

Any ideas?
B
2
S
2
G
5
Posts: 448
Reputation: 2,546

Post » Thu Sep 18, 2008 1:59 pm

The current status on Python is that it seems to be broken in the latest builds - I think that if you install yourself a version of Python different to the one the IDE has implemented, Python can't find the right files, or something like that. We'll be looking in to it and fixing it before 1.0.
Scirra Founder
B
359
S
214
G
72
Posts: 22,946
Reputation: 178,478

Post » Tue Dec 16, 2008 10:42 pm

Hello everyone,

It sounds like it might be some issue with the PYTHONPATH environment variable being incorrect or getting overwritten when you install your own Python vs. Construct's python. Had you already thought of that as a source of the problem?

I notice when people post here with errors they seem to largely be ImportErrors. They are trying to import some standard library stuff (like socket or ftp) so it's unlikely that anything is actually missing, but it's just not looking in the right place.
B
1
G
4
Posts: 4
Reputation: 1,033

Post » Wed Dec 17, 2008 2:16 am

While toying around with Construct for the first time, I've made a diagnostic app. It will tell you the PYTHONPATH and some other python-specific system variables according to the Python instance running on top of Construct. Its only dependency is that you can successfully import the 'sys' module, which should be builtin to the interpreter itself.

[url:258l4xw8]http://nil.cjb.net/code/python_diagnostic.cap[/url:258l4xw8]

Also, on a fresh install I find no problems importing libraries and such, and any of the libraries I need seem to be available.
B
1
G
4
Posts: 4
Reputation: 1,033


Return to Construct Classic Discussion

Who is online

Users browsing this forum: No registered users and 2 guests