PDA

View Full Version : Python failure: install issue?



jeric_synergy
09-03-2012, 11:22 PM
I've been having some issues w/my Python installation in LW 11.0.3. All the failures are similar (see jpg) in that they have "ImportError: No module named XXXX", with varying values for XXXX.

The gear in the back of the image was generated using a Python script, so Python's not completely hosed.

The error message makes me think that some Python library isn't being loaded or found. Could that be the case?

Tnx.

BigHache
09-04-2012, 05:46 AM
in the 'bin' directory of your LW install there should be a folder 'python27.zip', that's where the modules are that the interpreter looks for.

I haven't run into an error like that with LW.

jeric_synergy
09-04-2012, 07:57 AM
in the 'bin' directory of your LW install there should be a folder 'python27.zip', that's where the modules are that the interpreter looks for.

I haven't run into an error like that with LW.
And that folder does not need to be decompressed, right?

Looking at the image, anybody got any clues?

iain_r
09-04-2012, 03:09 PM
Hi Jeric,

With my 11.0 install I created a lib directory as a subdirectory of bin and decompressed the zip file into it. I haven't had any errors since. I haven't installed my 11.0.3 yet so I don't know if it has the same problem.

Regards

Iain.

BigHache
09-04-2012, 04:34 PM
And that folder does not need to be decompressed, right?

I never decompressed it, no.

And this error is when attempting to run a .py file yes? Have you tried doing an import command directly in the interpreter console to see if that generates the same error?

jeric_synergy
09-04-2012, 06:04 PM
Decompression to bin/lib didn't help.

And this error is when attempting to run a .py file yes? Have you tried doing an import command directly in the interpreter console to see if that generates the same error?
Normally I get these errors on launch, because the PCore console is set to OPEN ON ERROR, and Layout seems to do some sort of preprocessing when Autoscan is on (just like it crashes if there's 1)a poison LScript and 2) Autoscan is on).

But, hitting the PYTHON button and loading it directly (versus having it mapped to a button) does get the same errors, yes.

Here's the errors I get when executing PACKAGESCENE.py (twice):

BigHache
09-04-2012, 06:21 PM
OK. Trying to think through this as I've never seen what you're getting. Just a dumb thought, have you installed Python by itself on your system? I don't think it should need it but I do have Python installed with IDLE.

jeric_synergy
09-04-2012, 08:17 PM
OK. Trying to think through this as I've never seen what you're getting. Just a dumb thought, have you installed Python by itself on your system? I don't think it should need it but I do have Python installed with IDLE.
I have not: I assumed of course that the LW installer would check and install it, redundantly perhaps, but that's often the case.

Looks like I have a whole new set of acronyms ("IDLE", sigh) to learn. :(

jeric_synergy
09-09-2012, 04:12 PM
I gave in, deleted ALL versions of LW on my system, deleted the ".Newtek" folder, and started from scratch, using the 11.0.3 installer.

I still get the Python error on launch in both Layout and LWM. :devil:

Poking around, I note there's other *.ZIPped files in the LW folder besides python27.zip:

lwcoresdk11.0.zip
lwsdk11.0.zip
pdbs.zip

??? Can lw access these resources without them being extracted?

jeric_synergy
09-09-2012, 06:07 PM
Still pounding at this.... Iain, since you used the word "since", I'm assuming at one time you did have a similar problem?

jeric_synergy
09-09-2012, 07:43 PM
Got it! ::high-self-five::

A while back I installed an old piece of software --- I sure hope those bastards went broke. When it installed it hijacked a System Variable, PYTHONHOME, which borked my installed version of Python.

I installed the current version of Python (2.7.3), mended PYTHONHOME to point at the new folder, and WALLAGH! PackageScene.py works again! Halle-effin-ulah!

(The software also futzed with PYTHONPATH.) Invoking a DOS window and typing PYTHON still gets version 2.2, so I don't know what that's about. No Python gurus seem to think one would ever want to UNinstall Python ::eyeroll::, so they don't tell you how. Niiiiiiice.

Anyway, now I can write those superduper Python scripts I've been meaning to....

THANKS to everybody for their help and suggestions!