The following curvy python precedure reliably creates an obscure warning.

1. Save the following python script as repeat.py

Code: Select all

```
import golly as g
s = g.getselrect()
if s == []:
s = g.getrect()
xy = [0, 0]
s = g.getcells(s)
if s == []:
g.exit("Pattern is empty.")
disp = g.getstring("Enter displacement in form (x,y,t):", "2,14,14").split(",")
n = 0
try:
disp = (int(disp[0]), int(disp[1]), int(disp[2]))
n = int(g.getstring("How many times to repeat?", "1000"))
except:
g.exit("Invalid input.")
g.new("repeated")
g.putcells(s, xy[0], xy[1], 1, 0, 0, 1, "xor")
for i in range(n):
xy[0] += disp[0]
xy[1] += disp[1]
g.run(disp[2])
g.putcells(s, xy[0], xy[1], 1, 0, 0, 1, "xor")
```

2. Start a new Golly

3. Set rule to W90 in QuickLife and draw a dot

4. Execute the script with predefined parameters

5. Before reaching full File size, click Cancel in the "Writing pattern file" popup window; a Golly warning saying

**File contains truncated pattern** is expected.

6. Undo with ctrl+Z (NOT reset!)

7. Execute the script again

This will result in a Golly warning popping up, saying

**G_PyRun_SimpleString failed!**, but then the first dialog in the script will pop up as usual.