The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

import-bot (20211) [Avatar] Offline
[Originally posted by iri]

I had a program running properly in Pythonwin (build 125) (I think it is
that; in fact I have this first version installed in the PC from before I
started this job... so I'n not really sure)
The problem has come when I tried to run that program in another PC in
which I installed the Python-2.2.1c2.exe
Is the following (I attach the part of the program that causes the
problem; I make comments "on line"):

## I read from a postscript file

## That file contains different documents separated with the string

## I want to comment the line starting with /SCS / of the postscript
file I'm working with so I separate DOCUMENTS in two parts, the previous of
that line and the next of that line, that is PROLOGPRE and IN MY OLD VERSION
PROLOGPRE=string.split(DOCUMENTS[0],'/SCS /')

## Now I make the join of those parts and the commented line

and.......... in the new version..... it appears the following error:

IndexError: list index out of range

I watched what was inside PROLOGPRE[0] and was the expected part of
DOCUMENTS[0]. Watched PROLOGPRE[1] and...... it wasn't the rest of
DOCUMENTS[0] (excepting the line of /SCS /)!!!!! ¿¿??

Can the changeing of a version make the old program don't work?
Thank you very much for any help,