[scribus-dev] 1.5.6svn and Python3

ale rimoldi ale.comp_06 at xox.ch
Sat Nov 2 09:41:19 UTC 2019


hi greg

for you information:

exceptions are for errors at runtime.

using print without parenthesis is a syntax error, so the error happens
while python analyses the code to see what it has to do and does not
even start running the code.

you can see the difference by running this two scripts outside of
scribus:

this will fail without printing anything


```
print("abc")
print "abc"
```

and this will first print "abc" and then fail:

```
print("abc")
import scribus
```

you can also see that by putting an "print 'abc'" or a "import scribus"
inside of an if.
the first will always trigger an error, the second one only if python
sees that the if condition is true.

some of this is typical for python, some is valid for (almost) every
programming language...

ciao
a.l.e



More information about the scribus-dev mailing list